Re: [U-Boot] [PATCH V3 00/14] ARM: AM43xx: Update support for AM4372 SoC

2013-12-15 Thread Vaibhav Bedia
Hi Lokesh,

On Tue, Dec 10, 2013 at 4:32 AM, Lokesh Vutla lokeshvu...@ti.com wrote:
 This Patch series updates support for AM4372 EPOS and GP EVM boards.
 AM4372 is a low cost Cortex-A9 based application processor targeted at 
 existing
 ARM9/ARM11 base of customers that need more processing capabilities.
 Currently there are two boards with AM4372 SoC: EPOS and GP EVM.
 Except for few differences like oscillator clock and SDRAM both EPOS and GP 
 EVM
 boards are similar.
 EPOS EVM:
 OSC clk : 25MHz
 DDR : LPDDR2 @ 266MHz (MT42L256M32D2LG-25 WT:A)
 GP EVM:
 OSC clk : 24MHz
 DDR : DDR3 @ 400MHz(MT41K512M8RH)

 This patch series is applied on top of Mainline U-Boot Tree and two
 patches mentioned below:
 git://git.denx.de/u-boot.git master
http://patchwork.ozlabs.org/patch/288175/


This series looks good to me. So FWIW

Reviewed-by: Vaibhav Bedia vaibhav.be...@gmail.com
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 1/2] snowball: Add networking support

2013-12-15 Thread Roy Spliet
Dear Jagan,

Thanks for the feedback. I will check the patch and split it up in two. This 
fix is derived from the igloocommunity github u-boot repository, but their 
implementation was a bit too ad-hoc for my taste, using #ifdef CONFIG_SNOWBALL 
to override the alignment of the smc911x driver. I added the delay based on 
trial-and-error, and without the delay the device would not be detected 
correctly. Perhaps 25ms is a little bit too long, but since I have no 
documentation to back the exact value up I guess this will just do. If you 
please I can experiment with shorter periods, but I personally feel it's not 
worth the effort and risks having a u-boot that doesn't work based on physical 
properties of the device (and thus appears to fail randomly).
Yours,

Roy


--- Ursprüngliche Nachricht ---
Von: Jagan Teki jagannadh.t...@gmail.com
Datum: 18:07:30 14-12-2013
An: Roy Spliet rspl...@eclipso.eu
Betreff: Re: [U-Boot] [PATCH 1/2] snowball: Add networking support

 Try to fix - checkpatch.pl issues.
 total: 2 errors, 4 warnings, 0 checks, 74 lines checked

 On Sat, Dec 14, 2013 at 10:09 PM, Roy Spliet rspl...@eclipso.eu wrote:

  Signed-off-by: Roy Spliet rspl...@eclipso.eu
  ---
   board/st-ericsson/snowball/snowball.c | 11 +++
   drivers/net/smc911x.h | 14 ++
   include/configs/snowball.h| 14 ++
   3 files changed, 35 insertions(+), 4 deletions(-)
 
  diff --git a/board/st-ericsson/snowball/snowball.c 
  b/board/st-ericsson/snowball/snowball.c

  index c3061e2..356beb1 100644
  --- a/board/st-ericsson/snowball/snowball.c
  +++ b/board/st-ericsson/snowball/snowball.c
  @@ -245,6 +245,8 @@ int board_late_init(void)
  while (tstc())
  (void) getc();
 
  +   mdelay(25);
  +
  return 0;
   }
 
  @@ -338,3 +340,12 @@ int board_mmc_init(bd_t *bis)
  return 0;
   }
   #endif /* CONFIG_MMC */
  +
  +int board_eth_init(bd_t *bis)
  +{
  +   int error = smc911x_initialize(0, CONFIG_SMC911X_BASE);
  +   if(error)
  +   return error;
  +
  +   return cpu_eth_init(bis);
  +}

 TAG++
  diff --git a/drivers/net/smc911x.h b/drivers/net/smc911x.h
  index acae0cf..7fe55f1 100644
  --- a/drivers/net/smc911x.h
  +++ b/drivers/net/smc911x.h
  @@ -19,6 +19,12 @@
  CONFIG_SMC911X_16_BIT shall be set
   #endif
 
  +#ifndef CONFIG_SMC911X_SHIFT
  +#define CONFIG_SMC911X_SHIFT 0
  +#endif
  +
  +#define smc911x_shift(i) ((i)  CONFIG_SMC911X_SHIFT)
  +
   #if defined (CONFIG_SMC911X_32_BIT)
   static inline u32 __smc911x_reg_read(struct eth_device *dev, u32 offset)

   {
  @@ -37,14 +43,14 @@ void smc911x_reg_write(struct eth_device *dev, u32
 offset, u32 val)
   #elif defined (CONFIG_SMC911X_16_BIT)
   static inline u32 smc911x_reg_read(struct eth_device *dev, u32 offset)

   {
  -   volatile u16 *addr_16 = (u16 *)(dev-iobase + offset);
  -   return ((*addr_16  0x) | (*(addr_16 + 1) 
 16));
  +   volatile u16 *addr_16 = (u16 *)(dev-iobase + 
  smc911x_shift(offset));

  +   return ((*addr_16  0x) | (*(addr_16 + smc911x_shift(1))
  16));
   }
   static inline void smc911x_reg_write(struct eth_device *dev,
  u32 offset, u32 val)
   {
  -   *(volatile u16 *)(dev-iobase + offset) = (u16)val;
  -   *(volatile u16 *)(dev-iobase + offset + 2) = (u16)(val 
 16);
  +   *(volatile u16 *)(dev-iobase + smc911x_shift(offset)) =
 (u16)val;
  +   *(volatile u16 *)(dev-iobase + smc911x_shift(offset + 2))
 = (u16)val;
   }
 TAG--

 TAG++ ..TAG-- as this area of code is part of smc911x driver, better to create

 another patch for it.

 By the way does this change comes from bcz of snowball or a generic one?


 --
 Thanks,
 Jagan.
 
 Jagannadha Sutradharudu Teki,
 E: jagannadh.t...@gmail.com, P: +91-9676773388
 Engineer - System Software Hacker
 U-boot - SPI Custodian and Zynq APSOC
 Ln: http://www.linkedin.com/in/jaganteki



___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/4] arm: pxa: always init ethaddr for LP-8x4x

2013-12-15 Thread Sergei Ianovich
On Sun, 2013-12-15 at 06:17 +0100, Marek Vasut wrote:
 On Sunday, December 15, 2013 at 12:53:18 AM, Sergei Ianovich wrote:
  It may even make sense to remove the code that initializes eth1, right?
 
 Which code?

I mean:

lp8x4x_eth1_mac_init() in board/icpdas/lp8x4x/lp8x4x.c

and its invocation in board_eth_init()


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 1/4] ARM: pxa: prevent PXA270 occasional reboot freezes

2013-12-15 Thread Sergei Ianovich
On Sun, 2013-12-15 at 06:17 +0100, Marek Vasut wrote:
 On Sunday, December 15, 2013 at 12:51:44 AM, Sergei Ianovich wrote:
  Nevertheless, I've put a patched U-Boot with a single write to MDREFR to
  test (reset every 2 sec). After several hours, it will be clear, if a
  single write works. Let's do it the right way.
 

It works with a single write. I'll post v2 to the series.

Thanks for constructive reviewing.


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 4/4] arm: pxa: update LP-8x4x to boot DTS kernel

2013-12-15 Thread Sergei Ianovich
On Sat, 2013-12-14 at 18:05 +0100, Marek Vasut wrote:
 On Saturday, December 14, 2013 at 04:41:30 PM, Sergei Ianovich wrote:
  Factory flash partition layout is just 256 kiB for the U-Boot. I am not
  associated with the producer, so I cannot fix this.
 
 I see, understood. I won't bug you here, but you _might_ want to investigate 
 if 
 the U-Boot can't be for example compiled using THUMB instruction set and thus 
 shrink it in size. But that'd be a long shot :)

After a clean rebuild, U-Boot with both OF_LIBFDT and CMD_USB, but
without SYS_LONGHELP is under 256 kiB. I won't disable USB. Instead,
I'll try to make it actually work.

Thanks for constructive reviewing.

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/2] vexpress: Add vexpress qemu variant

2013-12-15 Thread Ian Campbell
Ping?

On Sun, 2013-11-17 at 15:17 +, Ian Campbell wrote:
 The main purpose of this is to disable the use of the virtualisation 
 extensions
 which Qemu does not emulate.
 
 Also enable a few additional commands and the u-boot API.
 
 This works for me with:
 $ dd if=/dev/zero of=pflash0.img bs=1M count=64
 $ dd if=/dev/zero of=pflash1.img bs=1M count=64
 $ qemu-system-arm -M vexpress-a15 -cpu cortex-a15 -kernel u-boot -m 1024m -sd 
 mmc.img -nographic -pflash pflash0.img -pflash pflash1.img
 
 (for some reason both pflash images are needed for saveenv to work)
 
 Signed-off-by: Ian Campbell i...@hellion.org.uk
 Cc: albert.u.b...@aribaud.net
 ---
  boards.cfg  | 1 +
  include/configs/vexpress_ca15_tc2.h | 2 ++
  include/configs/vexpress_common.h   | 4 
  3 files changed, 7 insertions(+)
 
 diff --git a/boards.cfg b/boards.cfg
 index caba64e..6e2fccc 100644
 --- a/boards.cfg
 +++ b/boards.cfg
 @@ -245,6 +245,7 @@ Active  arm arm926ejs  versatile   armltd 
  versatile
  Active  arm arm946es   -   armltd  integrator
   integratorap_cm946es integratorap:CM946ES   
   
  Linus Walleij linus.wall...@linaro.org
  Active  arm arm946es   -   armltd  integrator
   integratorcp_cm946es integratorcp:CM946ES   
   
  Linus Walleij linus.wall...@linaro.org
  Active  arm armv7  -   armltd  vexpress  
   vexpress_ca15_tc2-  
   
  -
 +Active  arm armv7  -   armltd  vexpress  
   vexpress_ca15_tc2_qemu   
 vexpress_ca15_tc2:ARCH_VEXPRESS_QEMU  
 -
  Active  arm armv7  -   armltd  vexpress  
   vexpress_ca5x2   -  
   
  Matt Waddel matt.wad...@linaro.org
  Active  arm armv7  -   armltd  vexpress  
   vexpress_ca9x4   -  
   
  Matt Waddel matt.wad...@linaro.org
  Active  arm armv7  am33xx  iseeigep0033  
   am335x_igep0033  -  
   
  Enric Balletbo i Serra eballe...@iseebcn.com
 diff --git a/include/configs/vexpress_ca15_tc2.h 
 b/include/configs/vexpress_ca15_tc2.h
 index 982f4a7..ccdb3c5 100644
 --- a/include/configs/vexpress_ca15_tc2.h
 +++ b/include/configs/vexpress_ca15_tc2.h
 @@ -18,6 +18,8 @@
  #define CONFIG_SYSFLAGS_ADDR 0x1c010030
  #define CONFIG_SMP_PEN_ADDR  CONFIG_SYSFLAGS_ADDR
  
 +#ifndef CONFIG_ARCH_VEXPRESS_QEMU
  #define CONFIG_ARMV7_VIRT
 +#endif
  
  #endif
 diff --git a/include/configs/vexpress_common.h 
 b/include/configs/vexpress_common.h
 index 7e78f8a..fbb9993 100644
 --- a/include/configs/vexpress_common.h
 +++ b/include/configs/vexpress_common.h
 @@ -157,6 +157,7 @@
  #define CONFIG_CMD_DHCP
  #define CONFIG_CMD_PXE
  #define CONFIG_MENU
 +#define CONFIG_CMD_ECHO
  #define CONFIG_CMD_ELF
  #define CONFIG_CMD_ENV
  #define CONFIG_CMD_FLASH
 @@ -164,6 +165,7 @@
  #define CONFIG_CMD_MEMORY
  #define CONFIG_CMD_NET
  #define CONFIG_CMD_PING
 +#define CONFIG_CMD_EXT2
  #define CONFIG_CMD_SAVEENV
  #define CONFIG_CMD_RUN
  #define CONFIG_CMD_BOOTZ
 @@ -176,6 +178,7 @@
  #define CONFIG_GENERIC_MMC
  #define CONFIG_ARM_PL180_MMCI
  #define CONFIG_ARM_PL180_MMCI_BASE   V2M_MMCI
 +#define CONFIG_SYS_MMC_MAX_DEVICE2
  #define CONFIG_SYS_MMC_MAX_BLK_COUNT 127
  #define CONFIG_ARM_PL180_MMCI_CLOCK_FREQ 625
  
 @@ -253,6 +256,7 @@
  #define CONFIG_SYS_FLASH_BASE0   V2M_NOR0
  #define CONFIG_SYS_FLASH_BASE1   V2M_NOR1
  #define CONFIG_SYS_MONITOR_BASE  CONFIG_SYS_FLASH_BASE0
 +#define CONFIG_API
  
  /* Timeout values in ticks */
  #define CONFIG_SYS_FLASH_ERASE_TOUT  (2 * CONFIG_SYS_HZ) /* Erase Timeout */


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/2] vexpress: Add vexpress qemu variant

2013-12-15 Thread Michael Trimarchi
Hi Ian


On Sun, Dec 15, 2013 at 6:08 PM, Ian Campbell i...@hellion.org.uk wrote:
 Ping?

 On Sun, 2013-11-17 at 15:17 +, Ian Campbell wrote:
 The main purpose of this is to disable the use of the virtualisation 
 extensions
 which Qemu does not emulate.

 Also enable a few additional commands and the u-boot API.


This is my cent ;)

My suggestion is to split the patch even if it is simple

Michael

 This works for me with:
 $ dd if=/dev/zero of=pflash0.img bs=1M count=64
 $ dd if=/dev/zero of=pflash1.img bs=1M count=64
 $ qemu-system-arm -M vexpress-a15 -cpu cortex-a15 -kernel u-boot -m 1024m 
 -sd mmc.img -nographic -pflash pflash0.img -pflash pflash1.img

 (for some reason both pflash images are needed for saveenv to work)

 Signed-off-by: Ian Campbell i...@hellion.org.uk
 Cc: albert.u.b...@aribaud.net
 ---
  boards.cfg  | 1 +
  include/configs/vexpress_ca15_tc2.h | 2 ++
  include/configs/vexpress_common.h   | 4 
  3 files changed, 7 insertions(+)

 diff --git a/boards.cfg b/boards.cfg
 index caba64e..6e2fccc 100644
 --- a/boards.cfg
 +++ b/boards.cfg
 @@ -245,6 +245,7 @@ Active  arm arm926ejs  versatile   armltd
   versatile
  Active  arm arm946es   -   armltd  integrator   
integratorap_cm946es integratorap:CM946ES 
  
 Linus Walleij linus.wall...@linaro.org
  Active  arm arm946es   -   armltd  integrator   
integratorcp_cm946es integratorcp:CM946ES 
  
 Linus Walleij linus.wall...@linaro.org
  Active  arm armv7  -   armltd  vexpress 
vexpress_ca15_tc2-
  
 -
 +Active  arm armv7  -   armltd  vexpress 
vexpress_ca15_tc2_qemu   
 vexpress_ca15_tc2:ARCH_VEXPRESS_QEMU 
  -
  Active  arm armv7  -   armltd  vexpress 
vexpress_ca5x2   -
  
 Matt Waddel matt.wad...@linaro.org
  Active  arm armv7  -   armltd  vexpress 
vexpress_ca9x4   -
  
 Matt Waddel matt.wad...@linaro.org
  Active  arm armv7  am33xx  iseeigep0033 
am335x_igep0033  -
  
 Enric Balletbo i Serra eballe...@iseebcn.com
 diff --git a/include/configs/vexpress_ca15_tc2.h 
 b/include/configs/vexpress_ca15_tc2.h
 index 982f4a7..ccdb3c5 100644
 --- a/include/configs/vexpress_ca15_tc2.h
 +++ b/include/configs/vexpress_ca15_tc2.h
 @@ -18,6 +18,8 @@
  #define CONFIG_SYSFLAGS_ADDR 0x1c010030
  #define CONFIG_SMP_PEN_ADDR  CONFIG_SYSFLAGS_ADDR

 +#ifndef CONFIG_ARCH_VEXPRESS_QEMU
  #define CONFIG_ARMV7_VIRT
 +#endif

  #endif
 diff --git a/include/configs/vexpress_common.h 
 b/include/configs/vexpress_common.h
 index 7e78f8a..fbb9993 100644
 --- a/include/configs/vexpress_common.h
 +++ b/include/configs/vexpress_common.h
 @@ -157,6 +157,7 @@
  #define CONFIG_CMD_DHCP
  #define CONFIG_CMD_PXE
  #define CONFIG_MENU
 +#define CONFIG_CMD_ECHO
  #define CONFIG_CMD_ELF
  #define CONFIG_CMD_ENV
  #define CONFIG_CMD_FLASH
 @@ -164,6 +165,7 @@
  #define CONFIG_CMD_MEMORY
  #define CONFIG_CMD_NET
  #define CONFIG_CMD_PING
 +#define CONFIG_CMD_EXT2
  #define CONFIG_CMD_SAVEENV
  #define CONFIG_CMD_RUN
  #define CONFIG_CMD_BOOTZ
 @@ -176,6 +178,7 @@
  #define CONFIG_GENERIC_MMC
  #define CONFIG_ARM_PL180_MMCI
  #define CONFIG_ARM_PL180_MMCI_BASE   V2M_MMCI
 +#define CONFIG_SYS_MMC_MAX_DEVICE2
  #define CONFIG_SYS_MMC_MAX_BLK_COUNT 127
  #define CONFIG_ARM_PL180_MMCI_CLOCK_FREQ 625

 @@ -253,6 +256,7 @@
  #define CONFIG_SYS_FLASH_BASE0   V2M_NOR0
  #define CONFIG_SYS_FLASH_BASE1   V2M_NOR1
  #define CONFIG_SYS_MONITOR_BASE  CONFIG_SYS_FLASH_BASE0
 +#define CONFIG_API

  /* Timeout values in ticks */
  #define CONFIG_SYS_FLASH_ERASE_TOUT  (2 * CONFIG_SYS_HZ) /* Erase Timeout */


 ___
 U-Boot mailing list
 U-Boot@lists.denx.de
 http://lists.denx.de/mailman/listinfo/u-boot

Re: [U-Boot] [PATCH 4/4] arm: pxa: update LP-8x4x to boot DTS kernel

2013-12-15 Thread Marek Vasut
On Sunday, December 15, 2013 at 10:57:55 AM, Sergei Ianovich wrote:
 On Sat, 2013-12-14 at 18:05 +0100, Marek Vasut wrote:
  On Saturday, December 14, 2013 at 04:41:30 PM, Sergei Ianovich wrote:
   Factory flash partition layout is just 256 kiB for the U-Boot. I am not
   associated with the producer, so I cannot fix this.
  
  I see, understood. I won't bug you here, but you _might_ want to
  investigate if the U-Boot can't be for example compiled using THUMB
  instruction set and thus shrink it in size. But that'd be a long shot :)
 
 After a clean rebuild, U-Boot with both OF_LIBFDT and CMD_USB, but
 without SYS_LONGHELP is under 256 kiB. I won't disable USB. Instead,
 I'll try to make it actually work.
 
 Thanks for constructive reviewing.

Again, thank you for the effort! :)

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 1/4] ARM: pxa: prevent PXA270 occasional reboot freezes

2013-12-15 Thread Marek Vasut
On Sunday, December 15, 2013 at 10:48:16 AM, Sergei Ianovich wrote:
 On Sun, 2013-12-15 at 06:17 +0100, Marek Vasut wrote:
  On Sunday, December 15, 2013 at 12:51:44 AM, Sergei Ianovich wrote:
   Nevertheless, I've put a patched U-Boot with a single write to MDREFR
   to test (reset every 2 sec). After several hours, it will be clear, if
   a single write works. Let's do it the right way.
 
 It works with a single write. I'll post v2 to the series.
 
 Thanks for constructive reviewing.

No, thank _you_ for the efforts!

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/4] arm: pxa: always init ethaddr for LP-8x4x

2013-12-15 Thread Marek Vasut
On Sunday, December 15, 2013 at 10:44:06 AM, Sergei Ianovich wrote:
 On Sun, 2013-12-15 at 06:17 +0100, Marek Vasut wrote:
  On Sunday, December 15, 2013 at 12:53:18 AM, Sergei Ianovich wrote:
   It may even make sense to remove the code that initializes eth1, right?
  
  Which code?
 
 I mean:
 
 lp8x4x_eth1_mac_init() in board/icpdas/lp8x4x/lp8x4x.c
 
 and its invocation in board_eth_init()

Heh, yes. The DT will solve it through the ethernet1 alias, just set the 
eth1addr and test it to make sure please.

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 2/4] arm: pxa: always init ethaddr for LP-8x4x

2013-12-15 Thread Sergei Ianovich
On Sun, 2013-12-15 at 16:05 +0100, Marek Vasut wrote:
 Heh, yes. The DT will solve it through the ethernet1 alias, just set the 
 eth1addr and test it to make sure please.

It works. I've updated the dts in kernel for next version of patch
series.

I will update this patch for v2.

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 4/4] arm: pxa: update LP-8x4x to boot DTS kernel

2013-12-15 Thread Sergei Ianovich
On Sun, 2013-12-15 at 16:06 +0100, Marek Vasut wrote:
 On Sunday, December 15, 2013 at 10:57:55 AM, Sergei Ianovich wrote:
  After a clean rebuild, U-Boot with both OF_LIBFDT and CMD_USB, but
  without SYS_LONGHELP is under 256 kiB. I won't disable USB. Instead,
  I'll try to make it actually work.

While testing, I've run into an issue with USB support. If I do

$ usb start

in U-Boot, not only it doesn't see an attached flash storage, but also
it break USB in the kernel. If I just boot the kernel from flash or
tftp, USB works in the kernel.

I've verified that my usb_board_init() is exactly the same sequence of
commands, that the kernel uses to initialize the stack up to
usb_add_hcd() at linux/drivers/usb/host/ohci-pxa27x.c:445

I suspect the issue is in U-Boot OHCI PXA driver. Are you aware of any?

It probably makes sense to disable USB at LP-8x4 for now.


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 4/4] arm: pxa: update LP-8x4x to boot DTS kernel

2013-12-15 Thread Marek Vasut
On Sunday, December 15, 2013 at 07:56:35 PM, Sergei Ianovich wrote:
 On Sun, 2013-12-15 at 16:06 +0100, Marek Vasut wrote:
  On Sunday, December 15, 2013 at 10:57:55 AM, Sergei Ianovich wrote:
   After a clean rebuild, U-Boot with both OF_LIBFDT and CMD_USB, but
   without SYS_LONGHELP is under 256 kiB. I won't disable USB. Instead,
   I'll try to make it actually work.
 
 While testing, I've run into an issue with USB support. If I do
 
   $ usb start
 
 in U-Boot, not only it doesn't see an attached flash storage, but also
 it break USB in the kernel. If I just boot the kernel from flash or
 tftp, USB works in the kernel.

The OHCI controller is not properly shut down before booting kernel, that's 
what 
I'd check first.

 I've verified that my usb_board_init() is exactly the same sequence of
 commands, that the kernel uses to initialize the stack up to
 usb_add_hcd() at linux/drivers/usb/host/ohci-pxa27x.c:445
 
 I suspect the issue is in U-Boot OHCI PXA driver. Are you aware of any?

No, not really. I didn't use the OHCI stuff for a while.

 It probably makes sense to disable USB at LP-8x4 for now.

Can you maybe try debugging it please ?

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH v6] spi: Add support SH Quad SPI driver

2013-12-15 Thread Nobuhiro Iwamatsu
ping.

2013/12/2 Nobuhiro Iwamatsu nobuhiro.iwamatsu...@renesas.com:
 This patch adds a driver for Renesas SoC's Quad SPI bus.
 This supports with 8 bits per transfer to use with SPI flash.

 Signed-off-by: Kouei Abe kouei.abe...@renesas.com
 Signed-off-by: Nobuhiro Iwamatsu nobuhiro.iwamatsu...@renesas.com
 Signed-off-by: Jagannadha Sutradharudu Teki jaga...@xilinx.com
 ---

 Changes for v6:
   - Update Makefile to new style.
 Changes for v5:
   - Add print abort when call ctrlc().
   - Move source code in spi_xfer() which should be processed by
 spi_cs_activate().
   - Move source code in spi_xfer() which should be processed by
 spi_cs_deactivate().
   - Remove sh_qspi_xfer, move to spi_xfer().
 Changes for v4:
   - Added tabs
   - Added comments
   - Added sh_qspi_init()
 Changes for v3:
   - Change Queued to Quad.
   - Remove path of file from file header.
   - Use read* and write* directly instead of sh_qspi_write* sh_qspi_read*.
   - Change driver format.
 Changes for v2:
   - SH QSPI to SH QSPI (Queued SPI).
   - Remove magic number.

  drivers/spi/Makefile  |   1 +
  drivers/spi/sh_qspi.c | 244 
 ++
  2 files changed, 245 insertions(+)
  create mode 100644 drivers/spi/sh_qspi.c

 diff --git a/drivers/spi/Makefile b/drivers/spi/Makefile
 index 27902fe..914e71f 100644
 --- a/drivers/spi/Makefile
 +++ b/drivers/spi/Makefile
 @@ -29,6 +29,7 @@ obj-$(CONFIG_OC_TINY_SPI) += oc_tiny_spi.o
  obj-$(CONFIG_OMAP3_SPI) += omap3_spi.o
  obj-$(CONFIG_SOFT_SPI) += soft_spi.o
  obj-$(CONFIG_SH_SPI) += sh_spi.o
 +obj-$(CONFIG_SH_QSPI) += sh_qspi.o
  obj-$(CONFIG_FSL_ESPI) += fsl_espi.o
  obj-$(CONFIG_FDT_SPI) += fdt_spi.o
  obj-$(CONFIG_TEGRA20_SFLASH) += tegra20_sflash.o
 diff --git a/drivers/spi/sh_qspi.c b/drivers/spi/sh_qspi.c
 new file mode 100644
 index 000..8f53552
 --- /dev/null
 +++ b/drivers/spi/sh_qspi.c
 @@ -0,0 +1,244 @@
 +/*
 + * SH QSPI (Quad SPI) driver
 + *
 + * Copyright (C) 2013 Renesas Electronics Corporation
 + * Copyright (C) 2013 Nobuhiro Iwamatsu nobuhiro.iwamatsu...@renesas.com
 + *
 + * SPDX-License-Identifier:GPL-2.0
 + */
 +
 +#include common.h
 +#include malloc.h
 +#include spi.h
 +#include asm/io.h
 +
 +/* SH QSPI register bit masks REG_BIT */
 +#define SPCR_MSTR  0x08
 +#define SPCR_SPE   0x40
 +#define SPSR_SPRFF 0x80
 +#define SPSR_SPTEF 0x20
 +#define SPPCR_IO3FV0x04
 +#define SPPCR_IO2FV0x02
 +#define SPPCR_IO1FV0x01
 +#define SPBDCR_RXBC0   (1  0)
 +#define SPCMD_SCKDEN   (1  15)
 +#define SPCMD_SLNDEN   (1  14)
 +#define SPCMD_SPNDEN   (1  13)
 +#define SPCMD_SSLKP(1  7)
 +#define SPCMD_BRDV0(1  2)
 +#define SPCMD_INIT1SPCMD_SCKDEN | SPCMD_SLNDEN | \
 +   SPCMD_SPNDEN | SPCMD_SSLKP | \
 +   SPCMD_BRDV0
 +#define SPCMD_INIT2SPCMD_SPNDEN | SPCMD_SSLKP | \
 +   SPCMD_BRDV0
 +#define SPBFCR_TXRST   (1  7)
 +#define SPBFCR_RXRST   (1  6)
 +
 +/* SH QSPI register set */
 +struct sh_qspi_regs {
 +   unsigned char spcr;
 +   unsigned char sslp;
 +   unsigned char sppcr;
 +   unsigned char spsr;
 +   unsigned long spdr;
 +   unsigned char spscr;
 +   unsigned char spssr;
 +   unsigned char spbr;
 +   unsigned char spdcr;
 +   unsigned char spckd;
 +   unsigned char sslnd;
 +   unsigned char spnd;
 +   unsigned char dummy0;
 +   unsigned short spcmd0;
 +   unsigned short spcmd1;
 +   unsigned short spcmd2;
 +   unsigned short spcmd3;
 +   unsigned char spbfcr;
 +   unsigned char dummy1;
 +   unsigned short spbdcr;
 +   unsigned long spbmul0;
 +   unsigned long spbmul1;
 +   unsigned long spbmul2;
 +   unsigned long spbmul3;
 +};
 +
 +struct sh_qspi_slave {
 +   struct spi_slaveslave;
 +   struct sh_qspi_regs *regs;
 +};
 +
 +static inline struct sh_qspi_slave *to_sh_qspi(struct spi_slave *slave)
 +{
 +   return container_of(slave, struct sh_qspi_slave, slave);
 +}
 +
 +static void sh_qspi_init(struct sh_qspi_slave *ss)
 +{
 +   /* QSPI initialize */
 +   writeb(SPCR_MSTR, ss-regs-spcr);
 +   writeb(0x00, ss-regs-sslp);
 +   writeb(SPPCR_IO3FV|SPPCR_IO2FV, ss-regs-sppcr);
 +
 +   /* Set bit rate. See 58.3.8 Quad Serial Peripheral Interface */
 +   writeb(0x01, ss-regs-spbr);
 +
 +   writeb(0x00, ss-regs-spdcr);
 +   writeb(0x00, ss-regs-spckd);
 +   writeb(0x00, ss-regs-sslnd);
 +   writeb(0x00, ss-regs-spnd);
 +   writew(SPCMD_INIT1, ss-regs-spcmd0);
 +   writew(SPCMD_INIT2, ss-regs-spcmd0);
 +   writeb(SPBFCR_TXRST|SPBFCR_RXRST, ss-regs-spbfcr);
 +   writeb(0x00, ss-regs-spbfcr);
 +   writeb(0x00, ss-regs-spscr);
 +   writeb(SPCR_SPE|SPCR_MSTR, ss-regs-spcr);
 +}
 +
 +int spi_cs_is_valid(unsigned int bus, unsigned int cs)
 +{
 +   return 1;
 +}
 +
 +void spi_cs_activate(struct spi_slave *slave)
 +{
 +   struct sh_qspi_slave *ss = 

Re: [U-Boot] [PATCH v3 1/4] mkexynosspl: fix uninitialized buffer

2013-12-15 Thread Minkyu Kang
Dear Albert ARIBAUD,

On 14/12/13 19:14, Albert ARIBAUD wrote:
 Hi Minkyu,
 
 On Sat, 14 Dec 2013 14:07:57 +0900, Minkyu Kang mk7.k...@samsung.com
 wrote:
 
 Dear Albert,

 On 13/12/13 18:00, Albert ARIBAUD wrote:
 (adding Minkyu as the Samsung custodian)

 On Mon,  9 Dec 2013 18:09:18 +0100, Albert ARIBAUD
 albert.u.b...@aribaud.net wrote:

 mkexynos reads its input file which might be smaller than

 ( typo: s/mkexynos/mkexynosspl/ -- wil fix when applying if thee is
 no other change to be made )

 its read buffer, but always writes the whole buffer out.
 This does not affect the functionalyty of the output file,
 
 ... and s/functionalyty/functionality/, too.
 
 but it makes its content unpredictable as the end of the
 buffer is never initialized. Fix this by zeroing the buffer
 before reading the input file.

 Minkyu: should the buffer be pre-filled with zeroes or should I use
 ones instead? Or maybe the output could be truncated to the size of the
 input?

 Basically, the output file is fixed to 14K as same as buffer size.
 And the input file should be smaller than 14K.
 It's the rule of exynos spl.
 The role of mkexynosspl is just adding 4 byte checksum value to end of file.
 If the input file is bigger than 14K, output will be truncated.


 Amicalement,
 Albert.
  
 Signed-off-by: Albert ARIBAUD albert.u.b...@aribaud.net

 btw, this change looks reasonable to me.

 Acked-by: Minkyu Kang mk7.k...@samsung.com
 
 Thanks! If that's ok with you, I'll apply 1/4 to ARM, considering it a
 kind of bugfix, and remove it from V4 of the patch series if there is
 any.
 
 Or if you prefer to apply 1/4 to u-boot-samsung, that's fine with me.

please apply this patch to u-boot-arm.

 
 Thanks,
 Minkyu Kang.
 
 Amicalement,
 

Thanks,
Minkyu Kang.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 1/7 V4] mmc: Add some usefull macro definition

2013-12-15 Thread haijun.zh...@freescale.com
Hi, Pantelis

These are the newest version of this patch set.
Expect your advice.


Regards  Thanks.

-- Haijun

 -Original Message-
 From: Haijun Zhang [mailto:haijun.zh...@freescale.com]
 Sent: Tuesday, December 10, 2013 4:21 PM
 To: pa...@antoniou-consulting.com
 Cc: u-boot@lists.denx.de; Xie Xiaobo-R63061; Sun York-R58495;
 tr...@ti.com; sba...@denx.de; rjbar...@rockwellcollins.com;
 jh80.ch...@samsung.com; mich...@amarulasolutions.com; Zhang Haijun-B42677;
 Zhang Haijun-B42677
 Subject: [PATCH 1/7 V4] mmc: Add some usefull macro definition
 
 From: Haijun Zhang haijun.zh...@freescale.com
 
 Add command class define.
 Add mmc erase and secure erase define.
 Add secure erase and trim support bit define.
 
 Signed-off-by: Haijun Zhang haijun.zh...@freescale.com
 ---
 changes for V4:
 - no changes
 changes for V3:
 - No changes
 
  include/mmc.h | 50 +-
  1 file changed, 49 insertions(+), 1 deletion(-)
 
 diff --git a/include/mmc.h b/include/mmc.h index cb558da..08f0f3e 100644
 --- a/include/mmc.h
 +++ b/include/mmc.h
 @@ -53,6 +53,7 @@
  #define COMM_ERR -18 /* Communications Error */
  #define TIMEOUT  -19
  #define IN_PROGRESS  -20 /* operation is in progress */
 +#define NOT_SUPPORT  -21 /* Operation is not support */
 
  #define MMC_CMD_GO_IDLE_STATE0
  #define MMC_CMD_SEND_OP_COND 1
 @@ -105,6 +106,39 @@
  #define OCR_VOLTAGE_MASK 0x007FFF80
  #define OCR_ACCESS_MODE  0x6000
 
 +/*
 + * Card Command Classes (CCC)
 + *
 + * (0) Basic protocol functions (CMD0,1,2,3,4,7,9,10,12,13,15)
 + * (and for SPI, CMD58,59)
 + * (1) Stream read commands (CMD11)
 + * (2) Block read commands (CMD16,17,18)
 + * (3) Stream write commands (CMD20)
 + * (4) Block write commands (CMD16,24,25,26,27)
 + * (5) Ability to erase blocks (CMD32,33,34,35,36,37,38,39)
 + * (6) Able to write protect blocks (CMD28,29,30)
 + * (7) Able to lock down card (CMD16,CMD42)
 + * (8) Application specific (CMD55,56,57,ACMD*)
 + * (9) I/O mode (CMD5,39,40,52,53)
 + * (10) High speed switch (CMD6,34,35,36,37,50)  */
 +#define CCC_BASIC(10)
 +#define CCC_STREAM_READ  (11)
 +#define CCC_BLOCK_READ   (12)
 +#define CCC_STREAM_WRITE (13)
 +#define CCC_BLOCK_WRITE  (14)
 +#define CCC_ERASE(15)
 +#define CCC_WRITE_PROT   (16)
 +#define CCC_LOCK_CARD(17)
 +#define CCC_APP_SPEC (18)
 +#define CCC_IO_MODE  (19)
 +#define CCC_SWITCH   (110)
 +
 +#define MMC_ERASE_ARG   0x
 +#define MMC_SECURE_ERASE_ARG0x8000
 +#define MMC_TRIM_ARG0x0001
 +#define MMC_DISCARD_ARG 0x0003
 +
  #define SECURE_ERASE 0x8000
 
  #define MMC_STATUS_MASK  (~0x0206BF7F)
 @@ -160,8 +194,12 @@
  #define EXT_CSD_CARD_TYPE196 /* RO */
  #define EXT_CSD_SEC_CNT  212 /* RO, 4 bytes */
  #define EXT_CSD_HC_WP_GRP_SIZE   221 /* RO */
 +#define EXT_CSD_REL_WR_SEC_C 222 /* RO */
 +#define EXT_CSD_ERASE_TIMEOUT_MULT   223 /* RO */
  #define EXT_CSD_HC_ERASE_GRP_SIZE224 /* RO */
  #define EXT_CSD_BOOT_MULT226 /* RO */
 +#define EXT_CSD_SEC_ERASE_MULT   230 /* RO */
 +#define EXT_CSD_SEC_FEATURE_SUPPORT  231 /* RO */
 
  /*
   * EXT_CSD field definitions
 @@ -178,6 +216,12 @@
  #define EXT_CSD_BUS_WIDTH_4  1   /* Card is in 4 bit mode */
  #define EXT_CSD_BUS_WIDTH_8  2   /* Card is in 8 bit mode */
 
 +/* EXT_CSD[231] */
 +#define EXT_CSD_SEC_ER_EN(10)
 +#define EXT_CSD_SEC_BD_BLK_EN(12)
 +#define EXT_CSD_SEC_GB_CL_EN (14)
 +#define EXT_CSD_SEC_SANITIZE (16)  /* v4.5 later */
 +
  #define EXT_CSD_BOOT_ACK_ENABLE  (1  6)
  #define EXT_CSD_BOOT_PARTITION_ENABLE(1  3)
  #define EXT_CSD_PARTITION_ACCESS_ENABLE  (1  0)
 @@ -187,7 +231,6 @@
  #define EXT_CSD_BOOT_PART_NUM(x) (x  3)
  #define EXT_CSD_PARTITION_ACCESS(x)  (x  0)
 
 -
  #define R1_ILLEGAL_COMMAND   (1  22)
  #define R1_APP_CMD   (1  5)
 
 @@ -268,10 +311,15 @@ struct mmc {
   ushort rca;
   char part_config;
   char part_num;
 + ushort cmdclass;
   uint tran_speed;
   uint read_bl_len;
   uint write_bl_len;
   uint erase_grp_size;
 + uint erase_timeout_mult;
 + char sec_feature_support;
 + uint sec_erase_mult;
 + uint sec_erase_timeout;
   u64 capacity;
   u64 capacity_user;
   u64 capacity_boot;
 --
 1.8.4.1
 

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] booting issue with Atmel SAMA5D31 Evaluation kit

2013-12-15 Thread Bo Shen

Hi Ron Eggler,

On 12/14/2013 05:15 AM, Ron Eggler wrote:

--

ron eggler | semios | senior software engineer

320 - 887 Great Northern Way | Vancouver, BC | V5T 4T5

T | 604 229 2044 ext 105 tel:604%20229%202044%20ext%20105

C | 778 230 9442 tel:778%20230%209442

E |regg...@semios.com mailto:regg...@semios.com

smart farming http://www.semios.com

twitter https://twitter.com/semioslinkedin
http://www.linkedin.com/company/semiosbio-technologies-inc?goback=%2Enmp_*1_*1_*1_*1_*1_*1_*1_*1_*1_*1trk=company_logo


On December 13, 2013 11:57:29 AM Andreas Bießmann wrote:

  Dear Ron Eggler,

 

  On 12/12/2013 10:22 PM, Ron Eggler wrote:

   Hi,

  

   I got a SAMA5D31 evaluation kit here, it came with some default

   application. I started reading through the getting started guide and

   immediately tried to load my own image - MISTAKE!

   I started playing around with u-boot trying to get an image from my
tftp

   server loaded but now i realize, that I can't get it to hook up to my

   LAN. Bad! Because it won't even let me boot the original application

   anymore.

   When I boot it and my variables look like this:

   ...

   ...

   Warning: failed to set MAC address

 

  your env is missing an ethaddr

Yes, I know, I had set it to some bogus address but that didn't help
either...


Please check whether the bogus address is a valid address, that means, 
the addr[0] bit 0 can not be 1.

For example: 3c:3f:35:28:44:61
the addr[0] is 3c, and (0x3c  0x01) is zero, then consider it as a 
bogus valid address.



How can the mac address be missing anyways, shouldn't that be fixed in
sillicon?


The MAC address can not be come with silicon. You should set it for your 
product (need buy from IEEE).



 

   Hit any key to stop autoboot: 0

   macb0: PHY present at 0

   macb0: Starting autonegotiation...

   macb0: Autonegotiation timed out (status=0x7849)

   macb0: link down (status: 0x7849)

   macb0: PHY present at 0

   macb0: Starting autonegotiation...

   macb0: Autonegotiation timed out (status=0x7849)

   macb0: link down (status: 0x7849)

   Wrong Image Format for bootm command

   ERROR: can't get kernel image!

   U-Boot printenv

   baudrate=115200

   bootargs=console=ttyS0,115200 ip=${ipaddr} root=/dev/nfs rw

   nfsroot=${serverip}:/full/path/to/rfs

   bootcmd=tftp;tftp 2100 sama5d3x_ek.dtbbootm 2200 - 2100

   bootdelay=1

   bootfile=uImage-3.6-ts-armv7l

   ethact=macb0

   ipaddr=192.168.1.122

   loadaddr=2200

   serverip=192.168.1.121

   stderr=serial

   stdin=serial

   stdout=serial

  

   Environment size: 367/131067 bytes

   U-Boot

  

   What can I do to at least get it to boot the default program again?

 

  Dunno from the given information, maybe it is the missing ethaddr. I can

  confirm that loading data via tftp is working on my d34 device. I think

  Bo has an d31 handy and could help you.

 

  To get the original code onto your device you could use the sam-ba

  application. It's working on Win and Linux, unfortunately not on OS X.

  Just plug the provided USB cable into the J20 on your baseboard (not the

  J-Link!), switch J9 correclty (I think open it), push and hold PB4 and

  push/release PB1, after that sequence startup sam-ba, choose the correct

  interface and the 'at91sama5d3x-ek' board.

I did the key combo when the usb was plugged in and now, not even uboot
boots up anymore, it seems to be completely blank now. When I launch
sam-ba as root (on Linux), I can only select Exit, nothing else is
enabled. Select the connection seems to be enabled but is empty,
nothing there to choose. Also dmesg doesn't show me anything on powert
reset... what else can I do from here? :o


First, please check the console output, it should be BootROM.
Second, which Linux distribution you are using? If use ubuntu 12.04, you 
can see a /dev/ttyACMx device, sam-ba will access this device.



Thanks,

Ron

 

  Best regards

 

  Andreas Bießmann



Best Regards,
Bo Shen
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] booting issue with Atmel SAMA5D31 Evaluation kit

2013-12-15 Thread Ron Eggler
Hi Bo,

Thanks for your reply!



 Hi Ron Eggler,
 
 On 12/14/2013 05:15 AM, Ron Eggler wrote:
  --
  
[snip]

  On December 13, 2013 11:57:29 AM Andreas Bießmann wrote:
Dear Ron Eggler,

On 12/12/2013 10:22 PM, Ron Eggler wrote:
 Hi,
 
 
 
 I got a SAMA5D31 evaluation kit here, it came with some default
 
 application. I started reading through the getting started guide and
 
 immediately tried to load my own image - MISTAKE!
 
 I started playing around with u-boot trying to get an image from my
  
  tftp
  
 server loaded but now i realize, that I can't get it to hook up to my
 
 LAN. Bad! Because it won't even let me boot the original application
 
 anymore.
 
 When I boot it and my variables look like this:
 
 ...
 
 ...
 
 Warning: failed to set MAC address

your env is missing an ethaddr
  
  Yes, I know, I had set it to some bogus address but that didn't help
  either...
 
 Please check whether the bogus address is a valid address, that means,
 the addr[0] bit 0 can not be 1.
 For example: 3c:3f:35:28:44:61
 the addr[0] is 3c, and (0x3c  0x01) is zero, then consider it as a
 bogus valid address.

Yes, I confirm, my bogus address was 00:12:34:56:78:90
 
  How can the mac address be missing anyways, shouldn't that be fixed in
  sillicon?
 
 The MAC address can not be come with silicon. You should set it for your
 product (need buy from IEEE).
 
 Hit any key to stop autoboot: 0
 
 macb0: PHY present at 0
 
 macb0: Starting autonegotiation...
 
 macb0: Autonegotiation timed out (status=0x7849)
 
 macb0: link down (status: 0x7849)
 
 macb0: PHY present at 0
 
 macb0: Starting autonegotiation...
 
 macb0: Autonegotiation timed out (status=0x7849)
 
 macb0: link down (status: 0x7849)
 
 Wrong Image Format for bootm command
 
 ERROR: can't get kernel image!
 
 U-Boot printenv
 
 baudrate=115200
 
 bootargs=console=ttyS0,115200 ip=${ipaddr} root=/dev/nfs rw
 
 nfsroot=${serverip}:/full/path/to/rfs
 
 bootcmd=tftp;tftp 2100 sama5d3x_ek.dtbbootm 2200 - 2100
 
 bootdelay=1
 
 bootfile=uImage-3.6-ts-armv7l
 
 ethact=macb0
 
 ipaddr=192.168.1.122
 
 loadaddr=2200
 
 serverip=192.168.1.121
 
 stderr=serial
 
 stdin=serial
 
 stdout=serial
 
 
 
 Environment size: 367/131067 bytes
 
 U-Boot
 
 
 
 What can I do to at least get it to boot the default program again?

Dunno from the given information, maybe it is the missing ethaddr. I
can___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] booting issue with Atmel SAMA5D31 Evaluation kit

2013-12-15 Thread Bo Shen

Hi Ron,

On 12/16/2013 11:19 AM, Ron Eggler wrote:

  First, please check the console output, it should be BootROM.

  Second, which Linux distribution you are using? If use ubuntu 12.04, you

  can see a /dev/ttyACMx device, sam-ba will access this device.

I'm using Kubuntu 13.10 and I connect to the serial port with

screen /dev/ttyACM0 115200


I will try to make something clear.
On sama5d3xek board, there are two USB device connectors, one is J14 (on 
the right side, near JTAG connector) is used for console. The other is 
J20 (on the upper side, near USB host connector) is USB device port for 
sama5 SoC.


So, bootup information, include BootROM are come out from J14. When you 
try to flash using sam-ba, you should connect J20.


In summary, please take the following steps to re-flash:
1. power up the board.
2. connect J14 as console. (minicom, screen as you prefer)
3. combo key, to check whether BootROM come out from console.
4. connect J20, and check whether /dev/ttyACMx is accessible.
5. start sam-ba with root permission.


but upon power cycle, nothing comes through, i.e. the screen is just
black also, the kit came with an LCD screen, that a showed a little demo
app but that's gone since the key combo Andreas had suggested and the
screen just stays blank so I assume that the flash got completely erased...

Any assistance to get that kit booting again is appreciated!

Thanks,

Ron



Best Regards,
Bo Shen
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] Pull request: u-boot-blackfin

2013-12-15 Thread Sonic Zhang
Hi Tom,

Please pull the following bug fixing patches from u-boot-blackfin into
your tree.

Thanks

Sonic Zhang


The following changes since commit e03c76c30342797a25ef9350e51c8daa0b56f1df:

  powerpc/mpc85xx: Update CONFIG_SYS_FSL_TBCLK_DIV for T1040
(2013-12-11 11:12:54 -0800)

are available in the git repository at:

  git://git.denx.de/u-boot-blackfin.git master

for you to fetch changes up to ecf9ce2149bdb884ac294e9b39c673046bb9b572:

  blackfin: remove build warning (2013-12-16 11:38:33 +0800)


Sonic Zhang (6):
  blackfin: fix build error by adding CONFIG_BFIN_SERIAL
  blackfin: fix building error by adding macro CONFIG_SYS_I2C
  blackfin: Disable commands to reduce l1 ram requirement
  blackfin: fix building error by enlarging the memory size
  blackfin: fixing warning by including proper headers
  blackfin: remove build warning

 arch/blackfin/cpu/initcode.c   |   18 ++
 arch/blackfin/include/asm/blackfin_local.h |7 +--
 arch/blackfin/lib/board.c  |1 +
 arch/blackfin/lib/clocks.c |5 -
 board/bf609-ezkit/bf609-ezkit.c|1 +
 include/configs/bf506f-ezkit.h |8 ++--
 include/configs/bf561-acvilon.h|2 +-
 include/configs/bf561-ezkit.h  |1 +
 include/configs/blackvme.h |1 +
 include/configs/cm-bf537e.h|4 ++--
 include/configs/cm-bf537u.h|3 ++-
 include/configs/tcm-bf537.h|3 ++-
 12 files changed, 36 insertions(+), 18 deletions(-)
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] booting issue with Atmel SAMA5D31 Evaluation kit

2013-12-15 Thread Ron Eggler
Hi Bo,

Okay here we have some more information! Great!

On December 16, 2013 11:42:11 AM Bo Shen wrote:
 Hi Ron,
 
 On 12/16/2013 11:19 AM, Ron Eggler wrote:
First, please check the console output, it should be BootROM.

Second, which Linux distribution you are using? If use ubuntu 12.04,
you

can see a /dev/ttyACMx device, sam-ba will access this device.
  
  I'm using Kubuntu 13.10 and I connect to the serial port with
  
  screen /dev/ttyACM0 115200
 
 I will try to make something clear.
 On sama5d3xek board, there are two USB device connectors, one is J14 (on
 the right side, near JTAG connector) is used for console. The other is
 J20 (on the upper side, near USB host connector) is USB device port for
 sama5 SoC.
 
 So, bootup information, include BootROM are come out from J14. When you
 try to flash using sam-ba, you should connect J20.
 
 In summary, please take the following steps to re-flash:
 1. power up the board.
 2. connect J14 as console. (minicom, screen as you prefer)
 3. combo key, to check whether BootROM come out from console.
Upon keuy combo (hold PB4 while pressing PB1) nothing appears on console (J14)
 4. connect J20, and check whether /dev/ttyACMx is accessible.
I connect to J20 but no /dev/ttyACMx is available

do you have any alternative suggestions for this behavior?

Thanks,
Ron

 5. start sam-ba with root permission.
 
  but upon power cycle, nothing comes through, i.e. the screen is just
  black also, the kit came with an LCD screen, that a showed a little demo
  app but that's gone since the key combo Andreas had suggested and the
  screen just stays blank so I assume that the flash got completely
  erased...
  
  Any assistance to get that kit booting again is appreciated!
  
  Thanks,
  
  Ron
 
 Best Regards,
 Bo Shen

-- 
*ron eggler | semios | senior software engineer*
320 - 887 Great Northern Way | Vancouver, BC | V5T 4T5
T | 604 229 2044 ext 105[1]
C | 778 230 9442[2]
E | regg...@semios.com[3]
smart farming[4]
twitter[5] linkedin[6]


[1] tel:604%20229%202044%20ext%20105
[2] tel:778%20230%209442
[3] mailto:regg...@semios.com
[4] http://www.semios.com
[5] https://twitter.com/semios
[6] 
http://www.linkedin.com/company/semiosbio-technologies-inc?goback=%2Enmp_*1_*1_*1_*1_*1_*1_*1_*1_*1_*1trk=company_logo
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] booting issue with Atmel SAMA5D31 Evaluation kit

2013-12-15 Thread Shen, Voice
Hi Ron,

Hi Bo,
 
Okay here we have some more information! Great!
 
On December 16, 2013 11:42:11 AM Bo Shen wrote:
 Hi Ron,
 
 On 12/16/2013 11:19 AM, Ron Eggler wrote:
   First, please check the console output, it should be BootROM.
   
   Second, which Linux distribution you are using? If use ubuntu 12.04,
   you
   
   can see a /dev/ttyACMx device, sam-ba will access this device.
  
  I'm using Kubuntu 13.10 and I connect to the serial port with
  
  screen /dev/ttyACM0 115200
 
 I will try to make something clear.
 On sama5d3xek board, there are two USB device connectors, one is J14 (on
 the right side, near JTAG connector) is used for console. The other is
 J20 (on the upper side, near USB host connector) is USB device port for
 sama5 SoC.
 
 So, bootup information, include BootROM are come out from J14. When you
 try to flash using sam-ba, you should connect J20.
 
 In summary, please take the following steps to re-flash:
 1. power up the board.
 2. connect J14 as console. (minicom, screen as you prefer)
 3. combo key, to check whether BootROM come out from console.
Upon keuy combo (hold PB4 while pressing PB1) nothing appears on console (J14)

I don't know why there is no output here.

 4. connect J20, and check whether /dev/ttyACMx is accessible.
I connect to J20 but no /dev/ttyACMx is available

Can you check some devices added? before and after you plug in USB cable to see 
the difference.
 
do you have any alternative suggestions for this behavior?

Can you check with lsusb command, it will show something similar as following:
---8---
Bus 002 Device 110: ID 03eb:6124 Atmel Corp. at91sam SAMBA bootlader
---8---
  
 5. start sam-ba with root permission.
 
  but upon power cycle, nothing comes through, i.e. the screen is just
  black also, the kit came with an LCD screen, that a showed a little demo
  app but that's gone since the key combo Andreas had suggested and the
  screen just stays blank so I assume that the flash got completely
  erased...
  
  Any assistance to get that kit booting again is appreciated!
  
  Thanks,
  
  Ron
 
 Best Regards,
 Bo Shen
 
-- 
ron eggler | semios | senior software engineer
320 - 887 Great Northern Way | Vancouver, BC | V5T 4T5
T | 604 229 2044 ext 105
C | 778 230 9442
E | regg...@semios.com
smart farming
twitter linkedin
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] Makefile: fix the typo error for mrproper

2013-12-15 Thread Bo Shen
Fix the typo error for mrproper from mkproper.

Signed-off-by: Bo Shen voice.s...@atmel.com
---
In Makefile, there is no object name is mkproper, so I think this is
a typo error.

 Makefile |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 7310c4e..ddbaaf0 100644
--- a/Makefile
+++ b/Makefile
@@ -168,7 +168,7 @@ endif
 include $(TOPDIR)/config.mk
 
 # Targets which don't build the source code
-NON_BUILD_TARGETS = backup clean clobber distclean mkproper tidy unconfig
+NON_BUILD_TARGETS = backup clean clobber distclean mrproper tidy unconfig
 
 # Only do the generic board check when actually building, not configuring
 ifeq ($(filter $(NON_BUILD_TARGETS),$(MAKECMDGOALS)),)
-- 
1.7.9.5

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH v6] spi: Add support SH Quad SPI driver

2013-12-15 Thread Jagan Teki
On Mon, Dec 2, 2013 at 1:42 PM, Nobuhiro Iwamatsu
nobuhiro.iwamatsu...@renesas.com wrote:
 This patch adds a driver for Renesas SoC's Quad SPI bus.
 This supports with 8 bits per transfer to use with SPI flash.

 Signed-off-by: Kouei Abe kouei.abe...@renesas.com
 Signed-off-by: Nobuhiro Iwamatsu nobuhiro.iwamatsu...@renesas.com
 Signed-off-by: Jagannadha Sutradharudu Teki jaga...@xilinx.com
 ---

 Changes for v6:
   - Update Makefile to new style.
 Changes for v5:
   - Add print abort when call ctrlc().
   - Move source code in spi_xfer() which should be processed by
 spi_cs_activate().
   - Move source code in spi_xfer() which should be processed by
 spi_cs_deactivate().
   - Remove sh_qspi_xfer, move to spi_xfer().
 Changes for v4:
   - Added tabs
   - Added comments
   - Added sh_qspi_init()
 Changes for v3:
   - Change Queued to Quad.
   - Remove path of file from file header.
   - Use read* and write* directly instead of sh_qspi_write* sh_qspi_read*.
   - Change driver format.
 Changes for v2:
   - SH QSPI to SH QSPI (Queued SPI).
   - Remove magic number.

  drivers/spi/Makefile  |   1 +
  drivers/spi/sh_qspi.c | 244 
 ++
  2 files changed, 245 insertions(+)
  create mode 100644 drivers/spi/sh_qspi.c

 diff --git a/drivers/spi/Makefile b/drivers/spi/Makefile
 index 27902fe..914e71f 100644
 --- a/drivers/spi/Makefile
 +++ b/drivers/spi/Makefile
 @@ -29,6 +29,7 @@ obj-$(CONFIG_OC_TINY_SPI) += oc_tiny_spi.o
  obj-$(CONFIG_OMAP3_SPI) += omap3_spi.o
  obj-$(CONFIG_SOFT_SPI) += soft_spi.o
  obj-$(CONFIG_SH_SPI) += sh_spi.o
 +obj-$(CONFIG_SH_QSPI) += sh_qspi.o
  obj-$(CONFIG_FSL_ESPI) += fsl_espi.o
  obj-$(CONFIG_FDT_SPI) += fdt_spi.o
  obj-$(CONFIG_TEGRA20_SFLASH) += tegra20_sflash.o
 diff --git a/drivers/spi/sh_qspi.c b/drivers/spi/sh_qspi.c
 new file mode 100644
 index 000..8f53552
 --- /dev/null
 +++ b/drivers/spi/sh_qspi.c
 @@ -0,0 +1,244 @@
 +/*
 + * SH QSPI (Quad SPI) driver
 + *
 + * Copyright (C) 2013 Renesas Electronics Corporation
 + * Copyright (C) 2013 Nobuhiro Iwamatsu nobuhiro.iwamatsu...@renesas.com
 + *
 + * SPDX-License-Identifier:GPL-2.0
 + */
 +
 +#include common.h
 +#include malloc.h
 +#include spi.h
 +#include asm/io.h
 +
 +/* SH QSPI register bit masks REG_BIT */
 +#define SPCR_MSTR  0x08
 +#define SPCR_SPE   0x40
 +#define SPSR_SPRFF 0x80
 +#define SPSR_SPTEF 0x20
 +#define SPPCR_IO3FV0x04
 +#define SPPCR_IO2FV0x02
 +#define SPPCR_IO1FV0x01
 +#define SPBDCR_RXBC0   (1  0)
 +#define SPCMD_SCKDEN   (1  15)
 +#define SPCMD_SLNDEN   (1  14)
 +#define SPCMD_SPNDEN   (1  13)
 +#define SPCMD_SSLKP(1  7)
 +#define SPCMD_BRDV0(1  2)
 +#define SPCMD_INIT1SPCMD_SCKDEN | SPCMD_SLNDEN | \
 +   SPCMD_SPNDEN | SPCMD_SSLKP | \
 +   SPCMD_BRDV0
 +#define SPCMD_INIT2SPCMD_SPNDEN | SPCMD_SSLKP | \
 +   SPCMD_BRDV0
 +#define SPBFCR_TXRST   (1  7)
 +#define SPBFCR_RXRST   (1  6)
 +
 +/* SH QSPI register set */
 +struct sh_qspi_regs {
 +   unsigned char spcr;
 +   unsigned char sslp;
 +   unsigned char sppcr;
 +   unsigned char spsr;
 +   unsigned long spdr;
 +   unsigned char spscr;
 +   unsigned char spssr;
 +   unsigned char spbr;
 +   unsigned char spdcr;
 +   unsigned char spckd;
 +   unsigned char sslnd;
 +   unsigned char spnd;
 +   unsigned char dummy0;
 +   unsigned short spcmd0;
 +   unsigned short spcmd1;
 +   unsigned short spcmd2;
 +   unsigned short spcmd3;
 +   unsigned char spbfcr;
 +   unsigned char dummy1;
 +   unsigned short spbdcr;
 +   unsigned long spbmul0;
 +   unsigned long spbmul1;
 +   unsigned long spbmul2;
 +   unsigned long spbmul3;
 +};
 +
 +struct sh_qspi_slave {
 +   struct spi_slaveslave;
 +   struct sh_qspi_regs *regs;
 +};
 +
 +static inline struct sh_qspi_slave *to_sh_qspi(struct spi_slave *slave)
 +{
 +   return container_of(slave, struct sh_qspi_slave, slave);
 +}
 +
 +static void sh_qspi_init(struct sh_qspi_slave *ss)
 +{
 +   /* QSPI initialize */
 +   writeb(SPCR_MSTR, ss-regs-spcr);
 +   writeb(0x00, ss-regs-sslp);
 +   writeb(SPPCR_IO3FV|SPPCR_IO2FV, ss-regs-sppcr);
 +
 +   /* Set bit rate. See 58.3.8 Quad Serial Peripheral Interface */
 +   writeb(0x01, ss-regs-spbr);
 +
 +   writeb(0x00, ss-regs-spdcr);
 +   writeb(0x00, ss-regs-spckd);
 +   writeb(0x00, ss-regs-sslnd);
 +   writeb(0x00, ss-regs-spnd);
 +   writew(SPCMD_INIT1, ss-regs-spcmd0);
 +   writew(SPCMD_INIT2, ss-regs-spcmd0);
 +   writeb(SPBFCR_TXRST|SPBFCR_RXRST, ss-regs-spbfcr);
 +   writeb(0x00, ss-regs-spbfcr);
 +   writeb(0x00, ss-regs-spscr);
 +   writeb(SPCR_SPE|SPCR_MSTR, ss-regs-spcr);
 +}
Please try to write comments on each initialization steps.
- refer code in drivers/spi/zynq_spi.c

 +
 +int spi_cs_is_valid(unsigned int bus, unsigned int cs)
 

Re: [U-Boot] [PATCH v3 1/4] mkexynosspl: fix uninitialized buffer

2013-12-15 Thread Rajeshwari Birje
Hi Albert,

Please refer the following patch:

SPL: EXYNOS: Prepare for variable size SPL support

http://patchwork.ozlabs.org/patch/298965/

I don't think after this patch is applied, the above patch would be required.

Regards,
Rajeshwari.


On Mon, Dec 16, 2013 at 6:18 AM, Minkyu Kang mk7.k...@samsung.com wrote:
 Dear Albert ARIBAUD,

 On 14/12/13 19:14, Albert ARIBAUD wrote:
 Hi Minkyu,

 On Sat, 14 Dec 2013 14:07:57 +0900, Minkyu Kang mk7.k...@samsung.com
 wrote:

 Dear Albert,

 On 13/12/13 18:00, Albert ARIBAUD wrote:
 (adding Minkyu as the Samsung custodian)

 On Mon,  9 Dec 2013 18:09:18 +0100, Albert ARIBAUD
 albert.u.b...@aribaud.net wrote:

 mkexynos reads its input file which might be smaller than

 ( typo: s/mkexynos/mkexynosspl/ -- wil fix when applying if thee is
 no other change to be made )

 its read buffer, but always writes the whole buffer out.
 This does not affect the functionalyty of the output file,

 ... and s/functionalyty/functionality/, too.

 but it makes its content unpredictable as the end of the
 buffer is never initialized. Fix this by zeroing the buffer
 before reading the input file.

 Minkyu: should the buffer be pre-filled with zeroes or should I use
 ones instead? Or maybe the output could be truncated to the size of the
 input?

 Basically, the output file is fixed to 14K as same as buffer size.
 And the input file should be smaller than 14K.
 It's the rule of exynos spl.
 The role of mkexynosspl is just adding 4 byte checksum value to end of file.
 If the input file is bigger than 14K, output will be truncated.


 Amicalement,
 Albert.

 Signed-off-by: Albert ARIBAUD albert.u.b...@aribaud.net

 btw, this change looks reasonable to me.

 Acked-by: Minkyu Kang mk7.k...@samsung.com

 Thanks! If that's ok with you, I'll apply 1/4 to ARM, considering it a
 kind of bugfix, and remove it from V4 of the patch series if there is
 any.

 Or if you prefer to apply 1/4 to u-boot-samsung, that's fine with me.

 please apply this patch to u-boot-arm.


 Thanks,
 Minkyu Kang.

 Amicalement,


 Thanks,
 Minkyu Kang.
 ___
 U-Boot mailing list
 U-Boot@lists.denx.de
 http://lists.denx.de/mailman/listinfo/u-boot



-- 
Regards,
Rajeshwari Shinde
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot