2001-12-11 21:46:58

by Hal Duston

[permalink] [raw]
Subject: bio and "old" block drivers

I'm looking at the bio changes for ps2esdi. The driver
appears to no longer work compiled when into the kernel.
The ps2esdi_init call has been removed from
ll_rw_blk.c:blk_dev_init. Where is the new/correct place
to call this from? This appears to be the same way with
many of the other "old" block drivers as well.

Thanks, and not on the list,
Hal Duston
[email protected]


2001-12-12 10:20:45

by Jens Axboe

[permalink] [raw]
Subject: Re: bio and "old" block drivers

On Tue, Dec 11 2001, Hal Duston wrote:
> I'm looking at the bio changes for ps2esdi. The driver
> appears to no longer work compiled when into the kernel.
> The ps2esdi_init call has been removed from
> ll_rw_blk.c:blk_dev_init. Where is the new/correct place
> to call this from? This appears to be the same way with
> many of the other "old" block drivers as well.

Just use module_init to make this happen automagically.

--
Jens Axboe

2001-12-12 15:22:42

by Hal Duston

[permalink] [raw]
Subject: Re: bio and "old" block drivers

Jens Axboe wrote:
>
> On Tue, Dec 11 2001, Hal Duston wrote:
> > I'm looking at the bio changes for ps2esdi. The driver
> > appears to no longer work compiled when into the kernel.
> > The ps2esdi_init call has been removed from
> > ll_rw_blk.c:blk_dev_init. Where is the new/correct place
> > to call this from? This appears to be the same way with
> > many of the other "old" block drivers as well.
>
> Just use module_init to make this happen automagically.

Sorry, I am not understanding you here. Could you spell it
out please? My root filesystem is on the ps2esdi disk, do
I need to set up an initrd, and load the ps2esdi driver as
a module? Or do you mean that I should change things to
have module_init call it even when it isn't built as a
module? Or something else?

Thanks,
Hal Duston
[email protected]

2001-12-12 15:30:03

by Jens Axboe

[permalink] [raw]
Subject: Re: bio and "old" block drivers

On Wed, Dec 12 2001, A Duston wrote:
> Jens Axboe wrote:
> >
> > On Tue, Dec 11 2001, Hal Duston wrote:
> > > I'm looking at the bio changes for ps2esdi. The driver
> > > appears to no longer work compiled when into the kernel.
> > > The ps2esdi_init call has been removed from
> > > ll_rw_blk.c:blk_dev_init. Where is the new/correct place
> > > to call this from? This appears to be the same way with
> > > many of the other "old" block drivers as well.
> >
> > Just use module_init to make this happen automagically.
>
> Sorry, I am not understanding you here. Could you spell it
> out please? My root filesystem is on the ps2esdi disk, do
> I need to set up an initrd, and load the ps2esdi driver as
> a module? Or do you mean that I should change things to
> have module_init call it even when it isn't built as a
> module? Or something else?

I mean:

--- /opt/kernel/linux-2.5.1-pre10/drivers/block/ps2esdi.c Tue Dec 11 13:30:36 2001
+++ drivers/block/ps2esdi.c Wed Dec 12 10:26:09 2001
@@ -189,6 +189,8 @@
return 0;
} /* ps2esdi_init */

+module_init(ps2esdi_init);
+
#ifdef MODULE

static int cyl[MAX_HD] = {-1,-1};

and then it will be initialized correctly. module_init isn't specific to
modules, it will work for builtin stuff too. See __initcall

--
Jens Axboe