[ARM] pxa: allow platforms to control which uarts are registered
Russell King [Mon, 9 Nov 2009 05:34:08 +0000 (13:34 +0800)]
For some platforms, it is inappropriate to register all PXA UARTs.
In some cases, the UARTs may not be used, and in others we may want
to avoid registering the UARTs to allow other drivers (eg, FICP) to
make use of the UART.

In addition, a while back there was a request to be able to pass
platform data to the UART driver.

This patch enables all of this by providing functions platforms can
call to register each individual UART.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>

52 files changed:
arch/arm/mach-pxa/balloon3.c
arch/arm/mach-pxa/cm-x2xx.c
arch/arm/mach-pxa/cm-x300.c
arch/arm/mach-pxa/colibri-pxa270.c
arch/arm/mach-pxa/colibri-pxa300.c
arch/arm/mach-pxa/colibri-pxa320.c
arch/arm/mach-pxa/corgi.c
arch/arm/mach-pxa/csb726.c
arch/arm/mach-pxa/devices.c
arch/arm/mach-pxa/e330.c
arch/arm/mach-pxa/e350.c
arch/arm/mach-pxa/e400.c
arch/arm/mach-pxa/e740.c
arch/arm/mach-pxa/e750.c
arch/arm/mach-pxa/e800.c
arch/arm/mach-pxa/em-x270.c
arch/arm/mach-pxa/ezx.c
arch/arm/mach-pxa/generic.h
arch/arm/mach-pxa/gumstix.c
arch/arm/mach-pxa/h5000.c
arch/arm/mach-pxa/himalaya.c
arch/arm/mach-pxa/hx4700.c
arch/arm/mach-pxa/idp.c
arch/arm/mach-pxa/imote2.c
arch/arm/mach-pxa/littleton.c
arch/arm/mach-pxa/lpd270.c
arch/arm/mach-pxa/lubbock.c
arch/arm/mach-pxa/magician.c
arch/arm/mach-pxa/mainstone.c
arch/arm/mach-pxa/mioa701.c
arch/arm/mach-pxa/mp900.c
arch/arm/mach-pxa/palmld.c
arch/arm/mach-pxa/palmt5.c
arch/arm/mach-pxa/palmtc.c
arch/arm/mach-pxa/palmte2.c
arch/arm/mach-pxa/palmtreo.c
arch/arm/mach-pxa/palmtx.c
arch/arm/mach-pxa/palmz72.c
arch/arm/mach-pxa/pcm027.c
arch/arm/mach-pxa/poodle.c
arch/arm/mach-pxa/pxa25x.c
arch/arm/mach-pxa/pxa27x.c
arch/arm/mach-pxa/pxa3xx.c
arch/arm/mach-pxa/saar.c
arch/arm/mach-pxa/spitz.c
arch/arm/mach-pxa/stargate2.c
arch/arm/mach-pxa/tavorevb.c
arch/arm/mach-pxa/tosa.c
arch/arm/mach-pxa/trizeps4.c
arch/arm/mach-pxa/viper.c
arch/arm/mach-pxa/xcep.c
arch/arm/mach-pxa/zylonite.c

index f23138b..b8cd07c 100644 (file)
@@ -306,6 +306,10 @@ static void __init balloon3_init(void)
         */
        ARB_CNTRL = ARB_CORE_PARK | 0x234;
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
        if (balloon3_has(BALLOON3_FEATURE_AUDIO))
                pxa_set_ac97_info(NULL);
index b50ef39..bff6e78 100644 (file)
@@ -453,6 +453,10 @@ static inline void cmx2xx_init_ac97(void) {}
 
 static void __init cmx2xx_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        cmx2xx_pm_init();
 
        if (cpu_is_pxa25x())
index 06552ca..7f2e878 100644 (file)
@@ -438,6 +438,10 @@ static void __init cm_x300_init(void)
        /* board-processor specific GPIO initialization */
        pxa3xx_mfp_config(ARRAY_AND_SIZE(cm_x300_mfp_cfg));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        cm_x300_init_dm9000();
        cm_x300_init_lcd();
        cm_x300_init_ohci();
index 01bcfaa..061c453 100644 (file)
@@ -130,6 +130,9 @@ static struct platform_device *colibri_pxa270_devices[] __initdata = {
 static void __init colibri_pxa270_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(colibri_pxa270_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        platform_add_devices(ARRAY_AND_SIZE(colibri_pxa270_devices));
 }
 
index 37c239c..45c23fd 100644 (file)
@@ -170,6 +170,10 @@ static inline void colibri_pxa310_init_ac97(void) {}
 
 void __init colibri_pxa300_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        colibri_pxa300_init_eth();
        colibri_pxa300_init_ohci();
        colibri_pxa3xx_init_nand();
index ec0e14b..ae835fa 100644 (file)
@@ -199,6 +199,10 @@ static void __init colibri_pxa320_init_uart(void)
 
 void __init colibri_pxa320_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        colibri_pxa320_init_eth();
        colibri_pxa320_init_ohci();
        colibri_pxa3xx_init_nand();
index b536b5a..74446cf 100644 (file)
@@ -671,6 +671,10 @@ static void __init corgi_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(corgi_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        corgi_init_spi();
 
        pxa_set_udc_info(&udc_info);
index 965480e..88575b8 100644 (file)
@@ -268,6 +268,9 @@ static void __init csb726_init(void)
 /*     MSC2 = 0x06697ff4; *//* none/SM501 */
        MSC2 = (MSC2 & ~0xffff) | 0x7ff4; /* SM501 */
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        pxa_set_i2c_info(NULL);
        pxa27x_set_i2c_power_info(NULL);
        pxa_set_mci_info(&csb726_mci);
index e2b427f..d4cc41d 100644 (file)
@@ -167,13 +167,18 @@ static struct resource pxa_resource_ffuart[] = {
        }
 };
 
-struct platform_device pxa_device_ffuart= {
+struct platform_device pxa_device_ffuart = {
        .name           = "pxa2xx-uart",
        .id             = 0,
        .resource       = pxa_resource_ffuart,
        .num_resources  = ARRAY_SIZE(pxa_resource_ffuart),
 };
 
+void __init pxa_set_ffuart_info(void *info)
+{
+       pxa_register_device(&pxa_device_ffuart, info);
+}
+
 static struct resource pxa_resource_btuart[] = {
        {
                .start  = 0x40200000,
@@ -193,6 +198,11 @@ struct platform_device pxa_device_btuart = {
        .num_resources  = ARRAY_SIZE(pxa_resource_btuart),
 };
 
+void __init pxa_set_btuart_info(void *info)
+{
+       pxa_register_device(&pxa_device_btuart, info);
+}
+
 static struct resource pxa_resource_stuart[] = {
        {
                .start  = 0x40700000,
@@ -212,6 +222,11 @@ struct platform_device pxa_device_stuart = {
        .num_resources  = ARRAY_SIZE(pxa_resource_stuart),
 };
 
+void __init pxa_set_stuart_info(void *info)
+{
+       pxa_register_device(&pxa_device_stuart, info);
+}
+
 static struct resource pxa_resource_hwuart[] = {
        {
                .start  = 0x41600000,
@@ -231,6 +246,14 @@ struct platform_device pxa_device_hwuart = {
        .num_resources  = ARRAY_SIZE(pxa_resource_hwuart),
 };
 
+void __init pxa_set_hwuart_info(void *info)
+{
+       if (cpu_is_pxa255())
+               pxa_register_device(&pxa_device_hwuart, info);
+       else
+               pr_info("UART: Ignoring attempt to register HWUART on non-PXA255 hardware");
+}
+
 static struct resource pxai2c_resources[] = {
        {
                .start  = 0x40301680,
index 74d3f89..8fde338 100644 (file)
@@ -55,6 +55,9 @@ static struct platform_device *devices[] __initdata = {
 
 static void __init e330_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        eseries_register_clks();
        eseries_get_tmio_gpios();
        platform_add_devices(devices, ARRAY_SIZE(devices));
index 0800362..f50f055 100644 (file)
@@ -56,6 +56,9 @@ static struct platform_device *devices[] __initdata = {
 
 static void __init e350_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        eseries_register_clks();
        eseries_get_tmio_gpios();
        platform_add_devices(devices, ARRAY_SIZE(devices));
index ed9c0c3..55b950f 100644 (file)
@@ -130,6 +130,9 @@ static struct platform_device *devices[] __initdata = {
 static void __init e400_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e400_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        /* Fixme - e400 may have a switched clock */
        eseries_register_clks();
        eseries_get_tmio_gpios();
index 49acdfa..94b23a9 100644 (file)
@@ -192,6 +192,9 @@ static struct platform_device *devices[] __initdata = {
 static void __init e740_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e740_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        eseries_register_clks();
        clk_add_alias("CLK_CK48M", e740_t7l66xb_device.name,
                        "UDCCLK", &pxa25x_device_udc.dev),
index 4052ece..5eccbce 100644 (file)
@@ -194,6 +194,9 @@ static struct platform_device *devices[] __initdata = {
 static void __init e750_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e750_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        clk_add_alias("CLK_CK3P6MI", e750_tc6393xb_device.name,
                        "GPIO11_CLK", NULL),
        eseries_get_tmio_gpios();
index 9866c7b..aad129b 100644 (file)
@@ -195,6 +195,9 @@ static struct platform_device *devices[] __initdata = {
 
 static void __init e800_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        clk_add_alias("CLK_CK3P6MI", e800_tc6393xb_device.name,
                        "GPIO11_CLK", NULL),
        eseries_get_tmio_gpios();
index aec7f42..e0b0fda 100644 (file)
@@ -1286,6 +1286,10 @@ static void __init em_x270_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(common_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
 #ifdef CONFIG_PM
        pxa27x_set_pwrmode(PWRMODE_DEEPSLEEP);
 #endif
index 588b265..48c1737 100644 (file)
@@ -693,6 +693,10 @@ static void __init a780_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen1_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(a780_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
 
        set_pxa_fb_info(&ezx_fb_info_1);
@@ -754,6 +758,10 @@ static void __init e680_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen1_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e680_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
        i2c_register_board_info(0, ARRAY_AND_SIZE(e680_i2c_board_info));
 
@@ -816,6 +824,10 @@ static void __init a1200_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen2_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(a1200_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
        i2c_register_board_info(0, ARRAY_AND_SIZE(a1200_i2c_board_info));
 
@@ -874,6 +886,10 @@ static void __init a910_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen2_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(a910_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
 
        set_pxa_fb_info(&ezx_fb_info_2);
@@ -935,6 +951,10 @@ static void __init e6_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen2_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e6_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
        i2c_register_board_info(0, ARRAY_AND_SIZE(e6_i2c_board_info));
 
@@ -971,6 +991,10 @@ static void __init e2_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gen2_pin_config));
        pxa2xx_mfp_config(ARRAY_AND_SIZE(e2_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        pxa_set_i2c_info(NULL);
        i2c_register_board_info(0, ARRAY_AND_SIZE(e2_i2c_board_info));
 
index 485fede..890fb90 100644 (file)
@@ -67,3 +67,8 @@ extern struct sysdev_class pxa_irq_sysclass;
 extern struct sysdev_class pxa_gpio_sysclass;
 extern struct sysdev_class pxa2xx_mfp_sysclass;
 extern struct sysdev_class pxa3xx_mfp_sysclass;
+
+void __init pxa_set_ffuart_info(void *info);
+void __init pxa_set_btuart_info(void *info);
+void __init pxa_set_stuart_info(void *info);
+void __init pxa_set_hwuart_info(void *info);
index 1708c01..96c3451 100644 (file)
@@ -211,6 +211,11 @@ static void __init gumstix_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(gumstix_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+       pxa_set_hwuart_info(NULL);
+
        gumstix_bluetooth_init();
        gumstix_udc_init();
        gumstix_mmc_init();
index f3d220c..c1cab08 100644 (file)
@@ -193,6 +193,9 @@ static void __init h5000_init(void)
        fix_msc();
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(h5000_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        pxa_set_udc_info(&h5000_udc_mach_info);
        platform_add_devices(ARRAY_AND_SIZE(devices));
 }
index cea99fe..f9a2e4b 100644 (file)
@@ -150,6 +150,9 @@ static void __init himalaya_lcd_init(void)
 
 static void __init himalaya_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        himalaya_lcd_init();
        platform_add_devices(devices, ARRAY_SIZE(devices));
 }
index 83bd3c6..6b3c90e 100644 (file)
@@ -849,6 +849,10 @@ static void __init hx4700_init(void)
        pxa2xx_mfp_config(ARRAY_AND_SIZE(hx4700_pin_config));
        hx4700_gpio_request(ARRAY_AND_SIZE(global_gpios));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_add_devices(devices, ARRAY_SIZE(devices));
 
        pxa_set_ficp_info(&ficp_info);
index b6486ef..5c9e11d 100644 (file)
@@ -179,6 +179,9 @@ static void __init idp_init(void)
        printk("idp_init()\n");
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(idp_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
 
        platform_device_register(&smc91x_device);
        //platform_device_register(&mst_audio_device);
index 2a4945d..5b0862d 100644 (file)
@@ -554,8 +554,12 @@ static struct i2c_pxa_platform_data i2c_pdata = {
 
 static void __init imote2_init(void)
 {
-
        pxa2xx_mfp_config(ARRAY_AND_SIZE(imote2_pin_config));
+
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        /* SPI chip select directions - all other directions should
         * be handled by drivers.*/
        gpio_direction_output(37, 0);
index ce5e617..f28c171 100644 (file)
@@ -413,6 +413,10 @@ static void __init littleton_init(void)
        /* initialize MFP configurations */
        pxa3xx_mfp_config(ARRAY_AND_SIZE(littleton_mfp_cfg));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        /*
         * Note: we depend bootloader set the correct
         * value to MSC register for SMC91x.
index d64395f..1373c22 100644 (file)
@@ -455,6 +455,10 @@ static void __init lpd270_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(lpd270_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        lpd270_flash_data[0].width = (BOOT_DEF & 1) ? 2 : 4;
        lpd270_flash_data[1].width = 4;
 
index c6a94d3..98ee7e5 100644 (file)
@@ -518,6 +518,10 @@ static void __init lubbock_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(lubbock_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        clk_add_alias("SA1111_CLK", NULL, "GPIO11_CLK", NULL);
        pxa_set_udc_info(&udc_info);
        set_pxa_fb_info(&sharp_lm8v31);
index 5360c07..8a38d60 100644 (file)
@@ -742,6 +742,10 @@ static void __init magician_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(magician_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_add_devices(ARRAY_AND_SIZE(devices));
 
        err = gpio_request(GPIO83_MAGICIAN_nIR_EN, "nIR_EN");
index a4eeae3..851ee0f 100644 (file)
@@ -576,6 +576,10 @@ static void __init mainstone_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(mainstone_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        mst_flash_data[0].width = (BOOT_DEF & 1) ? 2 : 4;
        mst_flash_data[1].width = 4;
 
index 3cab452..2466a44 100644 (file)
@@ -798,6 +798,9 @@ static void __init mioa701_machine_init(void)
        UP2OCR = UP2OCR_HXOE;
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(mioa701_pin_config));
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        mio_gpio_request(ARRAY_AND_SIZE(global_gpios));
        bootstrap_init();
        set_pxa_fb_info(&mioa701_pxafb_info);
index a65713c..6d45039 100644 (file)
@@ -84,6 +84,9 @@ static struct platform_device *devices[] __initdata = {
 static void __init mp900c_init(void)
 {
        printk(KERN_INFO "MobilePro 900/C machine init\n");
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
        platform_add_devices(devices, ARRAY_SIZE(devices));
 }
 
index 1ad029d..5914021 100644 (file)
@@ -530,6 +530,10 @@ static void __init palmld_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmld_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        palmld_pm_init();
        set_pxa_fb_info(&palmld_lcd_screen);
        pxa_set_mci_info(&palmld_mci_platform_data);
index 2dd7ce2..7f89ca2 100644 (file)
@@ -419,6 +419,10 @@ static void __init palmt5_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmt5_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        palmt5_pm_init();
        set_pxa_fb_info(&palmt5_lcd_screen);
        pxa_set_mci_info(&palmt5_mci_platform_data);
index 0b92291..3084175 100644 (file)
@@ -416,6 +416,11 @@ static void __init palmtc_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmtc_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+       pxa_set_hwuart_info(NULL);
+
        set_pxa_fb_info(&palmtc_lcd_screen);
        pxa_set_mci_info(&palmtc_mci_platform_data);
        pxa_set_udc_info(&palmtc_udc_info);
index 277c406..265d62b 100644 (file)
@@ -373,6 +373,10 @@ static void __init palmte2_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmte2_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        set_pxa_fb_info(&palmte2_lcd_screen);
        pxa_set_mci_info(&palmte2_mci_platform_data);
        palmte2_udc_init();
index c071b60..606eb7e 100644 (file)
@@ -653,6 +653,10 @@ static void __init treo_lcd_power_init(void)
 
 static void __init treo_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        treo_pm_init();
        pxa2xx_mfp_config(ARRAY_AND_SIZE(treo_pin_config));
        treo_lcd_power_init();
index 76a2b37..7bf18c2 100644 (file)
@@ -570,6 +570,10 @@ static void __init palmtx_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmtx_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        palmtx_pm_init();
        set_pxa_fb_info(&palmtx_lcd_screen);
        pxa_set_mci_info(&palmtx_mci_platform_data);
index c2bf493..d787ac7 100644 (file)
@@ -491,6 +491,10 @@ static void __init palmz72_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(palmz72_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        set_pxa_fb_info(&palmz72_lcd_screen);
        pxa_set_mci_info(&palmz72_mci_platform_data);
        palmz72_udc_init();
index 6abfa29..2190af0 100644 (file)
@@ -227,6 +227,10 @@ static void __init pcm027_init(void)
 
        pxa2xx_mfp_config(pcm027_pin_config, ARRAY_SIZE(pcm027_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_add_devices(devices, ARRAY_SIZE(devices));
 
        /* at last call the baseboard to initialize itself */
index a186994..e5eeb3a 100644 (file)
@@ -449,6 +449,10 @@ static void __init poodle_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(poodle_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_scoop_config = &poodle_pcmcia_config;
 
        ret = platform_add_devices(devices, ARRAY_SIZE(devices));
index 77c2693..2c1b0b7 100644 (file)
@@ -322,9 +322,6 @@ void __init pxa26x_init_irq(void)
 
 static struct platform_device *pxa25x_devices[] __initdata = {
        &pxa25x_device_udc,
-       &pxa_device_ffuart,
-       &pxa_device_btuart,
-       &pxa_device_stuart,
        &pxa_device_i2s,
        &sa1100_device_rtc,
        &pxa25x_device_ssp,
@@ -372,10 +369,8 @@ static int __init pxa25x_init(void)
        }
 
        /* Only add HWUART for PXA255/26x; PXA210/250 do not have it. */
-       if (cpu_is_pxa255()) {
+       if (cpu_is_pxa255())
                clks_register(&pxa25x_hwuart_clkreg, 1);
-               ret = platform_device_register(&pxa_device_hwuart);
-       }
 
        return ret;
 }
index ec68cc1..6a0b731 100644 (file)
@@ -364,9 +364,6 @@ void __init pxa27x_set_i2c_power_info(struct i2c_pxa_platform_data *info)
 
 static struct platform_device *devices[] __initdata = {
        &pxa27x_device_udc,
-       &pxa_device_ffuart,
-       &pxa_device_btuart,
-       &pxa_device_stuart,
        &pxa_device_i2s,
        &sa1100_device_rtc,
        &pxa_device_rtc,
index ca536f2..3198680 100644 (file)
@@ -555,9 +555,6 @@ void __init pxa3xx_set_i2c_power_info(struct i2c_pxa_platform_data *info)
 
 static struct platform_device *devices[] __initdata = {
        &pxa27x_device_udc,
-       &pxa_device_ffuart,
-       &pxa_device_btuart,
-       &pxa_device_stuart,
        &pxa_device_i2s,
        &sa1100_device_rtc,
        &pxa_device_rtc,
index 3cccb08..115b6f2 100644 (file)
@@ -583,6 +583,10 @@ static void __init saar_init(void)
        /* initialize MFP configurations */
        pxa3xx_mfp_config(ARRAY_AND_SIZE(saar_mfp_cfg));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_device_register(&smc91x_device);
        saar_init_onenand();
 
index 3da45d0..bbd7a85 100644 (file)
@@ -768,6 +768,10 @@ static void __init common_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(spitz_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        spitz_init_spi();
 
        platform_add_devices(devices, ARRAY_SIZE(devices));
index 3b205b6..a98a434 100644 (file)
@@ -760,6 +760,10 @@ static void __init stargate2_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(stargate2_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        /* spi chip selects */
        gpio_direction_output(37, 0);
        gpio_direction_output(24, 0);
index b75353a..f02dcb5 100644 (file)
@@ -477,6 +477,10 @@ static void __init tavorevb_init(void)
        /* initialize MFP configurations */
        pxa3xx_mfp_config(ARRAY_AND_SIZE(tavorevb_mfp_cfg));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        platform_device_register(&smc91x_device);
 
        tavorevb_init_lcd();
index e81a526..c854c16 100644 (file)
@@ -825,6 +825,11 @@ static void __init tosa_init(void)
        int dummy;
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(tosa_pin_config));
+
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        gpio_set_wake(MFP_PIN_GPIO1, 1);
        /* We can't pass to gpio-keys since it will drop the Reset altfunc */
 
index 3981e03..0aa858e 100644 (file)
@@ -524,6 +524,10 @@ static void __init trizeps4_init(void)
                                        ARRAY_SIZE(trizeps4_devices));
        }
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        if (0)  /* dont know how to determine LCD */
                set_pxa_fb_info(&sharp_lcd);
        else
index d33c232..6c36bd9 100644 (file)
@@ -908,6 +908,10 @@ static void __init viper_init(void)
 
        pxa2xx_mfp_config(ARRAY_AND_SIZE(viper_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        /* Wake-up serial console */
        viper_init_serial_gpio();
 
index 3fd79cb..d3b4e3f 100644 (file)
@@ -165,6 +165,11 @@ static void __init xcep_init(void)
 {
        pxa2xx_mfp_config(ARRAY_AND_SIZE(xcep_pin_config));
 
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+       pxa_set_hwuart_info(NULL);
+
        /* See Intel XScale Developer's Guide for details */
        /* Set RDF and RDN to appropriate values (chip select 3 (smc91x)) */
        MSC1 = (MSC1 & 0xffff) | 0xD5540000;
index 8fcb694..b66e9e2 100644 (file)
@@ -444,6 +444,10 @@ static inline void zylonite_init_ohci(void) {}
 
 static void __init zylonite_init(void)
 {
+       pxa_set_ffuart_info(NULL);
+       pxa_set_btuart_info(NULL);
+       pxa_set_stuart_info(NULL);
+
        /* board-processor specific initialization */
        zylonite_pxa300_init();
        zylonite_pxa320_init();