[U-Boot] [PATCH] mx53loco: Fix PMIC name

Robert Nelson robertcnelson at gmail.com
Wed Dec 26 16:51:17 CET 2012


Hi Fabio,

On Wed, Dec 26, 2012 at 9:21 AM, Fabio Estevam <festevam at gmail.com> wrote:
> Robert,
>
> On Wed, Dec 26, 2012 at 1:07 PM, Fabio Estevam <festevam at gmail.com> wrote:
>> On Wed, Dec 26, 2012 at 1:02 PM, Fabio Estevam <festevam at gmail.com> wrote:
>>
>>> With the new PMIC framework: is it safe to call the PMIC API from
>>> board_init function?
>>
>> Calling it from board_late_init fixes the issue for me.
>>
>> Will send the patch soon.
>
> Can you try the patch below?

Thanks for taking a look at this..

>
> board/freescale/mx53loco/mx53loco.c |   10 ++++++++--
>  include/configs/mx53loco.h          |    1 +
>  2 files changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/board/freescale/mx53loco/mx53loco.c
> b/board/freescale/mx53loco/mx53loco.c
> index 2c8cb7a..63a4f8b 100644
> --- a/board/freescale/mx53loco/mx53loco.c
> +++ b/board/freescale/mx53loco/mx53loco.c
> @@ -462,12 +462,18 @@ int board_init(void)
>
>         mxc_set_sata_internal_clock();
>         setup_iomux_i2c();
> +
> +       lcd_enable();
> +
> +       return 0;
> +}
> +
> +int board_late_init(void)
> +{
>         if (!power_init())
>                 clock_1GHz();
>         print_cpuinfo();
>
> -       lcd_enable();
> -
>         return 0;
>  }
>
> diff --git a/include/configs/mx53loco.h b/include/configs/mx53loco.h
> index e30502b..c4181bd 100644
> --- a/include/configs/mx53loco.h
> +++ b/include/configs/mx53loco.h
> @@ -39,6 +39,7 @@
>  #define CONFIG_SYS_MALLOC_LEN          (10 * 1024 * 1024)
>
>  #define CONFIG_BOARD_EARLY_INIT_F
> +#define CONFIG_BOARD_LATE_INIT

Ah, i was missing this when heading down the "board_late_init" road on friday..

>  #define CONFIG_MXC_GPIO
>  #define CONFIG_REVISION_TAG
>
> --
> 1.7.9.5
>
>
> It boots now, but I get resets now:
>
> U-Boot 2013.01-rc2-00172-gf8cfcf1-dirty (Dec 26 2012 - 13:13:28)
>
> Board: MX53 LOCO
> I2C:   ready
> DRAM:  1 GiB
> MMC:   FSL_SDHC: 0, FSL_SDHC: 1
> In:    serial
> Out:   serial
> Err:   serial
> CPU:   Freescale i.MX53 family rev2.1 at 1000 MHz
> Reset cause: WDOG
> Net:   FEC
> Warning: FEC using MAC address from net device

Interesting, I'm still only getting this far on the old Dialog board..

U-Boot 2013.01-rc2-00173-gd781d95-dirty (Dec 26 2012 - 09:42:43)

Board: MX53 LOCO
I2C:   ready
DRAM:  1 GiB

I'm going to start printf'ing:
http://git.denx.de/?p=u-boot.git;a=blob;f=drivers/power/power_dialog.c
 as we aren't getting the memory error, so it should be atleast past
that...


> Hit any key to stop autoboot:  0
> data abort
>
>     MAYBE you should read doc/README.arm-unaligned-accesses
>
> pc : [<aff72220>]          lr : [<aff721fc>]
> sp : af565e20  ip : af566918     fp : 00000000
> r10: 00000003  r9 : affabb5b     r8 : af565f58
> r7 : 00000000  r6 : 36747fff     r5 : af5668e8  r4 : 36747fff
> r3 : af5668ec  r2 : af5668eb     r1 : 00000000  r0 : af5668e8
> Flags: NzcV  IRQs off  FIQs off  Mode SVC_32
> Resetting CPU ...
>
> resetting ...

I've reverted this just to double check (no change for me...):
http://git.denx.de/?p=u-boot.git;a=commit;h=28e5ac2d974547bde0c72aa0c1d66fd22c6ef3ad


> U-Boot 2013.01-rc2-00172-gf8cfcf1-dirty (Dec 26 2012 - 13:13:28)
>
> Board: MX53 LOCO
> I2C:   ready
> DRAM:  1 GiB
>
>
> but it looks like a separate issue?

Regards,

-- 
Robert Nelson
http://www.rcn-ee.com/


More information about the U-Boot mailing list