sh: Add support sh7760fb to sh7763rdp board

Add sh7760fb platform device to sh7763rdp's setup.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>

authored by Nobuhiro Iwamatsu and committed by Paul Mundt 674063c5 0a766a6b

+51 -1
+51 -1
arch/sh/boards/mach-sh7763rdp/setup.c
··· 15 15 #include <linux/interrupt.h> 16 16 #include <linux/input.h> 17 17 #include <linux/mtd/physmap.h> 18 + #include <linux/fb.h> 18 19 #include <linux/io.h> 19 20 #include <asm/sh7763rdp.h> 20 21 #include <asm/sh_eth.h> 22 + #include <asm/sh7760fb.h> 21 23 22 24 /* NOR Flash */ 23 25 static struct mtd_partition sh7763rdp_nor_flash_partitions[] = { ··· 90 88 }, 91 89 }; 92 90 91 + /* SH7763 LCDC */ 92 + static struct resource sh7763rdp_fb_resources[] = { 93 + { 94 + .start = 0xFFE80000, 95 + .end = 0xFFE80442 - 1, 96 + .flags = IORESOURCE_MEM, 97 + }, 98 + }; 99 + 100 + static struct fb_videomode sh7763fb_videomode = { 101 + .refresh = 60, 102 + .name = "VGA Monitor", 103 + .xres = 640, 104 + .yres = 480, 105 + .pixclock = 10000, 106 + .left_margin = 80, 107 + .right_margin = 24, 108 + .upper_margin = 30, 109 + .lower_margin = 1, 110 + .hsync_len = 96, 111 + .vsync_len = 1, 112 + .sync = 0, 113 + .vmode = FB_VMODE_NONINTERLACED, 114 + .flag = FBINFO_FLAG_DEFAULT, 115 + }; 116 + 117 + static struct sh7760fb_platdata sh7763fb_def_pdata = { 118 + .def_mode = &sh7763fb_videomode, 119 + .ldmtr = (LDMTR_TFT_COLOR_16|LDMTR_MCNT), 120 + .lddfr = LDDFR_16BPP_RGB565, 121 + .ldpmmr = 0x0000, 122 + .ldpspr = 0xFFFF, 123 + .ldaclnr = 0x0001, 124 + .ldickr = 0x1102, 125 + .rotate = 0, 126 + .novsync = 0, 127 + .blank = NULL, 128 + }; 129 + 130 + static struct platform_device sh7763rdp_fb_device = { 131 + .name = "sh7760-lcdc", 132 + .resource = sh7763rdp_fb_resources, 133 + .num_resources = ARRAY_SIZE(sh7763rdp_fb_resources), 134 + .dev = { 135 + .platform_data = &sh7763fb_def_pdata, 136 + }, 137 + }; 138 + 93 139 static struct platform_device *sh7763rdp_devices[] __initdata = { 94 140 &sh7763rdp_nor_flash_device, 95 141 &sh7763rdp_eth_device, 142 + &sh7763rdp_fb_device, 96 143 }; 97 144 98 145 static int __init sh7763rdp_devices_setup(void) ··· 149 98 return platform_add_devices(sh7763rdp_devices, 150 99 ARRAY_SIZE(sh7763rdp_devices)); 151 100 } 152 - 153 101 device_initcall(sh7763rdp_devices_setup); 154 102 155 103 static void __init sh7763rdp_setup(char **cmdline_p)