* grub_halt()
@ 2009-11-25 20:37 Felix Zielcke
2009-11-27 21:24 ` grub_halt() Vladimir 'φ-coder/phcoder' Serbinenko
0 siblings, 1 reply; 5+ messages in thread
From: Felix Zielcke @ 2009-11-25 20:37 UTC (permalink / raw)
To: The development of GRUB 2
grub_halt is on i386-pc defined as `void grub_halt (int no_apm)' but
everywhere else as `grub_halt (void)'
util/grub-emu.c has a #ifdef for these 2
Shouldn't we just add an int parameter everywhere to make this more
simple?
grub-emu fails to build on powerpc now because grub/cpu/halt.h doestn't
exist there:
https://buildd.debian.org/fetch.cgi?pkg=grub2;ver=1.97%2B20091125-1;arch=powerpc;stamp=1259179180
--
Felix Zielcke
Proud Debian Maintainer and GNU GRUB developer
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: grub_halt()
2009-11-25 20:37 grub_halt() Felix Zielcke
@ 2009-11-27 21:24 ` Vladimir 'φ-coder/phcoder' Serbinenko
2009-11-27 21:28 ` grub_halt() Felix Zielcke
2009-11-28 19:01 ` grub_halt() Robert Millan
0 siblings, 2 replies; 5+ messages in thread
From: Vladimir 'φ-coder/phcoder' Serbinenko @ 2009-11-27 21:24 UTC (permalink / raw)
To: The development of GNU GRUB
[-- Attachment #1: Type: text/plain, Size: 800 bytes --]
Felix Zielcke wrote:
> grub_halt is on i386-pc defined as `void grub_halt (int no_apm)' but
> everywhere else as `grub_halt (void)'
> util/grub-emu.c has a #ifdef for these 2
>
> Shouldn't we just add an int parameter everywhere to make this more
> simple?
>
>
I think in future we'll have more different halt methods on different
platforms. So we could do:
grub_halt (int methods)
And have e.g.
GRUB_HALT_DEFAULT_METHODS
And e.g. on i386:
#define GRUB_HALT_DEFAULT_METHODS
(GRUB_HALT_APM|GRUB_HALT_ACPI|GRUB_HALT_HANG)
> grub-emu fails to build on powerpc now because grub/cpu/halt.h doestn't
> exist there:
> https://buildd.debian.org/fetch.cgi?pkg=grub2;ver=1.97%2B20091125-1;arch=powerpc;stamp=1259179180
>
--
Regards
Vladimir 'φ-coder/phcoder' Serbinenko
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 293 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: grub_halt()
2009-11-27 21:24 ` grub_halt() Vladimir 'φ-coder/phcoder' Serbinenko
@ 2009-11-27 21:28 ` Felix Zielcke
2009-11-28 19:01 ` grub_halt() Robert Millan
1 sibling, 0 replies; 5+ messages in thread
From: Felix Zielcke @ 2009-11-27 21:28 UTC (permalink / raw)
To: The development of GNU GRUB
[-- Attachment #1: Type: text/plain, Size: 1145 bytes --]
Am Freitag, den 27.11.2009, 22:24 +0100 schrieb Vladimir
'φ-coder/phcoder' Serbinenko:
> Felix Zielcke wrote:
> > grub_halt is on i386-pc defined as `void grub_halt (int no_apm)' but
> > everywhere else as `grub_halt (void)'
> > util/grub-emu.c has a #ifdef for these 2
> >
> > Shouldn't we just add an int parameter everywhere to make this more
> > simple?
> >
> >
> I think in future we'll have more different halt methods on different
> platforms. So we could do:
> grub_halt (int methods)
> And have e.g.
> GRUB_HALT_DEFAULT_METHODS
> And e.g. on i386:
> #define GRUB_HALT_DEFAULT_METHODS
> (GRUB_HALT_APM|GRUB_HALT_ACPI|GRUB_HALT_HANG)
Wouldn't be an enum then be better?
But I don't know how to handle this with asm where currently grub_halt()
on i386 seems to be actually defined.
> > grub-emu fails to build on powerpc now because grub/cpu/halt.h
> doestn't
> > exist there:
> >
> https://buildd.debian.org/fetch.cgi?pkg=grub2;ver=1.97%2B20091125-1;ar
> ch=powerpc;stamp=1259179180
> >
It fails also on sparc because of this.
--
Felix Zielcke
Proud Debian Maintainer and GNU GRUB developer
[-- Attachment #2: Dies ist ein digital signierter Nachrichtenteil --]
[-- Type: application/pgp-signature, Size: 490 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: grub_halt()
2009-11-27 21:24 ` grub_halt() Vladimir 'φ-coder/phcoder' Serbinenko
2009-11-27 21:28 ` grub_halt() Felix Zielcke
@ 2009-11-28 19:01 ` Robert Millan
2009-12-04 21:02 ` grub_halt() Robert Millan
1 sibling, 1 reply; 5+ messages in thread
From: Robert Millan @ 2009-11-28 19:01 UTC (permalink / raw)
To: The development of GNU GRUB
On Fri, Nov 27, 2009 at 10:24:39PM +0100, Vladimir 'φ-coder/phcoder' Serbinenko wrote:
> Felix Zielcke wrote:
> > grub_halt is on i386-pc defined as `void grub_halt (int no_apm)' but
> > everywhere else as `grub_halt (void)'
> > util/grub-emu.c has a #ifdef for these 2
> >
> > Shouldn't we just add an int parameter everywhere to make this more
> > simple?
> >
> >
> I think in future we'll have more different halt methods on different
> platforms. So we could do:
> grub_halt (int methods)
> And have e.g.
> GRUB_HALT_DEFAULT_METHODS
> And e.g. on i386:
> #define GRUB_HALT_DEFAULT_METHODS
> (GRUB_HALT_APM|GRUB_HALT_ACPI|GRUB_HALT_HANG)
I was hoping we could remove complexity rather than add more of it.
Why would higher layer (who's just calling grub_halt because it wants the
system to shutdown) want to know about things like APM or ACPI ?
--
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] 5+ messages in thread
* Re: grub_halt()
2009-11-28 19:01 ` grub_halt() Robert Millan
@ 2009-12-04 21:02 ` Robert Millan
0 siblings, 0 replies; 5+ messages in thread
From: Robert Millan @ 2009-12-04 21:02 UTC (permalink / raw)
To: The development of GNU GRUB
On Sat, Nov 28, 2009 at 08:01:01PM +0100, Robert Millan wrote:
> On Fri, Nov 27, 2009 at 10:24:39PM +0100, Vladimir 'φ-coder/phcoder' Serbinenko wrote:
> > Felix Zielcke wrote:
> > > grub_halt is on i386-pc defined as `void grub_halt (int no_apm)' but
> > > everywhere else as `grub_halt (void)'
> > > util/grub-emu.c has a #ifdef for these 2
> > >
> > > Shouldn't we just add an int parameter everywhere to make this more
> > > simple?
> > >
> > >
> > I think in future we'll have more different halt methods on different
> > platforms. So we could do:
> > grub_halt (int methods)
> > And have e.g.
> > GRUB_HALT_DEFAULT_METHODS
> > And e.g. on i386:
> > #define GRUB_HALT_DEFAULT_METHODS
> > (GRUB_HALT_APM|GRUB_HALT_ACPI|GRUB_HALT_HANG)
>
> I was hoping we could remove complexity rather than add more of it.
>
> Why would higher layer (who's just calling grub_halt because it wants the
> system to shutdown) want to know about things like APM or ACPI ?
Well, for now I just unified the headers but kept the current i386-pc
function parameters. This restores experimental to a buildable state.
--
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] 5+ messages in thread
end of thread, other threads:[~2009-12-04 21:02 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-25 20:37 grub_halt() Felix Zielcke
2009-11-27 21:24 ` grub_halt() Vladimir 'φ-coder/phcoder' Serbinenko
2009-11-27 21:28 ` grub_halt() Felix Zielcke
2009-11-28 19:01 ` grub_halt() Robert Millan
2009-12-04 21:02 ` grub_halt() Robert Millan
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.