Re: fcntl(2) and other file systems like XFS

From: almesber@lrc.di.epfl.ch
Date: Fri Mar 24 2000 - 08:07:25 EST

  • Next message: Lech Szychowski: "Re: 2.3.99-pre3 problems.."

    Jamie Lokier wrote:
    > I expect ioctls are not properly restricted for an O_NONE file, but I
    > didn't try. It wouldn't be hard to simply avoid opening the underlying
    > device -- thus allowing the fs-specific through to the fs.

    Some uses of O_NONE (or "O_NOACCESS", as it's called sometimes) are in
    avoiding access to a device (read-ahead, media detection, etc.) for
    which we want to send ioctls:

     - setfdprm: the driver may not know how to read the disk before the
       ioctls are done
     - fdformat: for obvious reasons
     - LILO: fetch geometry data, even if the media is not around

    Particularly fdformat is a good test if O_NONE still works :-)

    BTW, O_NONE is about as old as Linux. Maybe we should eventually add it
    to asm/fcntl.h, to avoid the regular threads on its feasibility ;-)

    - Werner

    -- 
      _________________________________________________________________________
     / Werner Almesberger, ICA, EPFL, CH       werner.almesberger@ica.epfl.ch /
    /_IN_N_032__Tel_+41_21_693_6621__Fax_+41_21_693_6610_____________________/
    

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



    This archive was generated by hypermail 2b29 : Fri Mar 24 2000 - 08:12:46 EST