Re: Reading contents of a directory inside kernel

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

 



On Tue, Jul 7, 2015 at 10:27 AM, Viswanath, Logeswari P (MCOU OSTL)
<logeswari.pv@xxxxxx> wrote:
> Sorry, I missed mentioning the kernel version: 2.6.32.
>
> What are the callers of vfs_readdir expected to do?
>
> I cannot use the generic callback fillonedir/filldir since they are defined in readdir.c and not exported for others.
> Should the caller implement his/her own filler function?

Is this your own file system? If that's the case then yes you'll need to have
a filler function.

>
> Also, struct linux_dirent is defined in readdir.c. How can callers use this defintion?
> Should the caller define it in again his/her kernel module?
>
> Please let me know whether my understanding is correct.

Can you provide more context what exactly are you doing.

>
>> -----Original Message-----
>> From: Viswanath, Logeswari P (MCOU OSTL)
>> Sent: Monday, July 06, 2015 7:59 PM
>> To: 'linux-fsdevel@xxxxxxxxxxxxxxx'
>> Subject: Reading contents of a directory inside kernel
>>
>> Hi,
>>
>> I am new to linux file system. I want to read the contents of a directory from
>> my linux kernel module.
>> Can anyone please explain how to use vfs_readdir for this? Or is there any
>> other kernel API which should be used for this?
>>
>> Regards,
>> Logeswari.
> --
> To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html



-- 
        ---P.K.S
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux