[Prev][Next][Index][Thread]

Re: Bug in OSKit's linux block I/O glue [PATCH]



Notes on recent experience with OSKit 20000202

I can build oskit fine in Linux as long as all three of the libc options 
are enabled.
Using a parallel make it takes maybe 10-15 mins. The sample kernels all work
although the smp test kernel prints some gibberish after shutting down 
the cpu's.

My problems happen when I try and compile it natively under Hurd.

I built oskit-mach using Debian's oskit deb, it compiled well enough 
under Hurd,
except the resulting kernel reboots my system shortly after it says 
OSKit-Mach!
Not sure if oskit was compiled with smp and then oskit-mach tries to go 
smp and
loses it.

I could compile oskit in Hurd with just "./configure --prefix=/usr" to 
overwrite
the Debian package, which I did. Definately use a parallel make with

$alias 'make MAKE="make -j9"'

Hurd's SCSI I/O is really slow, so it is very advantageous to do this. 
The make crashes
a couple times, but will eventually build after a few tries. It 
recognises the gcc compiler
as "pc-unknown-gnu0.2" and thats all I did to configure it. I think it 
took maybe 1-1/2
hour on a PII-450 running in uniprocessor mode. Not very friendly for 
repeated builds.

The oskit-mach that I was able to compile behaved exactly like the one 
built against
the original Deb headers and libs. Just reboots shortly after starting.

I'm working on getting the serial debugging setup going, maybe that will 
help get
this thing working.

Thanks for all the great work on OSKit!

Wish List:
Better support for Ada95 kernels? That would be excellent!



Cheers!
- Doug




Igor Khavkine wrote:

>This attached patch fixes the problem which was notcied when trying
>to use oskit's floppy driver from the oskit-mach kernel.
>
>The patch is against oskit-20000202, but i used the -p flag for diff
>so you would know where to apply it if it was rejected from the current
>source tree.
>
>Thanks.
>
>Igor
>
>
>------------------------------------------------------------------------
>
>--- linux/dev/block.c.orig	Sun Aug 12 16:49:03 2001
>+++ linux/dev/block.c	Sun Aug 12 16:45:45 2001
>@@ -563,7 +563,7 @@ blkio_read(oskit_blkio_t *io, void *buf,
> 	file.f_dentry = &dentry;
> 	dentry.d_inode = &po->inode;
> 
>-	err = (*po->fops->read)(&file, buf, count, 0);
>+	err = (*po->fops->read)(&file, buf, count, &file.f_pos);
> 	if (err) {
> 		err = linux_to_oskit_error(err);
> 		*amount_read = 0;	/* XXX */
>@@ -622,7 +622,7 @@ blkio_write(oskit_blkio_t *io, const voi
> 	file.f_inode = &po->inode;
> 	file.f_dentry = &dentry;
> 	dentry.d_inode = &po->inode;
>-	err = (po->fops->write)(&file, buf, count, 0);
>+	err = (po->fops->write)(&file, buf, count, &file.f_pos);
> 	if (err) {
> 		osenv_log(OSENV_LOG_NOTICE, "WRITE error %d, 0x%x\n", err, err);
> 		err = linux_to_oskit_error(err);
>
>
>
>




References: