All of lore.kernel.org
 help / color / mirror / Atom feed
* Reiser4 + seekdir()
@ 2005-06-27  9:28 Artem B. Bityuckiy
  2005-06-27 11:41 ` Vladimir Saveliev
  0 siblings, 1 reply; 15+ messages in thread
From: Artem B. Bityuckiy @ 2005-06-27  9:28 UTC (permalink / raw)
  To: reiserfs-list

Hello,

I was investigating Riser4 readdir() handling. As the result I've 
realized the following:

1. repeatable readdir() calls should work well.
2. seekdir()/telldir() mustn't work. (because per_file readdir_pos 
stores only the _last_ f_pos->{key, entry_no, position} mapping, so the 
mapping will be lost on the next readdir(), and the previous seekdir() 
will be lost too).

But probably I don't quite well understand what's going on. Here is the 
list of things which makes me doubt.

1. There are two types of directory plugins: HASHED_DIR_PLUGIN_ID and 
SEEKABLE_HASHED_DIR_PLUGIN_ID. The latter is claimed as "hashed 
directory for which seekdir/telldir are guaranteed to work". I don't 
understand how can it work. Could somebody please point me the code 
which implements seekdir() (seekdir is actually 
lseek(fd,saved_position,SEEK_SET) in glibc) ? For me it looks like both 
must not support telldir()/seekdir() ...

2. Why you store {entry_no, position, key} in readdir_pos instead of 
just storing the full name string ? In that case you would not need 
adjust_dir_pos() at all ...

Please, comment on this. Thanks.

-- 
Best Regards,
Artem B. Bityuckiy,
St.-Petersburg, Russia.

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2005-06-30 16:26 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-06-27  9:28 Reiser4 + seekdir() Artem B. Bityuckiy
2005-06-27 11:41 ` Vladimir Saveliev
2005-06-27 12:09   ` Artem B. Bityuckiy
2005-06-27 12:39     ` Vladimir Saveliev
2005-06-27 12:57       ` Artem B. Bityuckiy
2005-06-27 13:49         ` Vladimir Saveliev
2005-06-27 13:53           ` Artem B. Bityuckiy
2005-06-27 19:50             ` Hans Reiser
2005-06-29  6:51               ` Artem B. Bityuckiy
2005-06-29 10:22                 ` Vladimir Saveliev
2005-06-29 10:29                   ` Artem B. Bityuckiy
2005-06-29 11:48                     ` Vladimir Saveliev
2005-06-29 18:11                   ` Valdis.Kletnieks
2005-06-30 16:26                     ` Vladimir Saveliev
2005-06-27 18:09     ` Hans Reiser

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.