X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=arch%2Fpowerpc%2Fplatforms%2F82xx%2Fpq2fads.c;h=e1dceeec49944aba3e07ecb967abe37e07c822bf;hb=14ed74fbe2b917f0ad3e30cf2644203c04a45e89;hp=4f457a9c79aebee64db8e8e717147cf6ac852c20;hpb=3611f2ad424094655d381f099613a6f43239824d;p=linux-2.6-omap-h63xx.git diff --git a/arch/powerpc/platforms/82xx/pq2fads.c b/arch/powerpc/platforms/82xx/pq2fads.c index 4f457a9c79a..e1dceeec499 100644 --- a/arch/powerpc/platforms/82xx/pq2fads.c +++ b/arch/powerpc/platforms/82xx/pq2fads.c @@ -15,12 +15,12 @@ #include #include #include +#include #include #include #include #include -#include #include #include @@ -130,13 +130,12 @@ static void __init pq2fads_setup_arch(void) } bcsr = of_iomap(np, 0); + of_node_put(np); if (!bcsr) { printk(KERN_ERR "Cannot map BCSR registers\n"); return; } - of_node_put(np); - /* Enable the serial and ethernet ports */ clrbits32(&bcsr[1], BCSR1_RS232_EN1 | BCSR1_RS232_EN2 | BCSR1_FETHIEN); @@ -176,14 +175,11 @@ static struct of_device_id __initdata of_bus_ids[] = { static int __init declare_of_platform_devices(void) { - if (!machine_is(pq2fads)) - return 0; - /* Publish the QE devices */ of_platform_bus_probe(NULL, of_bus_ids, NULL); return 0; } -device_initcall(declare_of_platform_devices); +machine_device_initcall(pq2fads, declare_of_platform_devices); define_machine(pq2fads) {