From ce443ab5fd536941da1d529ba3963324f941fc29 Mon Sep 17 00:00:00 2001 From: GuanXuetao Date: Sat, 26 Feb 2011 21:39:10 +0800 Subject: unicore32 machine related: add frame buffer driver for pkunity-v3 soc change from original version -- by advice of Paul Mundt 1. remove videomemorysize definitions 2. remove unifb_enable and unifb_setup 3. use dev_warn instead of printk in fb driver 4. remove judgement for FB_ACCEL_PUV3_UNIGFX 5. adjust clk_get and clk_set_rate calls 6. add resources definitions 7. remove unifb_option 8. adjust register for platform_device 9. adjust unifb_ops position and unifb_regs assignment position Signed-off-by: Guan Xuetao Acked-by: Arnd Bergmann --- arch/unicore32/kernel/puv3-core.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'arch/unicore32/kernel') diff --git a/arch/unicore32/kernel/puv3-core.c b/arch/unicore32/kernel/puv3-core.c index 6edf928..7d10e7b 100644 --- a/arch/unicore32/kernel/puv3-core.c +++ b/arch/unicore32/kernel/puv3-core.c @@ -93,6 +93,19 @@ static struct resource puv3_mmc_resources[] = { }, }; +static struct resource puv3_unigfx_resources[] = { + [0] = { + .start = PKUNITY_UNIGFX_BASE, + .end = PKUNITY_UNIGFX_BASE + 0xfff, + .flags = IORESOURCE_MEM, + }, + [1] = { + .start = PKUNITY_UNIGFX_MMAP_BASE, + .end = PKUNITY_UNIGFX_MMAP_BASE + PKUNITY_UNIGFX_MMAP_SIZE, + .flags = IORESOURCE_MEM, + }, +}; + static struct resource puv3_rtc_resources[] = { [0] = { .start = PKUNITY_RTC_BASE, @@ -256,6 +269,8 @@ void __init puv3_core_init(void) puv3_umal_resources, ARRAY_SIZE(puv3_umal_resources)); platform_device_register_simple("PKUnity-v3-MMC", -1, puv3_mmc_resources, ARRAY_SIZE(puv3_mmc_resources)); + platform_device_register_simple("PKUnity-v3-UNIGFX", -1, + puv3_unigfx_resources, ARRAY_SIZE(puv3_unigfx_resources)); platform_device_register_simple("PKUnity-v3-PWM", -1, puv3_pwm_resources, ARRAY_SIZE(puv3_pwm_resources)); platform_device_register_simple("PKUnity-v3-UART", 0, -- cgit v1.1