Lines Matching defs:path

122 	struct mmp_path *path = overlay->path;
123 tmp = readl_relaxed(ctrl_regs(path) + dma_ctrl(0, path->id));
126 writel_relaxed(tmp, ctrl_regs(path) + dma_ctrl(0, path->id));
131 struct lcd_regs *regs = path_regs(overlay->path);
171 struct mmp_path *path = overlay->path;
174 tmp = readl_relaxed(ctrl_regs(path) + dma_ctrl(0, path->id));
177 writel(tmp, ctrl_regs(path) + dma_ctrl(0, path->id));
181 static void path_enabledisable(struct mmp_path *path, int on)
184 mutex_lock(&path->access_ok);
185 tmp = readl_relaxed(ctrl_regs(path) + LCD_SCLK(path));
190 writel_relaxed(tmp, ctrl_regs(path) + LCD_SCLK(path));
191 mutex_unlock(&path->access_ok);
194 static void path_onoff(struct mmp_path *path, int on)
196 if (path->status == on) {
197 dev_info(path->dev, "path %s is already %s\n",
198 path->name, stat_name(path->status));
203 path_enabledisable(path, 1);
205 if (path->panel && path->panel->set_onoff)
206 path->panel->set_onoff(path->panel, 1);
208 if (path->panel && path->panel->set_onoff)
209 path->panel->set_onoff(path->panel, 0);
211 path_enabledisable(path, 0);
213 path->status = on;
220 overlay->path->name, stat_name(overlay->status));
225 if (overlay->path->ops.check_status(overlay->path)
226 != overlay->path->status)
227 path_onoff(overlay->path, on);
237 struct lcd_regs *regs = path_regs(overlay->path);
252 static void path_set_mode(struct mmp_path *path, struct mmp_mode *mode)
254 struct lcd_regs *regs = path_regs(path);
256 link_config = path_to_path_plat(path)->link_config,
257 dsi_rbswap = path_to_path_plat(path)->link_config;
260 memcpy(&path->mode, mode, sizeof(struct mmp_mode));
262 mutex_lock(&path->access_ok);
265 tmp = readl_relaxed(ctrl_regs(path) + intf_ctrl(path->id)) & 0x1;
270 writel_relaxed(tmp, ctrl_regs(path) + intf_ctrl(path->id));
273 tmp = readl_relaxed(ctrl_regs(path) + intf_rbswap_ctrl(path->id)) &
276 writel_relaxed(tmp, ctrl_regs(path) + intf_rbswap_ctrl(path->id));
292 if (path->output_type == PATH_OUT_DSI)
300 sclk_src = clk_get_rate(path_to_ctrl(path)->clk);
305 dev_info(path->dev, "%s sclk_src %d sclk_div 0x%x pclk %d\n",
308 tmp = readl_relaxed(ctrl_regs(path) + LCD_SCLK(path));
311 writel_relaxed(tmp, ctrl_regs(path) + LCD_SCLK(path));
313 mutex_unlock(&path->access_ok);
345 static void path_set_default(struct mmp_path *path)
347 struct lcd_regs *regs = path_regs(path);
350 path_config = path_to_path_plat(path)->path_config;
353 if (PATH_OUT_PARALLEL == path->output_type) {
355 tmp = readl_relaxed(ctrl_regs(path) + SPU_IOPAD_CONTROL);
358 writel_relaxed(tmp, ctrl_regs(path) + SPU_IOPAD_CONTROL);
361 /* Select path clock source */
362 tmp = readl_relaxed(ctrl_regs(path) + LCD_SCLK(path));
365 writel_relaxed(tmp, ctrl_regs(path) + LCD_SCLK(path));
375 writel_relaxed(dma_ctrl1, ctrl_regs(path) + dma_ctrl(1, path->id));
384 * bus arbiter for faster read if not tv path;
388 tmp = readl_relaxed(ctrl_regs(path) + dma_ctrl(0, path->id));
390 if (PATH_TV == path->id)
392 writel_relaxed(tmp, ctrl_regs(path) + dma_ctrl(0, path->id));
400 struct mmp_path *path = NULL;
418 path = mmp_register_path(path_info);
419 if (!path) {
423 path_plat->path = path;
427 path_set_default(path);
438 mmp_unregister_path(path_plat->path);
536 /* path init */