lkml.org 
[lkml]   [2001]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: block ioctl to read/write last sector
Date
> I have one additional user space only idea:
> have you tried raw-io? bind a raw device to the partition, IIRC raw-io
> is always in 512 byte units.

Steven Tweedie responded to my question about that:

> Raw IO is subject to the same limits as other IO, because
> ultimately it uses the same route through the kernel
> to get to the low-level disk IO drivers.

This was confirmed by my testing. Reading/writing via /dev/raw/rawX fails
exactly the same way as for /dev/[sh]dX.

> Accessing /dev/sg ought to work fine, but of course it
> places much more load on the application programmer
> and removes a ton of kernel safety-nets.

I believe using ide-scsi would work, but you must pass "hdc=ide-scsi" at
boot time, which isn't a big deal for accessing CD-ROMs, but to be used for
arbitrary disks, makes life much more difficult. Now all your IDE disks
need to think they're SCSI disks, at least for the boot in which you want to
change the partition table. I wouldn't want to suggest to customers that
they run this additional layer of abstraction all the time just in case they
want to examine and/or change the partition table of just one disk at some
time.

Thanks,
Matt

--
Matt Domsch
Dell Linux Systems Group
Linux OS Development
www.dell.com/linux


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:14    [W:0.032 / U:3.216 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site