Cursor in readdir

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

 



Hi Miklos,

Sorry for disturb you. I'm confused with *cursor* in struct
ovl_dir_file. I know this struct ovl_cache_entry *cursor* is
presented to indicate current pos when performing readdir at
a MERGE type directory.

Why this additional entry is needed? Can't we use a pointer
to record which entry is read or is ready for reading? After
finish reading lower and upper directories, entries in struct
ovl_dir_cache is stabilized. Changing of directories will
cause the later .readdir() to create a new ovl_dir_cache but
the old cache will not be released until all the holders of
it call .release().

So I think a pointer points to an entry in the entry list of
ovl_dir_cache is enough to each process sharing the access
of the same cache. We don't need to keep and move an special
entry, *cursor*. That's my thought.

I've considered a lot and googled some key words but found
nothing. Did I miss something important?

It will be fine if you'd like to explain the requirement of
*cursor* in readdir. Thanks a lot~!


Hu


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




[Index of Archives]     [Linux Filesystems Devel]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux