[U-Boot] [PATCH] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD

2014-07-07 Thread Maxin B. John
This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD
introduced by the commit:

commit dfe64e2c89731a3f9950d7acd8681b68df2bae03
Author: Sergey Lapin 
Date:   Mon Jan 14 03:46:50 2013 +

mtd: resync with Linux-3.7.1

Signed-off-by: Maxin B. John 
---
 drivers/mtd/mtdcore.c |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
index 0a38fbe..328a2b9 100644
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@ -167,7 +167,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
*truncated = 0;
*len_incl_bad = 0;
 
-   if (!mtd->block_isbad) {
+   if (!mtd->_block_isbad) {
*len_incl_bad = length;
return;
}
@@ -183,7 +183,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
 
block_len = mtd->erasesize - (offset & (mtd->erasesize - 1));
 
-   if (!mtd->block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
+   if (!mtd->_block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
len_excl_bad += block_len;
 
*len_incl_bad += block_len;
-- 
1.7.5.4

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


Re: [U-Boot] [PATCH] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD

2014-07-07 Thread Maxin B. John
Dear Wolfgang,

On Mon, Jul 07, 2014 at 02:17:09PM +0200, Wolfgang Denk wrote:
> Dear Maxin,
> 
> In message <1404729444-10957-1-git-send-email-maxin.j...@enea.com> you wrote:
> > This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD
> > introduced by the commit:
> > 
> > commit dfe64e2c89731a3f9950d7acd8681b68df2bae03
> > Author: Sergey Lapin 
> > Date:   Mon Jan 14 03:46:50 2013 +
> > 
> > mtd: resync with Linux-3.7.1
> 
> Can you please check if this patch is still needed with the updated
> MTD code posted by Heiko [1] - and if so, rebase your patch against
> Heiko's code base?
> 
> Thanks.
> 
> [1] http://article.gmane.org/gmane.comp.boot-loaders.u-boot/189358

Thank you very much for pointing this out. I have tested Heiko's code
available here:
repo:  git://git.denx.de/u-boot-testing.git
branch: update-v3-mtd+ubi-linux-v3.14

The build error that was mentioned in this mail is still valid there:

  LD  drivers/pcmcia/built-in.o
drivers/mtd/mtdcore.c: In function 'mtd_get_len_incl_bad':
drivers/mtd/mtdcore.c:805:10: error: 'struct mtd_info' has no member
named 'block_isbad'
drivers/mtd/mtdcore.c:821:11: error: 'struct mtd_info' has no member
named 'block_isbad'
  CC  drivers/rtc/date.o
make[1]: *** [drivers/mtd/mtdcore.o] Error 1
make: *** [drivers/mtd] Error 2
make: *** Waiting for unfinished jobs

Also re-created patch against this. Should I send it as a separate
patch or would you suggest another branch for this fix ?
 
> 
> Best regards,
> Wolfgang Denk

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


[U-Boot] [PATCH v2] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD

2014-07-07 Thread Maxin B. John
This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD
introduced by the commit:

commit dfe64e2c89731a3f9950d7acd8681b68df2bae03
Author: Sergey Lapin 
Date:   Mon Jan 14 03:46:50 2013 +

mtd: resync with Linux-3.7.1

v2 changes:
Rebased the patch against Heiko's code base:
http://article.gmane.org/gmane.comp.boot-loaders.u-boot/189358
So,Heiko's update should be applied first.

Signed-off-by: Maxin B. John 
---
 drivers/mtd/mtdcore.c |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
index 796ac07..3596b06 100644
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@ -802,7 +802,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
*truncated = 0;
*len_incl_bad = 0;
 
-   if (!mtd->block_isbad) {
+   if (!mtd->_block_isbad) {
*len_incl_bad = length;
return;
}
@@ -818,7 +818,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
 
block_len = mtd->erasesize - (offset & (mtd->erasesize - 1));
 
-   if (!mtd->block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
+   if (!mtd->_block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
len_excl_bad += block_len;
 
*len_incl_bad += block_len;
-- 
1.7.5.4

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


[U-Boot] [PATCH] vitesse: remove duplicated argument to ||

2014-07-24 Thread Maxin B. John
Remove the duplicated argument to || check

Signed-off-by: Maxin B. John 
---
 drivers/net/phy/vitesse.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/phy/vitesse.c b/drivers/net/phy/vitesse.c
index c58fe50..2b29cd8 100644
--- a/drivers/net/phy/vitesse.c
+++ b/drivers/net/phy/vitesse.c
@@ -126,7 +126,6 @@ static int cis8204_config(struct phy_device *phydev)
genphy_config_aneg(phydev);
 
if ((phydev->interface == PHY_INTERFACE_MODE_RGMII) ||
-   (phydev->interface == PHY_INTERFACE_MODE_RGMII) ||
(phydev->interface == PHY_INTERFACE_MODE_RGMII_TXID) ||
(phydev->interface == PHY_INTERFACE_MODE_RGMII_RXID))
phy_write(phydev, MDIO_DEVAD_NONE, MIIM_CIS8204_EPHY_CON,
-- 
1.9.1

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


[U-Boot] [PATCH] emif.h: remove duplicated argument to |

2014-07-24 Thread Maxin B. John
Remove the duplicated argument to | in two places. Reported
by Coccinelle (http://coccinelle.lip6.fr/).

Signed-off-by: Maxin B. John 
---
 arch/arm/include/asm/emif.h | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/arch/arm/include/asm/emif.h b/arch/arm/include/asm/emif.h
index b8d6bdc..2fe5776 100644
--- a/arch/arm/include/asm/emif.h
+++ b/arch/arm/include/asm/emif.h
@@ -878,7 +878,6 @@ struct dmm_lisa_map_regs {
((REG_CS_TIM << EMIF_REG_CS_TIM_SHIFT) & EMIF_REG_CS_TIM_MASK)|\
((REG_SR_TIM << EMIF_REG_SR_TIM_SHIFT) & EMIF_REG_SR_TIM_MASK)|\
((REG_PD_TIM << EMIF_REG_PD_TIM_SHIFT) & EMIF_REG_PD_TIM_MASK)|\
-   ((REG_PD_TIM << EMIF_REG_PD_TIM_SHIFT) & EMIF_REG_PD_TIM_MASK)|\
((LP_MODE_DISABLE << EMIF_REG_LP_MODE_SHIFT)\
& EMIF_REG_LP_MODE_MASK) |\
((DPD_DISABLE << EMIF_REG_DPD_EN_SHIFT)\
@@ -890,8 +889,6 @@ struct dmm_lisa_map_regs {
((REG_SR_TIM << EMIF_REG_SR_TIM_SHDW_SHIFT)\
& EMIF_REG_SR_TIM_SHDW_MASK) |\
((REG_PD_TIM << EMIF_REG_PD_TIM_SHDW_SHIFT)\
-   & EMIF_REG_PD_TIM_SHDW_MASK) |\
-   ((REG_PD_TIM << EMIF_REG_PD_TIM_SHDW_SHIFT)\
& EMIF_REG_PD_TIM_SHDW_MASK))
 
 /* EMIF_L3_CONFIG register value */
-- 
1.9.1

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


[U-Boot] [PATCH] cosmetic: mconf.c: remove texts referring to modules

2014-08-01 Thread Maxin B. John
As we don't have the concept of 'loadable modules' in u-boot,
remove texts referring to modules.

Signed-off-by: Maxin B. John 
---
 scripts/kconfig/mconf.c | 23 +--
 1 file changed, 9 insertions(+), 14 deletions(-)

diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c
index 14cea74..1c952b5 100644
--- a/scripts/kconfig/mconf.c
+++ b/scripts/kconfig/mconf.c
@@ -26,21 +26,21 @@ static const char mconf_readme[] = N_(
 "Overview\n"
 "\n"
 "This interface lets you select features and parameters for the build.\n"
-"Features can either be built-in, modularized, or ignored. Parameters\n"
+"Features can either be built-in or ignored. Parameters\n"
 "must be entered in as decimal or hexadecimal numbers or text.\n"
 "\n"
 "Menu items beginning with following braces represent features that\n"
 "  [ ] can be built in or removed\n"
-"  < > can be built in, modularized or removed\n"
-"  { } can be built in or modularized (selected by other feature)\n"
+"  < > can be built in or removed\n"
+"  { } can be built in (selected by other feature)\n"
 "  - - are selected by other feature,\n"
-"while *, M or whitespace inside braces means to build in, build as\n"
-"a module or to exclude the feature respectively.\n"
+"while * or whitespace inside braces means to build in\n"
+"or to exclude the feature respectively.\n"
 "\n"
 "To change any of these features, highlight it with the cursor\n"
-"keys and press  to build it in,  to make it a module or\n"
+"keys and press  to build it in or\n"
 " to remove it.  You may also press the  to cycle\n"
-"through the available options (i.e. Y->N->M->Y).\n"
+"through the available options (i.e. Y->N->Y).\n"
 "\n"
 "Some additional keyboard hints:\n"
 "\n"
@@ -176,9 +176,9 @@ menu_instructions[] = N_(
"Arrow keys navigate the menu.  "
" selects submenus ---> (or empty submenus ).  "
"Highlighted letters are hotkeys.  "
-   "Pressing  includes,  excludes,  modularizes features.  "
+   "Pressing  includes,  excludes features.  "
"Press  to exit,  for Help,  for Search.  "
-   "Legend: [*] built-in  [ ] excluded   module  < > module capable"),
+   "Legend: [*] built-in  [ ] excluded"),
 radiolist_instructions[] = N_(
"Use the arrow keys to navigate this window or "
"press the hotkey of the item you wish to select "
@@ -194,9 +194,6 @@ inputbox_instructions_hex[] = N_(
 inputbox_instructions_string[] = N_(
"Please enter a string value. "
"Use the  key to move from the input field to the buttons below 
it."),
-setmod_text[] = N_(
-   "This feature depends on another which has been configured as a 
module.\n"
-   "As a result, this feature will be built as a module."),
 load_config_text[] = N_(
"Enter the name of the configuration file you wish to load.  "
"Accept the name shown to restore the configuration you "
@@ -722,8 +719,6 @@ static void conf(struct menu *menu, struct menu 
*active_menu)
if (item_is_tag('t')) {
if (sym_set_tristate_value(sym, yes))
break;
-   if (sym_set_tristate_value(sym, mod))
-   show_textbox(NULL, setmod_text, 6, 74);
}
break;
case 6:
-- 
1.9.1

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


Re: [U-Boot] [PATCH] cosmetic: mconf.c: remove texts referring to modules

2014-08-01 Thread Maxin B. John
Hi Masahiro-san,

On Fri, Aug 01, 2014 at 07:42:06PM +0900, Masahiro Yamada wrote:
> Hi.
> 
> 
> On Fri, 1 Aug 2014 11:38:56 +0200
> "Maxin B. John"  wrote:
> 
> > As we don't have the concept of 'loadable modules' in u-boot,
> > remove texts referring to modules.
> > 
> > Signed-off-by: Maxin B. John 
> 
> Thanks for your patch, but personally, I am against this patch.
> 
> It is true the help message mentioning loadable modules is funny
> but it is almost harmless.
> 
> So I vote for keeping this file in sync with Linux.

I agree with your opinion. This was just a cosmetic change anyway.
Please ignore this patch.
 
> Besides, we already have a similar concept feature, so-called
> "standalone" application.
> Perhaps we can use Kconfig's loadable modules feature
> for the standalone application...
> 
> Waiting for comments from other people.
> 
> 
> Best Regards
> Masahiro Yamada

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


[U-Boot] [PATCH] cmd_part: fix usage text

2015-04-27 Thread Maxin B. John
Fix the usage info from:
part part uuid  :
to
part uuid  :

Signed-off-by: Maxin B. John 
---
 common/cmd_part.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/cmd_part.c b/common/cmd_part.c
index d04588e..8483c12 100644
--- a/common/cmd_part.c
+++ b/common/cmd_part.c
@@ -128,7 +128,7 @@ static int do_part(cmd_tbl_t *cmdtp, int flag, int argc, 
char * const argv[])
 U_BOOT_CMD(
part,   CONFIG_SYS_MAXARGS, 1,  do_part,
"disk partition related commands",
-   "part uuid  :\n"
+   "uuid  :\n"
"- print partition UUID\n"
"part uuid  : \n"
"- set environment variable to partition UUID\n"
-- 
1.9.1

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


[U-Boot] [PATCH] mx6sabre_common.h: remove deprecated mmc open/close

2015-03-03 Thread Maxin B. John
Replace "mmc open/close" with "mmc dev" in mx6sabre_common.h as those commands
were removed with this commit: 614b2bf1c9bf80dbad24f5e5ce1d115bf24a831d

cmd_mmc.c: Drop open/close mmc sub-commands

Signed-off-by: Maxin B. John 
---
 include/configs/mx6sabre_common.h | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/include/configs/mx6sabre_common.h 
b/include/configs/mx6sabre_common.h
index 4aa8101..ea39a1c 100644
--- a/include/configs/mx6sabre_common.h
+++ b/include/configs/mx6sabre_common.h
@@ -109,12 +109,10 @@
"setenv get_cmd tftp; " \
"fi; " \
"if ${get_cmd} ${update_sd_firmware_filename}; then " \
-   "if mmc dev ${emmcdev} && " \
-   "mmc open ${emmcdev} 1; then "  \
+   "if mmc dev ${emmcdev} 1; then "\
"setexpr fw_sz ${filesize} / 0x200; " \
"setexpr fw_sz ${fw_sz} + 1; "  \
"mmc write ${loadaddr} 0x2 ${fw_sz}; " \
-   "mmc close ${emmcdev} 1; " \
"fi; "  \
"fi\0"
 #else
-- 
1.9.1

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


[U-Boot] [PATCH] ARM: omap4_panda: enable saveenv command

2015-03-18 Thread Maxin B. John
Enable saveenv command and the configs to store environment
persistently in the SD card.

Tested on OMAP4 Panda (OMAP4460 ES1.1)

Signed-off-by: Maxin B. John 
---
 include/configs/omap4_panda.h | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/include/configs/omap4_panda.h b/include/configs/omap4_panda.h
index 7378acd..e97c5e3 100644
--- a/include/configs/omap4_panda.h
+++ b/include/configs/omap4_panda.h
@@ -43,8 +43,13 @@
 #define CONFIG_CMD_GPIO
 
 /* ENV related config options */
-#define CONFIG_ENV_IS_NOWHERE
 
 #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
+#define CONFIG_ENV_IS_IN_FAT
+#define FAT_ENV_INTERFACE   "mmc"
+#define FAT_ENV_DEVICE_AND_PART "0:1"
+#define FAT_ENV_FILE"uboot.env"
+#define CONFIG_CMD_SAVEENV
+#define CONFIG_ENV_OVERWRITE
 
 #endif /* __CONFIG_PANDA_H */
-- 
1.9.1

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


[U-Boot] [PATCH] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD

2014-09-08 Thread Maxin B. John
This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD

Signed-off-by: Maxin B. John 
---
 drivers/mtd/mtdcore.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
index 6ad0357..c9efb3f 100644
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@ -804,7 +804,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
*truncated = 0;
*len_incl_bad = 0;
 
-   if (!mtd->block_isbad) {
+   if (!mtd->_block_isbad) {
*len_incl_bad = length;
return;
}
@@ -820,7 +820,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
offset,
 
block_len = mtd->erasesize - (offset & (mtd->erasesize - 1));
 
-   if (!mtd->block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
+   if (!mtd->_block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
len_excl_bad += block_len;
 
*len_incl_bad += block_len;
-- 
1.9.1

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


Re: [U-Boot] [PATCH] mtdcore: Fix a build error with CONFIG_CMD_MTDPARTS_SPREAD

2014-09-15 Thread Maxin B. John
Gentle ping.

On Mon, Sep 08, 2014 at 07:04:16PM +0200, Maxin B. John wrote:
> This patch fixes the build error for CONFIG_CMD_MTDPARTS_SPREAD
> 
> Signed-off-by: Maxin B. John 
> ---
>  drivers/mtd/mtdcore.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
> index 6ad0357..c9efb3f 100644
> --- a/drivers/mtd/mtdcore.c
> +++ b/drivers/mtd/mtdcore.c
> @@ -804,7 +804,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
> offset,
>   *truncated = 0;
>   *len_incl_bad = 0;
>  
> - if (!mtd->block_isbad) {
> + if (!mtd->_block_isbad) {
>   *len_incl_bad = length;
>   return;
>   }
> @@ -820,7 +820,7 @@ void mtd_get_len_incl_bad(struct mtd_info *mtd, uint64_t 
> offset,
>  
>   block_len = mtd->erasesize - (offset & (mtd->erasesize - 1));
>  
> - if (!mtd->block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
> + if (!mtd->_block_isbad(mtd, offset & ~(mtd->erasesize - 1)))
>   len_excl_bad += block_len;
>  
>   *len_incl_bad += block_len;
> -- 
> 1.9.1
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] Merrii_A80_Optimus: Fix build error

2015-06-03 Thread Maxin B. John
make Merrii_A80_Optimus_defconfig
make
fails with the following error:

board/sunxi/built-in.o: In function `misc_init_r':
/root/u-boot/board/sunxi/board.c:540: undefined reference to 
`eth_setenv_enetaddr'

Enable CONFIG_CMD_NET in Merrii_A80_Optimus_defconfig to fix it.

Signed-off-by: Maxin B. John 
---
 configs/Merrii_A80_Optimus_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/configs/Merrii_A80_Optimus_defconfig 
b/configs/Merrii_A80_Optimus_defconfig
index 6bd5273..b112596 100644
--- a/configs/Merrii_A80_Optimus_defconfig
+++ b/configs/Merrii_A80_Optimus_defconfig
@@ -9,3 +9,4 @@ CONFIG_MACH_SUN9I=y
 CONFIG_DRAM_CLK=360
 CONFIG_DRAM_ZQ=123
 CONFIG_SYS_CLK_FREQ=100800
+CONFIG_CMD_NET=y
-- 
1.9.1

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


[U-Boot] [PATCH] Bananapi: Fix ethernet device initialization

2015-06-07 Thread Maxin B. John
Ethernet device initialization fails with the following message:
Net:   PH: dir_output: error: gpio PH23 not reserved
Phy 1 not found
PHY reset timed out
eth0: ethernet@01c5

Tested on Banana Pi board.

Signed-off-by: Maxin B. John 
---
 arch/arm/cpu/armv7/sunxi/board.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/cpu/armv7/sunxi/board.c b/arch/arm/cpu/armv7/sunxi/board.c
index a82c8b9..030a711 100644
--- a/arch/arm/cpu/armv7/sunxi/board.c
+++ b/arch/arm/cpu/armv7/sunxi/board.c
@@ -223,6 +223,7 @@ int cpu_eth_init(bd_t *bis)
__maybe_unused int rc;
 
 #ifdef CONFIG_MACPWR
+   gpio_request(CONFIG_MACPWR, "MAC Power");
gpio_direction_output(CONFIG_MACPWR, 1);
mdelay(200);
 #endif
-- 
1.9.1

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


Re: [U-Boot] [PATCH] Bananapi: Fix ethernet device initialization

2015-06-07 Thread Maxin B. John
Hi Paul,

On Sun, Jun 07, 2015 at 03:12:41PM +0200, Paul Kocialkowski wrote:
> Hi,
> 
> > Ethernet device initialization fails with the following message:
> > Net:   PH: dir_output: error: gpio PH23 not reserved
> > Phy 1 not found
> > PHY reset timed out
> > eth0: ethernet@01c5
> > 
> > Tested on Banana Pi board.
> > 
> > Signed-off-by: Maxin B. John 
> > ---
> >  arch/arm/cpu/armv7/sunxi/board.c | 1 +
> >  1 file changed, 1 insertion(+)
> > 
> > diff --git a/arch/arm/cpu/armv7/sunxi/board.c 
> > b/arch/arm/cpu/armv7/sunxi/board.c
> > index a82c8b9..030a711 100644
> > --- a/arch/arm/cpu/armv7/sunxi/board.c
> > +++ b/arch/arm/cpu/armv7/sunxi/board.c
> > @@ -223,6 +223,7 @@ int cpu_eth_init(bd_t *bis)
> > __maybe_unused int rc;
> >  
> >  #ifdef CONFIG_MACPWR
> > +   gpio_request(CONFIG_MACPWR, "MAC Power");
> 
> I suggest using the string "macpwr" instead to be consistent with:
> board/sunxi/ahci.c:   gpio_request(CONFIG_SATAPWR, "satapwr");
> 
> Good find otherwise!

Thanks for the comments. Will send a v2 soon.

> > gpio_direction_output(CONFIG_MACPWR, 1);
> > mdelay(200);
> >  #endif

Best Regards,
Maxin 


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


[U-Boot] [PATCH v2] Bananapi: Fix ethernet device initialization

2015-06-07 Thread Maxin B. John
Ethernet device initialization fails with the following message:
Net:   PH: dir_output: error: gpio PH23 not reserved
Phy 1 not found
PHY reset timed out
eth0: ethernet@01c5

Tested on Banana Pi board.

Signed-off-by: Maxin B. John 
---
 arch/arm/cpu/armv7/sunxi/board.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/cpu/armv7/sunxi/board.c b/arch/arm/cpu/armv7/sunxi/board.c
index a82c8b9..4b2494e 100644
--- a/arch/arm/cpu/armv7/sunxi/board.c
+++ b/arch/arm/cpu/armv7/sunxi/board.c
@@ -223,6 +223,7 @@ int cpu_eth_init(bd_t *bis)
__maybe_unused int rc;
 
 #ifdef CONFIG_MACPWR
+   gpio_request(CONFIG_MACPWR, "macpwr");
gpio_direction_output(CONFIG_MACPWR, 1);
mdelay(200);
 #endif
-- 
1.9.1

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


Re: [U-Boot] [PATCH] sunxi: Request macpwr gpio before using it

2015-06-07 Thread Maxin B. John
Hi,

On Sun, Jun 07, 2015 at 04:59:30PM +0200, Hans de Goede wrote:
> This fixes ethernet no longer working on boards which use a gpio to enable
> the phy.
> 
> Signed-off-by: Hans de Goede 
> ---

Looks like we sent the same patch to the mailing list today :)
http://lists.denx.de/pipermail/u-boot/2015-June/216084.html

>  arch/arm/cpu/armv7/sunxi/board.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/arch/arm/cpu/armv7/sunxi/board.c 
> b/arch/arm/cpu/armv7/sunxi/board.c
> index 215551f..bd0d819 100644
> --- a/arch/arm/cpu/armv7/sunxi/board.c
> +++ b/arch/arm/cpu/armv7/sunxi/board.c
> @@ -241,6 +241,7 @@ int cpu_eth_init(bd_t *bis)
>   __maybe_unused int rc;
>  
>  #ifdef CONFIG_MACPWR
> + gpio_request(CONFIG_MACPWR, "macpwr");
>   gpio_direction_output(CONFIG_MACPWR, 1);
>   mdelay(200);
>  #endif
> -- 
> 2.4.2

Tested the same on a Banana Pi board and if it matters,

Tested-by: Maxin B. John 

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


Re: [U-Boot] Compilation of env error u-boot 2015.07-rc2

2015-06-10 Thread Maxin B. John
Hi,

On Wed, Jun 10, 2015 at 10:29:47AM +0530, Thirumalesha N wrote:
> Hi all,
> 
> I have pulled latest code from u-boot main line through git.
> 
> Using linaro tool chain for am335x board
> 
> I'm trying to compile tools/env but its giving an error
> 
> #make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- env
> 
> HOSTCC tools/env/fw_env.o
> 
> arm-linux-gnueabihf/include/search.h:173:1 erro: expected '}' before
> 'NETARGS'
> make[1]: *** [ tools/env/few.env.o] error 1

I have managed to re-create the same problem.

Revert this commit: 2320866b978fc12904eeba37236f35d12b4aec30
ie: 
# git revert 2320866b978fc12904eeba37236f35d12b4aec30

and then try building again. 

Apparently network arguments were moved to ti_armv7_common.h. 
However, it wasn't included in the am335x config.

> 
> With same tool chain I'm able compile 2014 u-boot
> 
> Regards,
> Thiru N

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


Re: [U-Boot] [PATCH] ti: am335x/am437x/omap5 devices: Fix breakage when CONFIG_CMD_NET is not used

2015-06-10 Thread Maxin B. John
On Wed, Jun 10, 2015 at 08:54:02AM -0500, Franklin S Cooper Jr wrote:
> Currently there is no default value for NETARGS if CONFIG_CMD_NET=y isn't set.
> This results in build errors which was first discovered when trying to run
> make env.
> 
> By defining a blank NETARGS these errors can be avoided.
> 
> Signed-off-by: Franklin S Cooper Jr 
> ---
>  include/configs/ti_armv7_common.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/include/configs/ti_armv7_common.h 
> b/include/configs/ti_armv7_common.h
> index f882942..d1c390f 100644
> --- a/include/configs/ti_armv7_common.h
> +++ b/include/configs/ti_armv7_common.h
> @@ -301,7 +301,8 @@
>   "run netloadfdt; " \
>   "run netargs; " \
>   "bootz ${loadaddr} - ${fdtaddr}\0"
> -
> +#else
> +#define NETARGS ""
>  #endif
>  
>  #endif   /* __CONFIG_TI_ARMV7_COMMON_H__ */
> --

Build tested for am335x_evm, am43xx_evm and omap5_uevm.

Tested-by: Maxin B. John 
 
Best Regards,
Maxin
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot