Skip to contentSkip to conversation

Add CONFIG_HDBOOTCOMMAND to the environment

PATCH New Kumar Gala 2 participants 3 messages Aug 21, 2008 – Aug 25, 2008

lore
Share & tools
lore

Kumar Gala

author
#0 lore raw

PATCH 1/1 Add CONFIG_HDBOOTCOMMAND to the environment

Provide a boot command for being able to boot from a hard drive

---
 common/env_common.c  |    3 +++
 common/environment.c |    3 +++
 tools/env/fw_env.c   |    3 +++
 3 files changed, 9 insertions(+), 0 deletions(-)
common/env_common.c +3 -0
index d51c211..271e71f 100644
@@ -64,6 +64,9 @@ uchar default_environment[] = {
 #ifdef	CONFIG_BOOTCOMMAND
 	"bootcmd="	CONFIG_BOOTCOMMAND		"\0"
 #endif
+#ifdef	CONFIG_HDBOOTCOMMAND
+	"hdboot="	CONFIG_HDBOOTCOMMAND		"\0"
+#endif
 #ifdef	CONFIG_RAMBOOTCOMMAND
 	"ramboot="	CONFIG_RAMBOOTCOMMAND		"\0"
 #endif
common/environment.c +3 -0
index 3b9914f..17377a7 100644
@@ -108,6 +108,9 @@ env_t environment __PPCENV__ = {
 #if defined(CONFIG_BOOTCOMMAND)
 	"bootcmd="	CONFIG_BOOTCOMMAND		"\0"
 #endif
+#ifdef	CONFIG_HDBOOTCOMMAND
+	"hdboot="	CONFIG_HDBOOTCOMMAND		"\0"
+#endif
 #if defined(CONFIG_RAMBOOTCOMMAND)
 	"ramboot="	CONFIG_RAMBOOTCOMMAND		"\0"
 #endif
tools/env/fw_env.c +3 -0
index b8bca91..6520c22 100644
@@ -87,6 +87,9 @@ static char default_environment[] = {
 #if defined(CONFIG_BOOTCOMMAND)
 	"bootcmd=" CONFIG_BOOTCOMMAND "\0"
 #endif
+#ifdef	CONFIG_HDBOOTCOMMAND
+	"hdboot=" CONFIG_HDBOOTCOMMAND "\0"
+#endif
 #if defined(CONFIG_RAMBOOTCOMMAND)
 	"ramboot=" CONFIG_RAMBOOTCOMMAND "\0"
 #endif
Signature · 1 line
1.5.5.1
#1 lore raw

PATCH 1/1 Add CONFIG_HDBOOTCOMMAND to the environment

Dear Kumar Gala,

Quoted 14 lines · In message <[email protected]> you…

Provide a boot command for being able to boot from a hard drive

---
 common/env_common.c  |    3 +++
 common/environment.c |    3 +++
 tools/env/fw_env.c   |    3 +++
 3 files changed, 9 insertions(+), 0 deletions(-)
common/env_common.c +0 -0
index d51c211..271e71f 100644

common/env_common.c uchar default_environment[] = { · line 72

Quoted 9 lines
common/env_common.c +3 -0
@@ -64,6 +64,9 @@ uchar default_environment[] = {
 #ifdef	CONFIG_BOOTCOMMAND
 	"bootcmd="	CONFIG_BOOTCOMMAND		"\0"
 #endif
+#ifdef	CONFIG_HDBOOTCOMMAND
+	"hdboot="	CONFIG_HDBOOTCOMMAND		"\0"
+#endif
 #ifdef	CONFIG_RAMBOOTCOMMAND
 	"ramboot="	CONFIG_RAMBOOTCOMMAND		"\0"
 #endif

The percentage of boards that actually have a HDD is so small that I do not think such an addition to these global files is justified, especially since it is trivial to add a definition of such an environment variable through a CONFIG_EXTRA_ENV_SETTINGS definition.

Or is there a specific reason why CONFIG_EXTRA_ENV_SETTINGS would not work for you?

Best regards,

Wolfgang Denk

Signature · 6 lines
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
We, the unwilling, led by the unknowing, are doing the impossible for
the ungrateful. We have done so much, for so long, with so little, we
are now qualified to do anything with nothing.
author
#2 lore raw

PATCH 1/1 Add CONFIG_HDBOOTCOMMAND to the environment

Quoted 33 lines · Wolfgang Denk

Dear Kumar Gala,

In message <[email protected]

Quoted 15 lines

you wrote:
Provide a boot command for being able to boot from a hard drive

---

common/env_common.c  |    3 +++
common/environment.c |    3 +++
tools/env/fw_env.c   |    3 +++
3 files changed, 9 insertions(+), 0 deletions(-)
common/env_common.c +0 -0
index d51c211..271e71f 100644

common/env_common.c uchar default_environment[] = { · line 72

Quoted 9 lines
common/env_common.c +3 -0
@@ -64,6 +64,9 @@ uchar default_environment[] = {
 #ifdef	CONFIG_BOOTCOMMAND
 	"bootcmd="	CONFIG_BOOTCOMMAND		"\0"
 #endif
+#ifdef	CONFIG_HDBOOTCOMMAND
+	"hdboot="	CONFIG_HDBOOTCOMMAND		"\0"
+#endif
 #ifdef	CONFIG_RAMBOOTCOMMAND
 	"ramboot="	CONFIG_RAMBOOTCOMMAND		"\0"
 #endif

The percentage of boards that actually have a HDD is so small that I do not think such an addition to these global files is justified, especially since it is trivial to add a definition of such an environment variable through a CONFIG_EXTRA_ENV_SETTINGS definition.

Quoted 2 lines

Or is there a specific reason why CONFIG_EXTRA_ENV_SETTINGS would not work for you?

Nope, that solution works as good as any.

- k