[U-Boot] bav335x support broken
Folks, I posted a patch to add support for bav335x boards (a322aad99de4). The patch was tested against v2015.04-rc1 and worked perfectly but somehow, something was introduced since then which breaks the board support. There are two main errors I need to fix before posting another patch but need help with the second error. The first error is easy. Compilation throws: #error "Please define NS16550 registers size." which I can simply fix by defining CONFIG_SYS_NS16550_REG_SIZE in include/configs/bav335x.h ((( Altough I am stil puzzled as to why this was defined as -4 (where?) on v2015.04-rc1 ))) After adding the define, everything compiles up to failing on the final link with: drivers/serial/built-in.o: In function `get_current': /home/gilles/bbdev/u-boot/drivers/serial/serial.c:389: undefined reference to `default_serial_console' drivers/serial/built-in.o: In function `serial_initialize': Can anyone please explain what changed between 2015.04-rc1 and 2015.04-rc2 which could cause such a behavior? I have spent the last couple hours re-basing a branch to see where it breaks as to maybe get a clue on what changed but no luck so far. Any tips would be appreciated. Thanks, Gilles . ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v5 0/8] Extend LPC32xx functionality and add LPC32xx-based work_92015 board
Hi Simon, Le Fri, 13 Mar 2015 18:33:51 -0600, Simon Glass a écrit : > Hi Albert, > > On 13 March 2015 at 02:04, Albert ARIBAUD (3ADEV) > wrote: > > This series extends functionality for the LPC32xx platform and > > introduces the WORK Microwave work_92105 board which makes use > > of the extended functionality. > > > > NOTES: > > > > A - I2C driver remains non-DM > > > > During v2 review, it was suggested to move to DM for I2C. However, > > this caused issues with the 'date', 'dtt' and 'eeprom' commands which > > are configured in this board. Therefore the I2C move to DM was not > > done. > > Does CONFIG_DM_I2C_COMPAT help with this? If you define that you get > the old API. Nope, I tried CONFIG_I2C_COMPAT as soon as I hit the errors, and itdid not fix things. > Otherwise if you can share the (broken) patches I can take a look at > how to fix those commands. I'll push a branch on Monday for this. > Regards, > Simon Cordialement, Albert ARIBAUD 3ADEV ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] odroid: defconfig: fix build break caused by missing dts
On 12 March 2015 at 17:58, Lukasz Majewski wrote: > Hi Tom, > > > The build break was caused by one of my previous commit: > > 'odroid: defconfig: disable memset at malloc init' > > > > It removes the dts from odroid defconfig - rebase mistake. > > > > Signed-off-by: Przemyslaw Marczak > > Cc: Minkyu Kang > > --- > > configs/odroid_defconfig | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/configs/odroid_defconfig b/configs/odroid_defconfig > > index cfb29e0..d32b5b5 100644 > > --- a/configs/odroid_defconfig > > +++ b/configs/odroid_defconfig > > @@ -2,6 +2,7 @@ CONFIG_ARM=y > > CONFIG_ARCH_EXYNOS=y > > CONFIG_TARGET_ODROID=y > > CONFIG_OF_CONTROL=y > > +CONFIG_DEFAULT_DEVICE_TREE="exynos4412-odroid" > > CONFIG_DM_I2C=y > > CONFIG_DM_I2C_COMPAT=y > > # CONFIG_SYS_MALLOC_CLEAR_ON_INIT is not set > > Tom, could you fetch this fix patch ? Thanks in advance. > > -- > Best regards, > > Lukasz Majewski > > Samsung R&D Institute Poland (SRPOL) | Linux Platform Group > ___ > U-Boot mailing list > U-Boot@lists.denx.de > http://lists.denx.de/mailman/listinfo/u-boot > Acked-by: Minkyu Kang -- from. prom. www.promsoft.net ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v5 2/8] lpc32xx: mtd: nand: add MLC NAND controller
Bonjour Scott, Le Fri, 13 Mar 2015 16:57:33 -0500, Scott Wood a écrit : > On Fri, 2015-03-13 at 09:04 +0100, Albert ARIBAUD (3ADEV) wrote: > > + /* go through all four small pages */ > > + for (i = 0; i < 4; i++) { > > + /* start auto decode (reads 528 NAND bytes) */ > > + writel(0, &lpc32xx_nand_mlc_registers->ecc_auto_dec_reg); > > + /* wait for controller to return to ready state */ > > + timeout = LPC32X_NAND_TIMEOUT; > > + do { > > + if (timeout-- == 0) > > + return -1; > > + status = readl(&lpc32xx_nand_mlc_registers->isr); > > + } while (!(status & ISR_CONTROLLER_READY)); > > How much time does 1 reads of this register equate to? Are you sure > it's enough? Timeouts should generally be in terms of time, not loop > iterations. I followed the examples in several drivers where timeouts are by iteration. Note that -- while this does not void your point -- I did not use 1 but 10, which at a CPU clock of 208 MHz, and assuming an optimistic one instruction per cycle and two instructions per loop, makes the loop last at least 960 us, well over the 600 us which the NAND takes for any page programming. > > +static int read_single_page(uint8_t *dest, int page, > > + struct lpc32xx_oob *oob) > > +{ > > + int status, i, timeout, err, max_bitflips = 0; > > + > > + /* enter read mode */ > > + writel(NAND_CMD_READ0, &lpc32xx_nand_mlc_registers->cmd); > > + /* send column (lsb then MSB) and page (lsb to MSB) */ > > + writel(0, &lpc32xx_nand_mlc_registers->addr); > > + writel(0, &lpc32xx_nand_mlc_registers->addr); > > + writel(page & 0xff, &lpc32xx_nand_mlc_registers->addr); > > + writel((page>>8) & 0xff, &lpc32xx_nand_mlc_registers->addr); > > + writel((page>>16) & 0xff, &lpc32xx_nand_mlc_registers->addr); > > + /* start reading */ > > + writel(NAND_CMD_READSTART, &lpc32xx_nand_mlc_registers->cmd); > > + > > + /* large page auto decode read */ > > + for (i = 0; i < 4; i++) { > > + /* start auto decode (reads 528 NAND bytes) */ > > + writel(0, &lpc32xx_nand_mlc_registers->ecc_auto_dec_reg); > > + /* wait for controller to return to ready state */ > > + timeout = LPC32X_NAND_TIMEOUT; > > + do { > > + if (timeout-- == 0) > > + return -1; > > + status = readl(&lpc32xx_nand_mlc_registers->isr); > > + } while (!(status & ISR_CONTROLLER_READY)) > > + ; > > + /* return -1 if hard error */ > > + if (status & ISR_DECODER_FAILURE) > > + return -1; > > + /* keep count of maximum bitflips performed */ > > + if (status & ISR_DECODER_ERROR) { > > + err = ISR_DECODER_ERRORS(status); > > + if (err > max_bitflips) > > + max_bitflips = err; > > + } > > + /* copy first 512 bytes into buffer */ > > + memcpy(dest+i*512, lpc32xx_nand_mlc_registers->buff, 512); > > + /* copy next 6 bytes bytes into OOB buffer */ > > + memcpy(&oob->free[i], lpc32xx_nand_mlc_registers->buff, 6); > > + } > > + return max_bitflips; > > +} > > + > > Why keep track of max_bitflips if the caller doesn't use it? Because I modeled read_single_page from another read function, and I preferred to minimize modifications and keep returning as much info as I have, which can help debugging and cannot cause harm as it does not affect the caller indeed. > > +#define LARGE_PAGE_SIZE 2048 > > + > > +int nand_spl_load_image(uint32_t offs, unsigned int size, void *dst) > > +{ > > + struct lpc32xx_oob oob; > > + unsigned int page = offs / LARGE_PAGE_SIZE; > > + unsigned int left = DIV_ROUND_UP(size, LARGE_PAGE_SIZE); > > + > > + while (left) { > > + int res = read_single_page(dst, page, &oob); > > + page++; > > + /* if read succeeded, even if fixed by ECC */ > > + if (res >= 0) { > > + /* skip bad block */ > > + if (oob.free[0].free_oob_bytes[0] != 0xff) > > + continue; > > + if (oob.free[0].free_oob_bytes[1] != 0xff) > > + continue; > > + /* page is good, keep it */ > > + dst += LARGE_PAGE_SIZE; > > + left--; > > + } > > You should be checking the designated page(s) of the block, rather than > the current page, for the bad block markers -- and skipping the entire > block if it's bad. Will fix this -- is there any helper function in the bad block management code for this? I could not find one, but I'm no NAND expert. > Also, if you fail ECC, that should be a fatal error, not something to > silently skip. Will fix. > -Scott Cordialement, Albert ARIBAUD 3ADEV __
Re: [U-Boot] bav335x support broken
Hi Gilles, This u-boot version is having lot of changes , they have enabled Kconfig similar to Kernel and having GUI support ( make menuconfig) . so if you are gettting error as you mentioned , try to add Device model configurations and SYS malloc() as : Steps 1 make Step 2 make menuconfig Step 3 Device driver -> Enable driver model, enable Driver model for serial) Step 4 malloc() pool , General setup --> Enable malloc() pool. Please try this , I think it will work. Thanks, Anish On Sat, Mar 14, 2015 at 10:36 AM, Gilles wrote: > Folks, > > I posted a patch to add support for bav335x boards (a322aad99de4). The patch > was tested against v2015.04-rc1 and worked perfectly but somehow, something > was introduced since then which breaks the board support. > > There are two main errors I need to fix before posting another patch but need > help with the second error. > > The first error is easy. Compilation throws: > #error "Please define NS16550 registers size." > which I can simply fix by defining CONFIG_SYS_NS16550_REG_SIZE in > include/configs/bav335x.h > ((( Altough I am stil puzzled as to why this was defined as -4 (where?) on > v2015.04-rc1 ))) > > After adding the define, everything compiles up to failing on the final link > with: > > drivers/serial/built-in.o: In function `get_current': > /home/gilles/bbdev/u-boot/drivers/serial/serial.c:389: undefined reference to > `default_serial_console' > drivers/serial/built-in.o: In function `serial_initialize': > > Can anyone please explain what changed between 2015.04-rc1 and 2015.04-rc2 > which could cause such a behavior? I have spent the last couple hours > re-basing a branch to see where it breaks as to maybe get a clue on what > changed but no luck so far. Any tips would be appreciated. > > Thanks, > Gilles > . > > > > ___ > U-Boot mailing list > U-Boot@lists.denx.de > http://lists.denx.de/mailman/listinfo/u-boot ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] Commit 7ae47f6b causes a warning
Hello Hannes, On Tue, 3 Feb 2015 13:22:34 +0100, Hannes Petermaier wrote: > diff --git a/include/configs/bur_am335x_common.h > b/include/configs/bur_am335x_common.h > index e9d5d01..d7ea1c9 100644 > --- a/include/configs/bur_am335x_common.h > +++ b/include/configs/bur_am335x_common.h > @@ -12,6 +12,23 @@ > #ifndef __BUR_AM335X_COMMON_H__ > #define __BUR_AM335X_COMMON_H__ > /* - > */ > +#define BUR_COMMON_ENV \ > +"defaultip=192.168.60.253\0" \ > +"defaultsip=192.168.60.254\0" \ > +"netconsole=echo switching to network console ...; " \ > +"if dhcp; then " \ > +"setenv ncip ${serverip}; else " \ > +"setenv ncip 192.168.60.254; " \ > +"setenv serverip 192.168.60.254; " \ > +"setenv gatewayip 192.168.60.254; " \ > +"setenv ipaddr 192.168.60.1; " \ > +"fi;" \ > +"setenv netdisplay0 '" \ > +"setcurs 1 9; puts myip; setcurs 10 9; puts ${ipaddr};" \ > +"setcurs 1 10;puts serverip; setcurs 10 10; puts ${serverip}\;'" \ This line contains a '\;' sequence which gcc warns against: cc1: warning: unknown escape sequence: '\;' [enabled by default] Could you post a fix? Amicalement, -- Albert. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] bav335x support broken
Hello Anish, (apologies for any duplicates. My mail server and the U-Boot ML are playing tricks with my sanity.) On Sat, 14 Mar 2015 23:25:03 +0530, Anish Khurana wrote: > Hi Gilles, > > This u-boot version is having lot of changes , they have enabled > Kconfig similar to Kernel and having GUI support ( make menuconfig) . > so if you are gettting error as you mentioned , try to add Device > model configurations and SYS malloc() as : > > Steps 1 make > Step 2 make menuconfig > Step 3 Device driver -> Enable driver model, enable Driver model for serial) > Step 4 malloc() pool , General setup --> Enable malloc() pool. > > Please try this , I think it will work. Thanks Anish for pointing this out. I just saw this in my all-ARM build. If this fix works, then the defconfig for both birdland_bav335a and birdland_bav335b should be adjusted so as not to need the manual menuconfig fix. > Thanks, > Anish Amicalement, -- Albert. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 1/2] MAINTAINERS: update Masahiro's email address
2015-03-11 13:01 GMT+09:00 Masahiro Yamada : > I have transferred to Socionext Inc. > > Signed-off-by: Masahiro Yamada Applied to u-boot-uniphier/master. -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH 2/2] git-mailrc: update Masahiro's email address
2015-03-11 13:01 GMT+09:00 Masahiro Yamada : > I have transferred to Socionext Inc. > > Signed-off-by: Masahiro Yamada Applied to u-boot-uniphier/master. -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] ARM: UniPhier: adjust device trees for business transfer
2015-03-11 15:54 GMT+09:00 Masahiro Yamada : > Panasonic's System LSI products, UniPhier SoC family, have been > transferred to Socionext Inc. > > Signed-off-by: Masahiro Yamada Applied to u-boot-uniphier/master. -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] Pull request: u-boot-uniphier
Hi Tom, The following changes since commit b79dadf846e5e140e261bbfa4decd024357702d7: Merge branch 'master' of git://git.denx.de/u-boot-tegra (2015-03-10 19:09:18 -0400) are available in the git repository at: git://git.denx.de/u-boot-uniphier.git master for you to fetch changes up to 6462cdedc20b08ff5aa402a991ec89b3255ba51d: ARM: UniPhier: adjust device trees for business transfer (2015-03-15 13:37:00 +0900) Masahiro Yamada (3): MAINTAINERS: update Masahiro's email address git-mailrc: update Masahiro's email address ARM: UniPhier: adjust device trees for business transfer MAINTAINERS | 2 +- arch/arm/dts/uniphier-ph1-ld4-ref.dts | 7 --- arch/arm/dts/uniphier-ph1-ld4.dtsi | 27 ++- arch/arm/dts/uniphier-ph1-pro4-ref.dts | 7 --- arch/arm/dts/uniphier-ph1-pro4.dtsi | 33 + arch/arm/dts/uniphier-ph1-sld3-ref.dts | 7 --- arch/arm/dts/uniphier-ph1-sld3.dtsi | 27 ++- arch/arm/dts/uniphier-ph1-sld8-ref.dts | 7 --- arch/arm/dts/uniphier-ph1-sld8.dtsi | 27 ++- arch/arm/dts/uniphier-ref-daughter.dtsi | 3 ++- doc/git-mailrc | 2 +- drivers/i2c/i2c-uniphier-f.c| 7 --- drivers/i2c/i2c-uniphier.c | 7 --- drivers/serial/serial_uniphier.c| 7 --- drivers/usb/host/ehci-uniphier.c| 5 +++-- drivers/usb/host/xhci-uniphier.c| 5 +++-- include/fdtdec.h| 2 +- lib/fdtdec.c| 2 +- 18 files changed, 99 insertions(+), 85 deletions(-) -- Best Regards Masahiro Yamada ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH] imx: mx6sx fix pad property macro definition
Fix PAD_CTL_SPEED_LOW pad property macro definition. PAT_CTL_SPEED_LOW occupies the 6th and 7th bit. To mx6sx: 0 0 | 50MHZ — Low(50 MHz) 0 1 | 100MHZ — Medium (100 MHz) 1 0 | 100MHZ — Medium (100 MHz) 1 1 | 200MHZ — Maximum (200 MHz) To Other mx6 socs: 0 0 | RESERVED0 — Reserved 0 1 | 50MHZ — Low (50 MHz) 1 0 | 100MHZ — Medium (100 MHz) 1 1 | 200MHZ — Maximum (200 MHz) Signed-off-by: Peng Fan --- arch/arm/include/asm/imx-common/iomux-v3.h | 4 1 file changed, 4 insertions(+) diff --git a/arch/arm/include/asm/imx-common/iomux-v3.h b/arch/arm/include/asm/imx-common/iomux-v3.h index e0a49be..5c31eb3 100644 --- a/arch/arm/include/asm/imx-common/iomux-v3.h +++ b/arch/arm/include/asm/imx-common/iomux-v3.h @@ -98,7 +98,11 @@ typedef u64 iomux_v3_cfg_t; #define PAD_CTL_ODE(1 << 11) +#ifdef CONFIG_MX6SX +#define PAD_CTL_SPEED_LOW (0 << 6) +#else #define PAD_CTL_SPEED_LOW (1 << 6) +#endif #define PAD_CTL_SPEED_MED (2 << 6) #define PAD_CTL_SPEED_HIGH (3 << 6) -- 1.8.4 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH] mmc: fsl_esdhc fix register offset
Hi, On 3/11/2015 9:00 PM, Fabio Estevam wrote: On Tue, Mar 10, 2015 at 4:35 AM, Peng Fan wrote: Commit f022d36e8a4517b2a9d25ff2d75bd2459d0c68b1 introduces error register offset. Change the "char reserved3[59]" to "char reserved3[56]". Signed-off-by: Peng Fan On a imx6sl-warp: Tested-by: Fabio Estevam Just kindly ask, will this patch be applied? Regards, Peng. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot