Lines Matching +full:set +full:- +full:top

1 // SPDX-License-Identifier: GPL-2.0-only
3 * linux/arch/arm/mach-omap1/lcd_dma.c
5 * Extracted from arch/arm/plat-omap/dma.c
6 * Copyright (C) 2003 - 2008 Nokia Corporation
11 * OMAP2/3 support Copyright (C) 2004-2007 Texas Instruments, Inc.
13 * Some functions based on earlier dma-omap.c Copyright (C) 2001 RidgeRun, Inc.
16 * Added OMAP4 support - Santosh Shilimkar <santosh.shilimkar@ti.com>
26 #include <linux/omap-dma.h>
28 #include <linux/soc/ti/omap1-soc.h>
29 #include <linux/soc/ti/omap1-io.h>
135 unsigned long top, bottom; in set_b1_regs() local
165 #define PIXSTEP(sx, sy, dx, dy) (PIXADDR(dx, dy) - PIXADDR(sx, sy) - es + 1) in set_b1_regs()
170 top = PIXADDR(0, 0); in set_b1_regs()
171 bottom = PIXADDR(lcd_dma.xres - 1, lcd_dma.yres - 1); in set_b1_regs()
178 fi = PIXSTEP(lcd_dma.xres - 1, 0, 0, 1); in set_b1_regs()
180 top = PIXADDR(lcd_dma.xres - 1, 0); in set_b1_regs()
181 bottom = PIXADDR(0, lcd_dma.yres - 1); in set_b1_regs()
183 fi = PIXSTEP(0, 0, lcd_dma.xres - 1, 1); in set_b1_regs()
190 top = PIXADDR(0, lcd_dma.yres - 1); in set_b1_regs()
191 bottom = PIXADDR(lcd_dma.xres - 1, 0); in set_b1_regs()
193 fi = PIXSTEP(0, 0, 1, lcd_dma.yres - 1); in set_b1_regs()
195 top = PIXADDR(lcd_dma.xres - 1, lcd_dma.yres - 1); in set_b1_regs()
198 fi = PIXSTEP(1, 0, 0, lcd_dma.yres - 1); in set_b1_regs()
205 top = PIXADDR(lcd_dma.xres - 1, lcd_dma.yres - 1); in set_b1_regs()
208 fi = PIXSTEP(0, 1, lcd_dma.xres - 1, 0); in set_b1_regs()
210 top = PIXADDR(0, lcd_dma.yres - 1); in set_b1_regs()
211 bottom = PIXADDR(lcd_dma.xres - 1, 0); in set_b1_regs()
213 fi = PIXSTEP(lcd_dma.xres - 1, 1, 0, 0); in set_b1_regs()
220 top = PIXADDR(lcd_dma.xres - 1, 0); in set_b1_regs()
221 bottom = PIXADDR(0, lcd_dma.yres - 1); in set_b1_regs()
223 fi = PIXSTEP(1, lcd_dma.yres - 1, 0, 0); in set_b1_regs()
225 top = PIXADDR(0, 0); in set_b1_regs()
226 bottom = PIXADDR(lcd_dma.xres - 1, lcd_dma.yres - 1); in set_b1_regs()
228 fi = PIXSTEP(0, lcd_dma.yres - 1, 1, 0); in set_b1_regs()
239 omap_writew(top >> 16, OMAP1510_DMA_LCD_TOP_F1_U); in set_b1_regs()
240 omap_writew(top, OMAP1510_DMA_LCD_TOP_F1_L); in set_b1_regs()
248 omap_writew(top >> 16, OMAP1610_DMA_LCD_TOP_B1_U); in set_b1_regs()
249 omap_writew(top, OMAP1610_DMA_LCD_TOP_B1_L); in set_b1_regs()
262 /* Always set the source port as SDRAM for now*/ in set_b1_regs()
275 /* Set the double-indexed addressing mode */ in set_b1_regs()
311 return -EBUSY; in omap_request_lcd_dma()
353 * Set the Enable bit only if an external controller is in omap_enable_lcd_dma()
376 /* Set some reasonable defaults */ in omap_setup_lcd_dma()
387 * If DMA was already active set the end_prog bit to have in omap_setup_lcd_dma()
388 * the programmed register set loaded into the active in omap_setup_lcd_dma()
389 * register set. in omap_setup_lcd_dma()
422 return -ENODEV; in omap_init_lcd_dma()