Opening a file in Kernel Space. - HP UX

This is a discussion on Opening a file in Kernel Space. - HP UX ; Hi, I would like to know is there any interface for opening a file in a kernel module. Linux has something like filp_open(). -Yogi....

+ Reply to Thread
Results 1 to 4 of 4

Thread: Opening a file in Kernel Space.

  1. Opening a file in Kernel Space.

    Hi,

    I would like to know is there any interface for opening a file in a
    kernel module. Linux has something like filp_open().

    -Yogi.


  2. Re: Opening a file in Kernel Space.

    I remember opening a file using the vnode ops vn_open routine. You
    could subsequently read/write a file using vn_rdwr with the uio
    structure.

    I don't think there are any high level interfaces available , as in
    Linux/AIX.

    -Qasim


  3. Re: Opening a file in Kernel Space.

    > Hi,

    > I would like to know is there any interface for opening a file in a
    > kernel module. Linux has something like filp_open().


    If you wanted to examine an open file you could
    use the pstat/pstat_getfile() system call interface.

    > -Yogi.

    DaveN


  4. Re: Opening a file in Kernel Space.

    Hi,

    Thanks for the info. For opening a file using vnode ops, do I need
    access to hp-ux kernel sources?

    Can someone post an sample code for this?

    -Yogi.


+ Reply to Thread