svn | 2 Sep 2009 01:44

r576 - trunk/openbios-devel/arch/ppc/qemu

Author: laurent
Date: 2009-09-02 01:44:24 +0200 (Wed, 02 Sep 2009)
New Revision: 576

Modified:
   trunk/openbios-devel/arch/ppc/qemu/main.c
Log:
Use the load method to load and execute CHRP script.

This adds a better support of Apple BootX script.
However, "init-program" and "go" are always missing to be able to really boot with BootX.

Signed-off-by: Laurent Vivier <Laurent@...>

Modified: trunk/openbios-devel/arch/ppc/qemu/main.c
===================================================================
--- trunk/openbios-devel/arch/ppc/qemu/main.c	2009-08-30 23:39:55 UTC (rev 575)
+++ trunk/openbios-devel/arch/ppc/qemu/main.c	2009-09-01 23:44:24 UTC (rev 576)
 <at>  <at>  -39,6 +39,14  <at>  <at> 
 #define NEWWORLD_DPRINTF(fmt, args...) SUBSYS_DPRINTF("NEWWORLD", fmt, ##args)

 static void
+load(const char *path)
+{
+	char buffer[1024];
+	sprintf(buffer, "load %s", path);
+	feval(buffer);
+}
+
+static void
(Continue reading)

Laurent Vivier | 2 Sep 2009 23:15
Picon

Re: r565 - trunk/openbios-devel/modules

Le samedi 22 août 2009 à 08:03 +0200, svn <at> openbios.org a écrit :
> Author: blueswirl
> Date: 2009-08-22 08:03:40 +0200 (Sat, 22 Aug 2009)
> New Revision: 565
> 
> Modified:
>    trunk/openbios-devel/modules/disk-label.c
> Log:
> Allow NULL dlabel path argument without accessing page zero.
> 
> Signed-off-by: Blue Swirl <blauwirbel <at> gmail.com>
> 
> Modified: trunk/openbios-devel/modules/disk-label.c
> ===================================================================
> --- trunk/openbios-devel/modules/disk-label.c	2009-08-22 06:03:20 UTC (rev 564)
> +++ trunk/openbios-devel/modules/disk-label.c	2009-08-22 06:03:40 UTC (rev 565)
>  <at>  <at>  -57,7 +57,7  <at>  <at> 
>  static void
>  dlabel_open( dlabel_info_t *di )
>  {
> -	char *s, *filename;
> +	const char *s, *filename;
>  	char *path;
>  	char block0[512];
>  	phandle_t ph;
>  <at>  <at>  -65,6 +65,9  <at>  <at> 
>  	xt_t xt;
>  
>  	path = my_args_copy();
> +	if (!path) {
(Continue reading)

Igor Kovalenko | 2 Sep 2009 23:32
Picon

Re: r565 - trunk/openbios-devel/modules

On Thu, Sep 3, 2009 at 1:15 AM, Laurent Vivier<Laurent@...> wrote:
> Le samedi 22 août 2009 à 08:03 +0200, svn@... a écrit :
>> Author: blueswirl
>> Date: 2009-08-22 08:03:40 +0200 (Sat, 22 Aug 2009)
>> New Revision: 565
>>
>> Modified:
>>    trunk/openbios-devel/modules/disk-label.c
>> Log:
>> Allow NULL dlabel path argument without accessing page zero.
>>
>> Signed-off-by: Blue Swirl <blauwirbel@...>
>>
>> Modified: trunk/openbios-devel/modules/disk-label.c
>> ===================================================================
>> --- trunk/openbios-devel/modules/disk-label.c 2009-08-22 06:03:20 UTC (rev 564)
>> +++ trunk/openbios-devel/modules/disk-label.c 2009-08-22 06:03:40 UTC (rev 565)
>>  <at>  <at>  -57,7 +57,7  <at>  <at> 
>>  static void
>>  dlabel_open( dlabel_info_t *di )
>>  {
>> -     char *s, *filename;
>> +     const char *s, *filename;
>>       char *path;
>>       char block0[512];
>>       phandle_t ph;
>>  <at>  <at>  -65,6 +65,9  <at>  <at> 
>>       xt_t xt;
>>
>>       path = my_args_copy();
(Continue reading)

Laurent Vivier | 2 Sep 2009 23:54
Picon

Re: r565 - trunk/openbios-devel/modules

Le jeudi 03 septembre 2009 à 01:32 +0400, Igor Kovalenko a écrit :
> On Thu, Sep 3, 2009 at 1:15 AM, Laurent Vivier<Laurent <at> vivier.eu> wrote:
> > Le samedi 22 août 2009 à 08:03 +0200, svn <at> openbios.org a écrit :
> >> Author: blueswirl
> >> Date: 2009-08-22 08:03:40 +0200 (Sat, 22 Aug 2009)
> >> New Revision: 565
> >>
> >> Modified:
> >>    trunk/openbios-devel/modules/disk-label.c
> >> Log:
> >> Allow NULL dlabel path argument without accessing page zero.
> >>
[...]
> >
> > This patch breaks booting PPC using QUIK bootloader. Ìs it possible to
> > revert it ?
> >
> 
> Can you please check what is the real issue here?

Yes, but my first idea was to make it done by someone else... ;-)

> Maybe dlabel_open is getting called somewhere in bootloader
> without proper path argument?

In fact, patch r565 modifies the behavior of dlabel_open() because
filename is not NULL anymore if path is empty.

This new patch corrects the problem:

(Continue reading)

Igor Kovalenko | 3 Sep 2009 00:08
Picon

Re: r565 - trunk/openbios-devel/modules

On Thu, Sep 3, 2009 at 1:54 AM, Laurent Vivier<Laurent@...> wrote:
> Le jeudi 03 septembre 2009 à 01:32 +0400, Igor Kovalenko a écrit :
>> On Thu, Sep 3, 2009 at 1:15 AM, Laurent Vivier<Laurent@...> wrote:
>> > Le samedi 22 août 2009 à 08:03 +0200, svn@... a écrit :
>> >> Author: blueswirl
>> >> Date: 2009-08-22 08:03:40 +0200 (Sat, 22 Aug 2009)
>> >> New Revision: 565
>> >>
>> >> Modified:
>> >>    trunk/openbios-devel/modules/disk-label.c
>> >> Log:
>> >> Allow NULL dlabel path argument without accessing page zero.
>> >>
> [...]
>> >
>> > This patch breaks booting PPC using QUIK bootloader. Ìs it possible to
>> > revert it ?
>> >
>>
>> Can you please check what is the real issue here?
>
> Yes, but my first idea was to make it done by someone else... ;-)
>
>> Maybe dlabel_open is getting called somewhere in bootloader
>> without proper path argument?
>
> In fact, patch r565 modifies the behavior of dlabel_open() because
> filename is not NULL anymore if path is empty.
>
> This new patch corrects the problem:
(Continue reading)

Laurent Vivier | 3 Sep 2009 00:21
Picon

Re: r565 - trunk/openbios-devel/modules

Le jeudi 03 septembre 2009 à 02:08 +0400, Igor Kovalenko a écrit :
> On Thu, Sep 3, 2009 at 1:54 AM, Laurent Vivier<Laurent <at> vivier.eu> wrote:
> > Le jeudi 03 septembre 2009 à 01:32 +0400, Igor Kovalenko a écrit :
> >> On Thu, Sep 3, 2009 at 1:15 AM, Laurent Vivier<Laurent <at> vivier.eu> wrote:
> >> > Le samedi 22 août 2009 à 08:03 +0200, svn <at> openbios.org a écrit :
> >> >> Author: blueswirl
> >> >> Date: 2009-08-22 08:03:40 +0200 (Sat, 22 Aug 2009)
> >> >> New Revision: 565
> >> >>
> >> >> Modified:
> >> >>    trunk/openbios-devel/modules/disk-label.c
> >> >> Log:
> >> >> Allow NULL dlabel path argument without accessing page zero.
> >> >>
> > [...]
> >> >
> >> > This patch breaks booting PPC using QUIK bootloader. Ìs it possible to
> >> > revert it ?
> >> >
> >>
> >> Can you please check what is the real issue here?
> >
> > Yes, but my first idea was to make it done by someone else... ;-)
> >
> >> Maybe dlabel_open is getting called somewhere in bootloader
> >> without proper path argument?
> >
> > In fact, patch r565 modifies the behavior of dlabel_open() because
> > filename is not NULL anymore if path is empty.
> >
(Continue reading)

svn | 3 Sep 2009 00:25

r577 - trunk/openbios-devel/modules

Author: laurent
Date: 2009-09-03 00:25:44 +0200 (Thu, 03 Sep 2009)
New Revision: 577

Modified:
   trunk/openbios-devel/modules/disk-label.c
Log:
Allow "boot hd:,%BOOT" to work again (and thus Quik).

Signed-off-by: Laurent Vivier <Laurent@...>

Modified: trunk/openbios-devel/modules/disk-label.c
===================================================================
--- trunk/openbios-devel/modules/disk-label.c	2009-09-01 23:44:24 UTC (rev 576)
+++ trunk/openbios-devel/modules/disk-label.c	2009-09-02 22:25:44 UTC (rev 577)
 <at>  <at>  -79,7 +79,7  <at>  <at> 
 	/* argument format: parnum,filename */

 	s = path;
-	filename = NULL;
+	filename = "";
 	if( *s == '-' || isdigit(*s) ||
 	    (*s >= 'a' && *s < ('a' + 8)
 	     && (*(s + 1) == ',' || *(s + 1) == '\0'))) {
 <at>  <at>  -146,7 +146,7  <at>  <at> 
 		push_str( filename );
 		PUSH_ph( ph );
 		fword("interpose");
-	} else if (filename && strcmp(filename, "%BOOT") != 0) {
+	} else if (*filename && strcmp(filename, "%BOOT") != 0) {
(Continue reading)

Stefan Reinauer | 6 Sep 2009 21:41
Picon

[Fwd: [coreboot] possible bug, reported on irc]


Picon
From: Maciej Pijanka <maciej.pijanka@...>
Subject: [coreboot] possible bug, reported on irc
Date: 2009-09-06 16:06:04 GMT
Hello,

< Guest836553> Hello I noticed that OpenBIOS' disk-label package
doesn't allow raw disk access unless it has an apple partition map. In
particular I noticed that only modules/mac-parts.c honours the specs
(ftp://playground.sun.com/pub/1275/bindings/postscript/CHRP.ps,
section 11.1.2), which state the partition number 0 indicates the
whole disk. In pc-parts.c (MSDOS partition table format) partiton 0 is
the first primary partiton (it should be partition 1, I suppose) and
in sun-parts.c (I didn't try it) I don't see any special-handling code
for partition 0, so I suppose it's affected by the bug too.

I asked reporting person to post mail to list, so at least after
moderation it could reach ML. But mail don't appear so i am posting
this now.

best regards
Maciej

(Continue reading)

Segher Boessenkool | 8 Sep 2009 19:47

Re: [Fwd: [coreboot] possible bug, reported on irc]

> < Guest836553> Hello I noticed that OpenBIOS' disk-label package
> doesn't allow raw disk access unless it has an apple partition map. In
> particular I noticed that only modules/mac-parts.c honours the specs
> (ftp://playground.sun.com/pub/1275/bindings/postscript/CHRP.ps,
> section 11.1.2), which state the partition number 0 indicates the
> whole disk. In pc-parts.c (MSDOS partition table format) partiton 0 is
> the first primary partiton (it should be partition 1, I suppose) and
> in sun-parts.c (I didn't try it) I don't see any special-handling code
> for partition 0, so I suppose it's affected by the bug too.

The CHRP spec only applies to CHRP's disk-label package, not to others.
In particular, some other systems treat the absence of any partition
number part (the part before the comma) as meaning the full disk, and
partition #0 is simply the first partition; CHRP uses this to indicate
the first "bootable" partition, which has no meaning for many partition
schemes, and is guesswork for most others.

If your client program does not require CHRP, but does require :0 to
mean the whole disk, it is buggy.

Segher

svn | 19 Sep 2009 00:59

r578 - in trunk/openbios-devel: arch/ppc/qemu forth/debugging modules

Author: laurent
Date: 2009-09-19 00:59:30 +0200 (Sat, 19 Sep 2009)
New Revision: 578

Modified:
   trunk/openbios-devel/arch/ppc/qemu/init.c
   trunk/openbios-devel/forth/debugging/client.fs
   trunk/openbios-devel/modules/build.xml
   trunk/openbios-devel/modules/init.c
   trunk/openbios-devel/modules/modules.h
Log:
Allows to boot openSUSE from install CD-ROM

Implements "init-program" using loader packages
Write a first loader package: elf-loader

Signed-off-by: Laurent Vivier <Laurent@...>

Modified: trunk/openbios-devel/arch/ppc/qemu/init.c
===================================================================
--- trunk/openbios-devel/arch/ppc/qemu/init.c	2009-09-02 22:25:44 UTC (rev 577)
+++ trunk/openbios-devel/arch/ppc/qemu/init.c	2009-09-18 22:59:30 UTC (rev 578)
 <at>  <at>  -439,6 +439,18  <at>  <at> 
     for (;;);
 }

+static void go( void );
+
+static void
+go( void )
(Continue reading)


Gmane