Lines Matching refs:cfg
26 u32 cfg; in gsc_wait_reset() local
29 cfg = readl(dev->regs + GSC_SW_RESET); in gsc_wait_reset()
30 if (!cfg) in gsc_wait_reset()
40 u32 cfg; in gsc_hw_set_frm_done_irq_mask() local
42 cfg = readl(dev->regs + GSC_IRQ); in gsc_hw_set_frm_done_irq_mask()
44 cfg |= GSC_IRQ_FRMDONE_MASK; in gsc_hw_set_frm_done_irq_mask()
46 cfg &= ~GSC_IRQ_FRMDONE_MASK; in gsc_hw_set_frm_done_irq_mask()
47 writel(cfg, dev->regs + GSC_IRQ); in gsc_hw_set_frm_done_irq_mask()
52 u32 cfg; in gsc_hw_set_gsc_irq_enable() local
54 cfg = readl(dev->regs + GSC_IRQ); in gsc_hw_set_gsc_irq_enable()
56 cfg |= GSC_IRQ_ENABLE; in gsc_hw_set_gsc_irq_enable()
58 cfg &= ~GSC_IRQ_ENABLE; in gsc_hw_set_gsc_irq_enable()
59 writel(cfg, dev->regs + GSC_IRQ); in gsc_hw_set_gsc_irq_enable()
65 u32 cfg = readl(dev->regs + GSC_IN_BASE_ADDR_Y_MASK); in gsc_hw_set_input_buf_masking() local
68 cfg &= ~mask; in gsc_hw_set_input_buf_masking()
69 cfg |= enable << shift; in gsc_hw_set_input_buf_masking()
71 writel(cfg, dev->regs + GSC_IN_BASE_ADDR_Y_MASK); in gsc_hw_set_input_buf_masking()
72 writel(cfg, dev->regs + GSC_IN_BASE_ADDR_CB_MASK); in gsc_hw_set_input_buf_masking()
73 writel(cfg, dev->regs + GSC_IN_BASE_ADDR_CR_MASK); in gsc_hw_set_input_buf_masking()
79 u32 cfg = readl(dev->regs + GSC_OUT_BASE_ADDR_Y_MASK); in gsc_hw_set_output_buf_masking() local
82 cfg &= ~mask; in gsc_hw_set_output_buf_masking()
83 cfg |= enable << shift; in gsc_hw_set_output_buf_masking()
85 writel(cfg, dev->regs + GSC_OUT_BASE_ADDR_Y_MASK); in gsc_hw_set_output_buf_masking()
86 writel(cfg, dev->regs + GSC_OUT_BASE_ADDR_CB_MASK); in gsc_hw_set_output_buf_masking()
87 writel(cfg, dev->regs + GSC_OUT_BASE_ADDR_CR_MASK); in gsc_hw_set_output_buf_masking()
115 u32 cfg = readl(dev->regs + GSC_IN_CON); in gsc_hw_set_input_path() local
116 cfg &= ~(GSC_IN_PATH_MASK | GSC_IN_LOCAL_SEL_MASK); in gsc_hw_set_input_path()
119 cfg |= GSC_IN_PATH_MEMORY; in gsc_hw_set_input_path()
121 writel(cfg, dev->regs + GSC_IN_CON); in gsc_hw_set_input_path()
128 u32 cfg; in gsc_hw_set_in_size() local
131 cfg = GSC_SRCIMG_OFFSET_X(frame->crop.left); in gsc_hw_set_in_size()
132 cfg |= GSC_SRCIMG_OFFSET_Y(frame->crop.top); in gsc_hw_set_in_size()
133 writel(cfg, dev->regs + GSC_SRCIMG_OFFSET); in gsc_hw_set_in_size()
136 cfg = GSC_SRCIMG_WIDTH(frame->f_width); in gsc_hw_set_in_size()
137 cfg |= GSC_SRCIMG_HEIGHT(frame->f_height); in gsc_hw_set_in_size()
138 writel(cfg, dev->regs + GSC_SRCIMG_SIZE); in gsc_hw_set_in_size()
141 cfg = GSC_CROPPED_WIDTH(frame->crop.width); in gsc_hw_set_in_size()
142 cfg |= GSC_CROPPED_HEIGHT(frame->crop.height); in gsc_hw_set_in_size()
143 writel(cfg, dev->regs + GSC_CROPPED_SIZE); in gsc_hw_set_in_size()
150 u32 cfg; in gsc_hw_set_in_image_rgb() local
152 cfg = readl(dev->regs + GSC_IN_CON); in gsc_hw_set_in_image_rgb()
154 cfg |= GSC_IN_RGB_HD_WIDE; in gsc_hw_set_in_image_rgb()
156 cfg |= GSC_IN_RGB_SD_WIDE; in gsc_hw_set_in_image_rgb()
159 cfg |= GSC_IN_RGB565; in gsc_hw_set_in_image_rgb()
161 cfg |= GSC_IN_XRGB8888; in gsc_hw_set_in_image_rgb()
163 writel(cfg, dev->regs + GSC_IN_CON); in gsc_hw_set_in_image_rgb()
171 u32 cfg; in gsc_hw_set_in_image_format() local
173 cfg = readl(dev->regs + GSC_IN_CON); in gsc_hw_set_in_image_format()
174 cfg &= ~(GSC_IN_RGB_TYPE_MASK | GSC_IN_YUV422_1P_ORDER_MASK | in gsc_hw_set_in_image_format()
177 writel(cfg, dev->regs + GSC_IN_CON); in gsc_hw_set_in_image_format()
188 cfg |= GSC_IN_YUV422_1P; in gsc_hw_set_in_image_format()
190 cfg |= GSC_IN_YUV422_1P_ORDER_LSB_Y; in gsc_hw_set_in_image_format()
192 cfg |= GSC_IN_YUV422_1P_OEDER_LSB_C; in gsc_hw_set_in_image_format()
194 cfg |= GSC_IN_CHROMA_ORDER_CBCR; in gsc_hw_set_in_image_format()
196 cfg |= GSC_IN_CHROMA_ORDER_CRCB; in gsc_hw_set_in_image_format()
200 cfg |= GSC_IN_YUV420_2P; in gsc_hw_set_in_image_format()
202 cfg |= GSC_IN_YUV422_2P; in gsc_hw_set_in_image_format()
204 cfg |= GSC_IN_CHROMA_ORDER_CBCR; in gsc_hw_set_in_image_format()
206 cfg |= GSC_IN_CHROMA_ORDER_CRCB; in gsc_hw_set_in_image_format()
210 cfg |= GSC_IN_YUV420_3P; in gsc_hw_set_in_image_format()
212 cfg |= GSC_IN_YUV422_3P; in gsc_hw_set_in_image_format()
217 cfg |= GSC_IN_TILE_C_16x8 | GSC_IN_TILE_MODE; in gsc_hw_set_in_image_format()
219 writel(cfg, dev->regs + GSC_IN_CON); in gsc_hw_set_in_image_format()
226 u32 cfg = readl(dev->regs + GSC_OUT_CON); in gsc_hw_set_output_path() local
227 cfg &= ~GSC_OUT_PATH_MASK; in gsc_hw_set_output_path()
230 cfg |= GSC_OUT_PATH_MEMORY; in gsc_hw_set_output_path()
232 cfg |= GSC_OUT_PATH_LOCAL; in gsc_hw_set_output_path()
234 writel(cfg, dev->regs + GSC_OUT_CON); in gsc_hw_set_output_path()
241 u32 cfg; in gsc_hw_set_out_size() local
245 cfg = GSC_DSTIMG_OFFSET_X(frame->crop.left); in gsc_hw_set_out_size()
246 cfg |= GSC_DSTIMG_OFFSET_Y(frame->crop.top); in gsc_hw_set_out_size()
247 writel(cfg, dev->regs + GSC_DSTIMG_OFFSET); in gsc_hw_set_out_size()
249 cfg = GSC_DSTIMG_WIDTH(frame->f_width); in gsc_hw_set_out_size()
250 cfg |= GSC_DSTIMG_HEIGHT(frame->f_height); in gsc_hw_set_out_size()
251 writel(cfg, dev->regs + GSC_DSTIMG_SIZE); in gsc_hw_set_out_size()
257 cfg = GSC_SCALED_WIDTH(frame->crop.height); in gsc_hw_set_out_size()
258 cfg |= GSC_SCALED_HEIGHT(frame->crop.width); in gsc_hw_set_out_size()
260 cfg = GSC_SCALED_WIDTH(frame->crop.width); in gsc_hw_set_out_size()
261 cfg |= GSC_SCALED_HEIGHT(frame->crop.height); in gsc_hw_set_out_size()
263 writel(cfg, dev->regs + GSC_SCALED_SIZE); in gsc_hw_set_out_size()
270 u32 cfg; in gsc_hw_set_out_image_rgb() local
272 cfg = readl(dev->regs + GSC_OUT_CON); in gsc_hw_set_out_image_rgb()
274 cfg |= GSC_OUT_RGB_HD_WIDE; in gsc_hw_set_out_image_rgb()
276 cfg |= GSC_OUT_RGB_SD_WIDE; in gsc_hw_set_out_image_rgb()
279 cfg |= GSC_OUT_RGB565; in gsc_hw_set_out_image_rgb()
281 cfg |= GSC_OUT_XRGB8888; in gsc_hw_set_out_image_rgb()
283 writel(cfg, dev->regs + GSC_OUT_CON); in gsc_hw_set_out_image_rgb()
291 u32 cfg; in gsc_hw_set_out_image_format() local
293 cfg = readl(dev->regs + GSC_OUT_CON); in gsc_hw_set_out_image_format()
294 cfg &= ~(GSC_OUT_RGB_TYPE_MASK | GSC_OUT_YUV422_1P_ORDER_MASK | in gsc_hw_set_out_image_format()
297 writel(cfg, dev->regs + GSC_OUT_CON); in gsc_hw_set_out_image_format()
305 cfg |= GSC_OUT_YUV444; in gsc_hw_set_out_image_format()
314 cfg |= GSC_OUT_YUV422_1P; in gsc_hw_set_out_image_format()
316 cfg |= GSC_OUT_YUV422_1P_ORDER_LSB_Y; in gsc_hw_set_out_image_format()
318 cfg |= GSC_OUT_YUV422_1P_OEDER_LSB_C; in gsc_hw_set_out_image_format()
320 cfg |= GSC_OUT_CHROMA_ORDER_CBCR; in gsc_hw_set_out_image_format()
322 cfg |= GSC_OUT_CHROMA_ORDER_CRCB; in gsc_hw_set_out_image_format()
326 cfg |= GSC_OUT_YUV420_2P; in gsc_hw_set_out_image_format()
328 cfg |= GSC_OUT_YUV422_2P; in gsc_hw_set_out_image_format()
330 cfg |= GSC_OUT_CHROMA_ORDER_CBCR; in gsc_hw_set_out_image_format()
332 cfg |= GSC_OUT_CHROMA_ORDER_CRCB; in gsc_hw_set_out_image_format()
335 cfg |= GSC_OUT_YUV420_3P; in gsc_hw_set_out_image_format()
340 cfg |= GSC_OUT_TILE_C_16x8 | GSC_OUT_TILE_MODE; in gsc_hw_set_out_image_format()
343 writel(cfg, dev->regs + GSC_OUT_CON); in gsc_hw_set_out_image_format()
350 u32 cfg; in gsc_hw_set_prescaler() local
352 cfg = GSC_PRESC_SHFACTOR(sc->pre_shfactor); in gsc_hw_set_prescaler()
353 cfg |= GSC_PRESC_H_RATIO(sc->pre_hratio); in gsc_hw_set_prescaler()
354 cfg |= GSC_PRESC_V_RATIO(sc->pre_vratio); in gsc_hw_set_prescaler()
355 writel(cfg, dev->regs + GSC_PRE_SCALE_RATIO); in gsc_hw_set_prescaler()
362 u32 cfg; in gsc_hw_set_mainscaler() local
364 cfg = GSC_MAIN_H_RATIO_VALUE(sc->main_hratio); in gsc_hw_set_mainscaler()
365 writel(cfg, dev->regs + GSC_MAIN_H_RATIO); in gsc_hw_set_mainscaler()
367 cfg = GSC_MAIN_V_RATIO_VALUE(sc->main_vratio); in gsc_hw_set_mainscaler()
368 writel(cfg, dev->regs + GSC_MAIN_V_RATIO); in gsc_hw_set_mainscaler()
374 u32 cfg; in gsc_hw_set_rotation() local
376 cfg = readl(dev->regs + GSC_IN_CON); in gsc_hw_set_rotation()
377 cfg &= ~GSC_IN_ROT_MASK; in gsc_hw_set_rotation()
381 cfg |= GSC_IN_ROT_270; in gsc_hw_set_rotation()
384 cfg |= GSC_IN_ROT_180; in gsc_hw_set_rotation()
388 cfg |= GSC_IN_ROT_90_XFLIP; in gsc_hw_set_rotation()
390 cfg |= GSC_IN_ROT_90_YFLIP; in gsc_hw_set_rotation()
392 cfg |= GSC_IN_ROT_90; in gsc_hw_set_rotation()
396 cfg |= GSC_IN_ROT_XFLIP; in gsc_hw_set_rotation()
398 cfg |= GSC_IN_ROT_YFLIP; in gsc_hw_set_rotation()
401 writel(cfg, dev->regs + GSC_IN_CON); in gsc_hw_set_rotation()
408 u32 cfg; in gsc_hw_set_global_alpha() local
415 cfg = readl(dev->regs + GSC_OUT_CON); in gsc_hw_set_global_alpha()
416 cfg &= ~GSC_OUT_GLOBAL_ALPHA_MASK; in gsc_hw_set_global_alpha()
418 cfg |= GSC_OUT_GLOBAL_ALPHA(ctx->gsc_ctrls.global_alpha->val); in gsc_hw_set_global_alpha()
419 writel(cfg, dev->regs + GSC_OUT_CON); in gsc_hw_set_global_alpha()
425 u32 cfg; in gsc_hw_set_sfr_update() local
427 cfg = readl(dev->regs + GSC_ENABLE); in gsc_hw_set_sfr_update()
428 cfg |= GSC_ENABLE_SFR_UPDATE; in gsc_hw_set_sfr_update()
429 writel(cfg, dev->regs + GSC_ENABLE); in gsc_hw_set_sfr_update()