Lines Matching refs:xvip

134 static inline u32 xvip_read(struct xvip_device *xvip, u32 addr)  in xvip_read()  argument
136 return ioread32(xvip->iomem + addr); in xvip_read()
139 static inline void xvip_write(struct xvip_device *xvip, u32 addr, u32 value) in xvip_write() argument
141 iowrite32(value, xvip->iomem + addr); in xvip_write()
144 static inline void xvip_clr(struct xvip_device *xvip, u32 addr, u32 clr) in xvip_clr() argument
146 xvip_write(xvip, addr, xvip_read(xvip, addr) & ~clr); in xvip_clr()
149 static inline void xvip_set(struct xvip_device *xvip, u32 addr, u32 set) in xvip_set() argument
151 xvip_write(xvip, addr, xvip_read(xvip, addr) | set); in xvip_set()
154 void xvip_clr_or_set(struct xvip_device *xvip, u32 addr, u32 mask, bool set);
155 void xvip_clr_and_set(struct xvip_device *xvip, u32 addr, u32 clr, u32 set);
157 int xvip_init_resources(struct xvip_device *xvip);
158 void xvip_cleanup_resources(struct xvip_device *xvip);
160 static inline void xvip_reset(struct xvip_device *xvip) in xvip_reset() argument
162 xvip_write(xvip, XVIP_CTRL_CONTROL, XVIP_CTRL_CONTROL_SW_RESET); in xvip_reset()
165 static inline void xvip_start(struct xvip_device *xvip) in xvip_start() argument
167 xvip_set(xvip, XVIP_CTRL_CONTROL, in xvip_start()
171 static inline void xvip_stop(struct xvip_device *xvip) in xvip_stop() argument
173 xvip_clr(xvip, XVIP_CTRL_CONTROL, XVIP_CTRL_CONTROL_SW_ENABLE); in xvip_stop()
176 static inline void xvip_resume(struct xvip_device *xvip) in xvip_resume() argument
178 xvip_write(xvip, XVIP_CTRL_CONTROL, in xvip_resume()
179 xvip->saved_ctrl | XVIP_CTRL_CONTROL_SW_ENABLE); in xvip_resume()
182 static inline void xvip_suspend(struct xvip_device *xvip) in xvip_suspend() argument
184 xvip->saved_ctrl = xvip_read(xvip, XVIP_CTRL_CONTROL); in xvip_suspend()
185 xvip_write(xvip, XVIP_CTRL_CONTROL, in xvip_suspend()
186 xvip->saved_ctrl & ~XVIP_CTRL_CONTROL_SW_ENABLE); in xvip_suspend()
189 static inline void xvip_set_frame_size(struct xvip_device *xvip, in xvip_set_frame_size() argument
192 xvip_write(xvip, XVIP_ACTIVE_SIZE, in xvip_set_frame_size()
197 static inline void xvip_get_frame_size(struct xvip_device *xvip, in xvip_get_frame_size() argument
202 reg = xvip_read(xvip, XVIP_ACTIVE_SIZE); in xvip_get_frame_size()
209 static inline void xvip_enable_reg_update(struct xvip_device *xvip) in xvip_enable_reg_update() argument
211 xvip_set(xvip, XVIP_CTRL_CONTROL, XVIP_CTRL_CONTROL_REG_UPDATE); in xvip_enable_reg_update()
214 static inline void xvip_disable_reg_update(struct xvip_device *xvip) in xvip_disable_reg_update() argument
216 xvip_clr(xvip, XVIP_CTRL_CONTROL, XVIP_CTRL_CONTROL_REG_UPDATE); in xvip_disable_reg_update()
219 static inline void xvip_print_version(struct xvip_device *xvip) in xvip_print_version() argument
223 version = xvip_read(xvip, XVIP_CTRL_VERSION); in xvip_print_version()
225 dev_info(xvip->dev, "device found, version %u.%02x%x\n", in xvip_print_version()