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

Re: Linux kernel 2.6.x Raw device support



Joerg Schilling wrote:

James Finnall <James@Finnall.net> wrote:

When configuring a Linux kernel 2.6.x series to enable the raw device support, it states this as being obsolete and deprecated. The suggestion is to use the O_DIRECT flag when opening the device name. I can see how this could be possible from inside an application where the system calls are directly available to the programmer.

O_DIRECT is a nonstandard extension only found on Linux.
UNIX supports raw device access via "character special" files.


But how can such an option be passed through from the CLI to a program though?

This is a problem. Why should a portable program introduce an option for something that is Linux specific and done completely different on other OS?


It was also stated that in the next kernel development of 2.7 that raw device support could be removed. Now I suppose that might be changed by popular demand as well.

I believe that the reason for not implementing raw devices on Linux was the fact
that Linux was designed for x86 and the way Linux did implement DMA to devices would have made a raw device slower than a buffered device.

But there WERE /dev/raw devices on Linux. You are correct that they don't work the way UNIX raw devices do, but the capability was there in 2.4, and I think in 2.2. Quite fast in 2.4!

As for "designed for x86" could we say "developed on x86?" SunOS was based on BSD, developed on a VAX (from memory), while Solaris is sort-of based on SysVR3, while I think was avtually developed on either a VAX or that funky CPU AT&T used in PBX. I used one, but have happily forgotten.

--
bill davidsen <davidsen@tmr.com>
 CTO TMR Associates, Inc
 Doing interesting things with small computers since 1979



Reply to: