Re: Using GRUB2 for booting from CD

2007-11-10 Thread Marco Gerards
Alex Roman [EMAIL PROTECTED] writes:

Hi Alex,

 On 20/08/07, Robert Millan [EMAIL PROTECTED] wrote:
 I heard from Patrick Georgi on IRC (CCed) that he already has an ATAPI
 implementation for GRUB as part of his LinuxBIOS work.  Maybe you should
 coordinate with him so that the code can be shared with pc/bios targets.

 Awesome, perhaps we'll be able to get it going after Summer of Code is
 finished and all is integrated in the CVS, or if Patrick can post a
 patch that'd work too.

Did you send in a patch+Changelog entry with your work?

I would be happy to review it so we can integrate your work soon.

--
Marco



___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel


Re: Using GRUB2 for booting from CD

2007-08-20 Thread Robert Millan
On Mon, Aug 13, 2007 at 02:44:09PM -0400, Alex Roman wrote:
 On 13/08/07, Marco Gerards [EMAIL PROTECTED] wrote:
  Alex Roman [EMAIL PROTECTED] writes:
 
  Does this mean you implemented IDE support, etc? :-)
 
 Not yet :( but that's coming :)

I heard from Patrick Georgi on IRC (CCed) that he already has an ATAPI
implementation for GRUB as part of his LinuxBIOS work.  Maybe you should
coordinate with him so that the code can be shared with pc/bios targets.

-- 
Robert Millan

GPLv2 I know my rights; I want my phone call!
DRM What use is a phone call, if you are unable to speak?
(as seen on /.)


___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel


Re: Using GRUB2 for booting from CD

2007-08-20 Thread Alex Roman
On 20/08/07, Robert Millan [EMAIL PROTECTED] wrote:
 I heard from Patrick Georgi on IRC (CCed) that he already has an ATAPI
 implementation for GRUB as part of his LinuxBIOS work.  Maybe you should
 coordinate with him so that the code can be shared with pc/bios targets.

Awesome, perhaps we'll be able to get it going after Summer of Code is
finished and all is integrated in the CVS, or if Patrick can post a
patch that'd work too.

Thanks!


-- 
Alex Roman [EMAIL PROTECTED]


___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel


Re: Using GRUB2 for booting from CD

2007-08-15 Thread Jeroen Dekkers
At Mon, 13 Aug 2007 20:40:27 -0400,
Alex Roman wrote:
 
 OK, I've done the following in grub-emu...
 
 I have a map file that looks like this:
 (fd0) floppy.img
 (cd0) grub2-iso.iso
 
 grub2-iso.iso is an iso I generate using genisoimage (mkisofs). I can
 mount it just fine.
 
 floppy.img is a floppy image I generate... It contains grub, basically
 and a few modules.
 
 I run grub-emu -d grub2 -m mapfile -r fd0
 
 grub2 is my build directory.
 
 I tried ls (cd0)/ but that did not work. The iso9660_mount function is
 saying that it couldn't read the superblock.
 
 Then I saw on your (Marco) blog about the loopback command. So I tried
 it as follows:
 
 loopback cd1 (host)/path/to/grub2-iso.iso
 
 Now, ls (cd1)/ goes a bit further, it can read the superblock, but it
 says it couldn't find the magic CD001. I printed the data it reads
 from the ISO and it's all 0's...
 
 
 Am I doing anything wrong from what you can see here? I'd like to know
 if it's something I'm doing wrong in my procedure or in my code...

Read what's in the file directly and compare it to what grub-emu
reads. If it reads something different than that's a bug in the
grub-emu or loopback code. 

Also don't forget about the possiblity that qemu might be buggy,
especially if you're using bios functions that aren't really used that
much. Testing on real hardware is really necessary sometimes.

And whether your code is wrong or not is very difficult to tell if you
don't post your code...

Jeroen Dekkers


___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel


Re: Using GRUB2 for booting from CD

2007-08-13 Thread Marco Gerards
Alex Roman [EMAIL PROTECTED] writes:

Hi,

 I've managed to (finally :( ) use GRUB2 as a bootloader on a CD-ROM.
 It loads the kernel and all modules I tell grub-mkimage to include.

 The problem is that it doens't know how to mount the root to be able
 to load other modules, read configuration files, etc. There is an
 iso9660 already there, but how can I tell grub2 to actually mount the
 CD-ROM drive as an iso9660 filesystem?

Does this mean you implemented IDE support, etc? :-)

The filesystem should automatically be detected.  What you can do is
dumping the first sector of the CDROM to see if it is read correctly.

Have a look at grub_iso9660_mount.  It first tries to read the
superblock.  Next it does is checking if it is actually an ISO9660
filesystem (by checking for CD001).  This function should reach
return data if it is indeed a ISO9660 filesystem.

What you could do first is checking if grub-emu can read your
filesystem image.  That way you can easily see if the problem is in my
code or in your code.

--
Marco



___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel


Re: Using GRUB2 for booting from CD

2007-08-13 Thread Alex Roman
OK, I've done the following in grub-emu...

I have a map file that looks like this:
(fd0) floppy.img
(cd0) grub2-iso.iso

grub2-iso.iso is an iso I generate using genisoimage (mkisofs). I can
mount it just fine.

floppy.img is a floppy image I generate... It contains grub, basically
and a few modules.

I run grub-emu -d grub2 -m mapfile -r fd0

grub2 is my build directory.

I tried ls (cd0)/ but that did not work. The iso9660_mount function is
saying that it couldn't read the superblock.

Then I saw on your (Marco) blog about the loopback command. So I tried
it as follows:

loopback cd1 (host)/path/to/grub2-iso.iso

Now, ls (cd1)/ goes a bit further, it can read the superblock, but it
says it couldn't find the magic CD001. I printed the data it reads
from the ISO and it's all 0's...


Am I doing anything wrong from what you can see here? I'd like to know
if it's something I'm doing wrong in my procedure or in my code...



Thanks!

-- 
Alex Roman [EMAIL PROTECTED]


___
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel