All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Add console kernel options
@ 2012-07-19 11:59 Radu Moisan
  2012-07-20  3:58 ` Saul Wold
  0 siblings, 1 reply; 2+ messages in thread
From: Radu Moisan @ 2012-07-19 11:59 UTC (permalink / raw)
  To: openembedded-core

Live image installer did not preserve BSP specified console= kernel parameter.
This patch updates the init scripts that are responsible for grub.cfg creation
so that options like console= are passed allong from installer to installed img

[YOCTO #2426]

Signed-off-by: Radu Moisan <radu.moisan@intel.com>
---
 meta/recipes-bsp/grub/grub-1.99/40_custom          |    2 +-
 .../initrdscripts/files/init-install.sh            |    1 +
 meta/recipes-core/initrdscripts/files/init-live.sh |    8 +++++++-
 3 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-bsp/grub/grub-1.99/40_custom b/meta/recipes-bsp/grub/grub-1.99/40_custom
index 0d80854..ba48830 100755
--- a/meta/recipes-bsp/grub/grub-1.99/40_custom
+++ b/meta/recipes-bsp/grub/grub-1.99/40_custom
@@ -5,5 +5,5 @@ exec tail -n +3 $0
 # the 'exec tail' line above.
 menuentry "Linux" {
     set root=(hd0,1)
-    linux /boot/vmlinuz root=__ROOTFS__ rw __VIDEO_MODE__ __VGA_MODE__ quiet
+    linux /boot/vmlinuz root=__ROOTFS__ rw __CONSOLE__ __VIDEO_MODE__ __VGA_MODE__ quiet
 }
diff --git a/meta/recipes-core/initrdscripts/files/init-install.sh b/meta/recipes-core/initrdscripts/files/init-install.sh
index 0ac4949..c1f8cba 100644
--- a/meta/recipes-core/initrdscripts/files/init-install.sh
+++ b/meta/recipes-core/initrdscripts/files/init-install.sh
@@ -156,6 +156,7 @@ if [ -f /ssd/etc/grub.d/40_custom ] ; then
     sed -i "s@__ROOTFS__@$rootfs $rootwait@g" /ssd/etc/grub.d/40_custom
     sed -i "s/__VIDEO_MODE__/$3/g" /ssd/etc/grub.d/40_custom
     sed -i "s/__VGA_MODE__/$4/g" /ssd/etc/grub.d/40_custom
+    sed -i "s/__CONSOLE__/$5/g" /ssd/etc/grub.d/40_custom
     mount $bootfs /bootmnt
     cp /ssd/etc/grub.d/40_custom /bootmnt/40_custom
     umount /bootmnt
diff --git a/meta/recipes-core/initrdscripts/files/init-live.sh b/meta/recipes-core/initrdscripts/files/init-live.sh
index 737dae4..d5e241a 100644
--- a/meta/recipes-core/initrdscripts/files/init-live.sh
+++ b/meta/recipes-core/initrdscripts/files/init-live.sh
@@ -38,6 +38,12 @@ read_args() {
                 video_mode=$arg ;;
             vga=*)
                 vga_mode=$arg ;;
+            console=*)
+                if [ -z "${console_params}" ]; then
+                    console_params=$arg
+                else
+                    console_params="$console_params $arg"
+                fi
         esac
     done
 }
@@ -112,7 +118,7 @@ case $label in
 	;;
     install)
 	if [ -f /media/$i/$ISOLINUX/$ROOT_IMAGE ] ; then
-	    ./install.sh $i/$ISOLINUX $ROOT_IMAGE $video_mode $vga_mode
+	    ./install.sh $i/$ISOLINUX $ROOT_IMAGE $video_mode $vga_mode $console_params
 	else
 	    fatal "Could not find install script"
 	fi
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] Add console kernel options
  2012-07-19 11:59 [PATCH] Add console kernel options Radu Moisan
@ 2012-07-20  3:58 ` Saul Wold
  0 siblings, 0 replies; 2+ messages in thread
From: Saul Wold @ 2012-07-20  3:58 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On 07/19/2012 04:59 AM, Radu Moisan wrote:
> Live image installer did not preserve BSP specified console= kernel parameter.
> This patch updates the init scripts that are responsible for grub.cfg creation
> so that options like console= are passed allong from installer to installed img
>
> [YOCTO #2426]
>
> Signed-off-by: Radu Moisan <radu.moisan@intel.com>
> ---
>   meta/recipes-bsp/grub/grub-1.99/40_custom          |    2 +-
>   .../initrdscripts/files/init-install.sh            |    1 +
>   meta/recipes-core/initrdscripts/files/init-live.sh |    8 +++++++-
>   3 files changed, 9 insertions(+), 2 deletions(-)
>
> diff --git a/meta/recipes-bsp/grub/grub-1.99/40_custom b/meta/recipes-bsp/grub/grub-1.99/40_custom
> index 0d80854..ba48830 100755
> --- a/meta/recipes-bsp/grub/grub-1.99/40_custom
> +++ b/meta/recipes-bsp/grub/grub-1.99/40_custom
> @@ -5,5 +5,5 @@ exec tail -n +3 $0
>   # the 'exec tail' line above.
>   menuentry "Linux" {
>       set root=(hd0,1)
> -    linux /boot/vmlinuz root=__ROOTFS__ rw __VIDEO_MODE__ __VGA_MODE__ quiet
> +    linux /boot/vmlinuz root=__ROOTFS__ rw __CONSOLE__ __VIDEO_MODE__ __VGA_MODE__ quiet
>   }
> diff --git a/meta/recipes-core/initrdscripts/files/init-install.sh b/meta/recipes-core/initrdscripts/files/init-install.sh
> index 0ac4949..c1f8cba 100644
> --- a/meta/recipes-core/initrdscripts/files/init-install.sh
> +++ b/meta/recipes-core/initrdscripts/files/init-install.sh
> @@ -156,6 +156,7 @@ if [ -f /ssd/etc/grub.d/40_custom ] ; then
>       sed -i "s@__ROOTFS__@$rootfs $rootwait@g" /ssd/etc/grub.d/40_custom
>       sed -i "s/__VIDEO_MODE__/$3/g" /ssd/etc/grub.d/40_custom
>       sed -i "s/__VGA_MODE__/$4/g" /ssd/etc/grub.d/40_custom
> +    sed -i "s/__CONSOLE__/$5/g" /ssd/etc/grub.d/40_custom
>       mount $bootfs /bootmnt
>       cp /ssd/etc/grub.d/40_custom /bootmnt/40_custom
>       umount /bootmnt
> diff --git a/meta/recipes-core/initrdscripts/files/init-live.sh b/meta/recipes-core/initrdscripts/files/init-live.sh
> index 737dae4..d5e241a 100644
> --- a/meta/recipes-core/initrdscripts/files/init-live.sh
> +++ b/meta/recipes-core/initrdscripts/files/init-live.sh
> @@ -38,6 +38,12 @@ read_args() {
>                   video_mode=$arg ;;
>               vga=*)
>                   vga_mode=$arg ;;
> +            console=*)
> +                if [ -z "${console_params}" ]; then
> +                    console_params=$arg
> +                else
> +                    console_params="$console_params $arg"
> +                fi
>           esac
>       done
>   }
> @@ -112,7 +118,7 @@ case $label in
>   	;;
>       install)
>   	if [ -f /media/$i/$ISOLINUX/$ROOT_IMAGE ] ; then
> -	    ./install.sh $i/$ISOLINUX $ROOT_IMAGE $video_mode $vga_mode
> +	    ./install.sh $i/$ISOLINUX $ROOT_IMAGE $video_mode $vga_mode $console_params
>   	else
>   	    fatal "Could not find install script"
>   	fi
>

Merged into OE-Core

Thanks
	Sau!



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-07-20  4:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-19 11:59 [PATCH] Add console kernel options Radu Moisan
2012-07-20  3:58 ` Saul Wold

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.