Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ce443ab5 authored by GuanXuetao's avatar GuanXuetao
Browse files

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: default avatarGuan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
parent d10e4a66
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -4902,6 +4902,7 @@ S: Maintained
T:	git git://git.kernel.org/pub/scm/linux/kernel/git/epip/linux-2.6-unicore32.git
F:	drivers/input/serio/i8042-unicore32io.h
F:	drivers/i2c/busses/i2c-puv3.c
F:	drivers/video/fb-puv3.c

PMC SIERRA MaxRAID DRIVER
M:	Anil Ravindranath <anil_ravindranath@pmc-sierra.com>
+2 −1
Original line number Diff line number Diff line
@@ -66,7 +66,6 @@ CONFIG_LCD_BACKLIGHT=n

CONFIG_PUV3_RTC=y
CONFIG_PUV3_UMAL=y
CONFIG_PUV3_UNIGFX=y
CONFIG_PUV3_MUSB=n
CONFIG_PUV3_AC97=n
CONFIG_PUV3_NAND=n
@@ -130,6 +129,8 @@ CONFIG_VIDEO_DEV=n
CONFIG_USB_VIDEO_CLASS=n

#	Graphics support
CONFIG_FB=y
CONFIG_FB_PUV3_UNIGFX=y
#	Console display driver support
CONFIG_VGA_CONSOLE=n
CONFIG_FRAMEBUFFER_CONSOLE=y
+1 −1
Original line number Diff line number Diff line
@@ -50,7 +50,7 @@ void puv3_pci_adjust_zones(unsigned long *size, unsigned long *holes);

/* kuser area */
#define KUSER_VECPAGE_BASE	(KUSER_BASE + UL(0x3fff0000))
#define KUSER_UNIGFX_BASE	(KUSER_BASE + PKUNITY_UNIGFX_MMAP_BASE)
#define KUSER_UNIGFX_BASE	(PAGE_OFFSET + PKUNITY_UNIGFX_MMAP_BASE)
/* kuser_vecpage (0xbfff0000) is ro, and vectors page (0xffff0000) is rw */
#define kuser_vecpage_to_vectors(x)	((x) - (KUSER_VECPAGE_BASE)	\
					+ (VECTORS_BASE))
+15 −0
Original line number Diff line number Diff line
@@ -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,
+11 −0
Original line number Diff line number Diff line
@@ -2365,6 +2365,17 @@ config FB_JZ4740
	help
	  Framebuffer support for the JZ4740 SoC.

config FB_PUV3_UNIGFX
	tristate "PKUnity v3 Unigfx framebuffer support"
	depends on FB && UNICORE32 && ARCH_PUV3
	select FB_SYS_FILLRECT
	select FB_SYS_COPYAREA
	select FB_SYS_IMAGEBLIT
	select FB_SYS_FOPS
	help
	  Choose this option if you want to use the Unigfx device as a
	  framebuffer device. Without the support of PCI & AGP.

source "drivers/video/omap/Kconfig"
source "drivers/video/omap2/Kconfig"

Loading