]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
ARM: pxa: move regs-lcd.h into driver
authorArnd Bergmann <arnd@arndb.de>
Sun, 1 Sep 2019 22:15:44 +0000 (00:15 +0200)
committerArnd Bergmann <arnd@arndb.de>
Tue, 19 Apr 2022 14:29:03 +0000 (16:29 +0200)
Only the pxafb driver uses this header, so move it into the
same directory. The SMART_* macros are required by some
platform data definitions and can go into the
linux/platform_data/video-pxafb.h header.

Acked-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Cc: dri-devel@lists.freedesktop.org
Cc: linux-fbdev@vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
drivers/video/fbdev/pxa3xx-regs.h [moved from arch/arm/mach-pxa/include/mach/regs-lcd.h with 90% similarity]
drivers/video/fbdev/pxafb.c
include/linux/platform_data/video-pxafb.h

similarity index 90%
rename from arch/arm/mach-pxa/include/mach/regs-lcd.h
rename to drivers/video/fbdev/pxa3xx-regs.h
index 6a434675f84a690461db07c4df38007f036c5b46..6a96610ef9b53d7b769dcffd2aee7554d4c048b2 100644 (file)
 #define PRSR_ST_OK     (1 << 9)        /* Status OK */
 #define PRSR_CON_NT    (1 << 10)       /* Continue to Next Command */
 
-#define SMART_CMD_A0                    (0x1 << 8)
-#define SMART_CMD_READ_STATUS_REG       (0x0 << 9)
-#define SMART_CMD_READ_FRAME_BUFFER    ((0x0 << 9) | SMART_CMD_A0)
-#define SMART_CMD_WRITE_COMMAND                 (0x1 << 9)
-#define SMART_CMD_WRITE_DATA           ((0x1 << 9) | SMART_CMD_A0)
-#define SMART_CMD_WRITE_FRAME          ((0x2 << 9) | SMART_CMD_A0)
-#define SMART_CMD_WAIT_FOR_VSYNC        (0x3 << 9)
-#define SMART_CMD_NOOP                  (0x4 << 9)
-#define SMART_CMD_INTERRUPT             (0x5 << 9)
-
-#define SMART_CMD(x)   (SMART_CMD_WRITE_COMMAND | ((x) & 0xff))
-#define SMART_DAT(x)   (SMART_CMD_WRITE_DATA | ((x) & 0xff))
-
-/* SMART_DELAY() is introduced for software controlled delay primitive which
- * can be inserted between command sequences, unused command 0x6 is used here
- * and delay ranges from 0ms ~ 255ms
- */
-#define SMART_CMD_DELAY                (0x6 << 9)
-#define SMART_DELAY(ms)                (SMART_CMD_DELAY | ((ms) & 0xff))
 #endif /* __ASM_ARCH_REGS_LCD_H */
index edf080f64a8c5412d10bf7d5fd9ea986901b2003..ab5bc8272d8ec226acdf2cf3712ca78ac841f4e8 100644 (file)
@@ -72,6 +72,7 @@
 #define DEBUG_VAR 1
 
 #include "pxafb.h"
+#include "pxa3xx-regs.h"
 
 /* Bits which should not be set in machine configuration structures */
 #define LCCR0_INVALID_CONFIG_MASK      (LCCR0_OUM | LCCR0_BM | LCCR0_QDM |\
index b3d5747783263f244deefe8d9fff613b622cc470..6333bac166a5a5e9139bc7cde580a9fcb40663bb 100644 (file)
@@ -8,7 +8,6 @@
  */
 
 #include <linux/fb.h>
-#include <mach/regs-lcd.h>
 
 /*
  * Supported LCD connections
@@ -153,6 +152,27 @@ struct pxafb_mach_info {
 void pxa_set_fb_info(struct device *, struct pxafb_mach_info *);
 unsigned long pxafb_get_hsync_time(struct device *dev);
 
+/* smartpanel related */
+#define SMART_CMD_A0                    (0x1 << 8)
+#define SMART_CMD_READ_STATUS_REG       (0x0 << 9)
+#define SMART_CMD_READ_FRAME_BUFFER    ((0x0 << 9) | SMART_CMD_A0)
+#define SMART_CMD_WRITE_COMMAND                 (0x1 << 9)
+#define SMART_CMD_WRITE_DATA           ((0x1 << 9) | SMART_CMD_A0)
+#define SMART_CMD_WRITE_FRAME          ((0x2 << 9) | SMART_CMD_A0)
+#define SMART_CMD_WAIT_FOR_VSYNC        (0x3 << 9)
+#define SMART_CMD_NOOP                  (0x4 << 9)
+#define SMART_CMD_INTERRUPT             (0x5 << 9)
+
+#define SMART_CMD(x)   (SMART_CMD_WRITE_COMMAND | ((x) & 0xff))
+#define SMART_DAT(x)   (SMART_CMD_WRITE_DATA | ((x) & 0xff))
+
+/* SMART_DELAY() is introduced for software controlled delay primitive which
+ * can be inserted between command sequences, unused command 0x6 is used here
+ * and delay ranges from 0ms ~ 255ms
+ */
+#define SMART_CMD_DELAY                (0x6 << 9)
+#define SMART_DELAY(ms)                (SMART_CMD_DELAY | ((ms) & 0xff))
+
 #ifdef CONFIG_FB_PXA_SMARTPANEL
 extern int pxafb_smart_queue(struct fb_info *info, uint16_t *cmds, int);
 extern int pxafb_smart_flush(struct fb_info *info);