[ENBD] 2.6.0 support

Peter T. Breuer ptb at it.uc3m.es
Thu Jan 15 18:12:41 MST 2004


"Also sprach Peter T. Breuer:"
> Retitle this thread "what happened to kdev_t"!

Hmm .. well, it compiles after a bit of fiddling. kdev_t seems to have
reverted to dev_t, but with 32 bits this time instead of 16.

Essentially

    1) change all kdev_t's to dev_t
    2) chance minor(...) to MINOR(...), major(...) to MAJOR(...)
    3) if there was a kdev_mkdev, or whatever it was called, change
       it to a MAKEDEV
    4) replace  disk->queue = kmalloc(...) with
         disk->queue = blk_init_queue(do_nbd_request, &enbd_lock);
      and remove the memset(disk->queue,0, ...) a bit further down
      and remove the call to blk_init_queue in enbd_init_queue.
    5) fix my wrong use of _IOW in the enbd_base.c code by replacing
       sizeof(int) with just int as an argument.

I think that was enough to get the existing patch to compile under 2.6.1.
But that was purely syntactic - I didn't look what what I did meant.
Braver people than I may wish to try it. I'll publish a full patch
shortly.

Incidentally, I noticed a fair proportion of other 2.6.1 drivers also
not compiling.


Peter


More information about the ENBD mailing list