[PATCH] ppc32: Fix pointer check for MPC8540 ADS device
authorKumar Gala <galak@freescale.com>
Thu, 30 Jun 2005 09:58:55 +0000 (02:58 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Thu, 30 Jun 2005 15:45:09 +0000 (08:45 -0700)
Editor snafu in which the call to ppc_sys_get_pdata got inside the if check
instead of before it.  Oops.

Signed-off-by: Kumar Gala <kumar.gala@freescale.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/ppc/platforms/85xx/mpc8540_ads.c

index ddd2e9a5bb121306863ce560ca48c967f562277a..f761fdf160db5ee353c8cd56518f45ac955102f6 100644 (file)
@@ -111,8 +111,8 @@ mpc8540ads_setup_arch(void)
                memcpy(pdata->mac_addr, binfo->bi_enet1addr, 6);
        }
 
+       pdata = (struct gianfar_platform_data *) ppc_sys_get_pdata(MPC85xx_FEC);
        if (pdata) {
-               pdata = (struct gianfar_platform_data *) ppc_sys_get_pdata(MPC85xx_FEC);
                pdata->board_flags = 0;
                pdata->interruptPHY = MPC85xx_IRQ_EXT5;
                pdata->phyid = 3;