* [PATCH] GRUB_GFXMODE_LINUX user variable
@ 2009-03-29 2:31 Robert Millan
2009-03-29 8:39 ` Yoshinori K. Okuji
0 siblings, 1 reply; 4+ messages in thread
From: Robert Millan @ 2009-03-29 2:31 UTC (permalink / raw)
To: grub-devel
[-- Attachment #1: Type: text/plain, Size: 357 bytes --]
This patch adds GRUB_GFXMODE_LINUX user variable to make it easy for
users to set graphical mode before booting Linux.
--
Robert Millan
The DRM opt-in fallacy: "Your data belongs to us. We will decide when (and
how) you may access your data; but nobody's threatening your freedom: we
still allow you to remove your data and not access it at all."
[-- Attachment #2: gfxmode_linux.diff --]
[-- Type: text/x-diff, Size: 1447 bytes --]
2009-03-29 Robert Millan <rmh@aybabtu.com>
* util/grub-mkconfig.in (GRUB_GFXMODE_LINUX): Export variable.
* util/grub.d/10_linux.in (linux_entry): If $GRUB_GFXMODE_LINUX
was set by the user, set mode as per specified before boot.
Index: util/grub.d/10_linux.in
===================================================================
--- util/grub.d/10_linux.in (revision 2048)
+++ util/grub.d/10_linux.in (working copy)
@@ -107,6 +107,11 @@ EOF
initrd ${rel_dirname}/${initrd}
EOF
fi
+ if [ "$GRUB_GFXMODE_LINUX" ] ; then cat << EOF
+ set gfxmode=$GRUB_GFXMODE_LINUX
+ terminal_output gfxterm
+EOF
+ fi
cat << EOF
}
EOF
Index: util/grub-mkconfig.in
===================================================================
--- util/grub-mkconfig.in (revision 2047)
+++ util/grub-mkconfig.in (working copy)
@@ -173,7 +173,8 @@ esac
export GRUB_DEVICE GRUB_DEVICE_UUID GRUB_DEVICE_BOOT GRUB_DEVICE_BOOT_UUID GRUB_FS GRUB_FONT_PATH GRUB_PRELOAD_MODULES
# These are optional, user-defined variables.
-export GRUB_DEFAULT GRUB_TIMEOUT GRUB_DISTRIBUTOR GRUB_CMDLINE_LINUX GRUB_CMDLINE_LINUX_DEFAULT GRUB_TERMINAL_OUTPUT GRUB_SERIAL_COMMAND GRUB_DISABLE_LINUX_UUID GRUB_GFXMODE
+export GRUB_DEFAULT GRUB_TIMEOUT GRUB_DISTRIBUTOR GRUB_CMDLINE_LINUX GRUB_CMDLINE_LINUX_DEFAULT GRUB_TERMINAL_OUTPUT \
+ GRUB_SERIAL_COMMAND GRUB_DISABLE_LINUX_UUID GRUB_GFXMODE GRUB_GFXMODE_LINUX
if test "x${grub_cfg}" != "x"; then
rm -f ${grub_cfg}.new
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] GRUB_GFXMODE_LINUX user variable
2009-03-29 2:31 [PATCH] GRUB_GFXMODE_LINUX user variable Robert Millan
@ 2009-03-29 8:39 ` Yoshinori K. Okuji
2009-04-01 13:05 ` Robert Millan
0 siblings, 1 reply; 4+ messages in thread
From: Yoshinori K. Okuji @ 2009-03-29 8:39 UTC (permalink / raw)
To: The development of GRUB 2
On Sunday 29 March 2009 11:31:29 Robert Millan wrote:
> This patch adds GRUB_GFXMODE_LINUX user variable to make it easy for
> users to set graphical mode before booting Linux.
Is this really Linux-specific? It look somehow coincidental to me that this is
used only for Linux. If other operating systems, such as FreeBSD, support
that way of switching a video mode, I think you would want to reuse the same
variable.
Thanks,
Okuji
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] GRUB_GFXMODE_LINUX user variable
2009-03-29 8:39 ` Yoshinori K. Okuji
@ 2009-04-01 13:05 ` Robert Millan
2009-04-01 14:01 ` Yoshinori K. Okuji
0 siblings, 1 reply; 4+ messages in thread
From: Robert Millan @ 2009-04-01 13:05 UTC (permalink / raw)
To: The development of GRUB 2
On Sun, Mar 29, 2009 at 05:39:36PM +0900, Yoshinori K. Okuji wrote:
> On Sunday 29 March 2009 11:31:29 Robert Millan wrote:
> > This patch adds GRUB_GFXMODE_LINUX user variable to make it easy for
> > users to set graphical mode before booting Linux.
>
> Is this really Linux-specific? It look somehow coincidental to me that this is
> used only for Linux. If other operating systems, such as FreeBSD, support
> that way of switching a video mode, I think you would want to reuse the same
> variable.
Agreed. Also, perhaps we should define an env variable like gfxmode, so that
loaders can switch mode themselves and "terminal_output gfxterm" doesn't have
to be used.
I like the terms "payload" and "loadee" because they don't imply what we're
loading is a kernel (Linux) or a standalone OS (invaders/memtest86). How
about using "gfxmode_payload=WIDTHxHEIGHT[xDEPTH]" ?
--
Robert Millan
The DRM opt-in fallacy: "Your data belongs to us. We will decide when (and
how) you may access your data; but nobody's threatening your freedom: we
still allow you to remove your data and not access it at all."
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] GRUB_GFXMODE_LINUX user variable
2009-04-01 13:05 ` Robert Millan
@ 2009-04-01 14:01 ` Yoshinori K. Okuji
0 siblings, 0 replies; 4+ messages in thread
From: Yoshinori K. Okuji @ 2009-04-01 14:01 UTC (permalink / raw)
To: The development of GRUB 2
On Wednesday 01 April 2009 22:05:57 Robert Millan wrote:
> On Sun, Mar 29, 2009 at 05:39:36PM +0900, Yoshinori K. Okuji wrote:
> > On Sunday 29 March 2009 11:31:29 Robert Millan wrote:
> > > This patch adds GRUB_GFXMODE_LINUX user variable to make it easy for
> > > users to set graphical mode before booting Linux.
> >
> > Is this really Linux-specific? It look somehow coincidental to me that
> > this is used only for Linux. If other operating systems, such as FreeBSD,
> > support that way of switching a video mode, I think you would want to
> > reuse the same variable.
>
> Agreed. Also, perhaps we should define an env variable like gfxmode, so
> that loaders can switch mode themselves and "terminal_output gfxterm"
> doesn't have to be used.
Not bad. ;)
> I like the terms "payload" and "loadee" because they don't imply what we're
> loading is a kernel (Linux) or a standalone OS (invaders/memtest86). How
> about using "gfxmode_payload=WIDTHxHEIGHT[xDEPTH]" ?
I am more used to Multiboot's terminology, so I prefer "OS Image".
Regards,
Okuji
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-04-01 14:01 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-03-29 2:31 [PATCH] GRUB_GFXMODE_LINUX user variable Robert Millan
2009-03-29 8:39 ` Yoshinori K. Okuji
2009-04-01 13:05 ` Robert Millan
2009-04-01 14:01 ` Yoshinori K. Okuji
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.