Dean Roehrich a écrit:
Certainly, dm_handle_to_ip() is intended to return any type of handle,
including filesystem handles. In the case of XFS, when a filesystem handle is
requested we contruct it from the filesystem's root vnode.
I suppose dm_handle_to_ip() could be called with the handle from the mount
event. That handle would have a fid_len of 0, due to the memset() in
dm_sb_data()...the HSM would call to things like dm_get_config() and
dm_set_disp() with that handle.
Yes, in fh_to_inode(), we could recognize the fshandle, using the
fid_len value.
But, in inode_to_fh(), how know that we must return a fshandle (with the
dm_fid part filled with 0) or a filehandle (ino, len and gen filled) ?
What's the difference between
dm_path_to_fshandle("/")
and
dm_path_to_handle("/") ?
(Assuming / is a DMAPI compatible filesystem)
Aurelien
|