| To: | Dean Roehrich <roehrich@xxxxxxx> |
|---|---|
| Subject: | Re: [DMAPI] code error in dm_ip_to_handle() |
| From: | Aurelien Degremont - Stagiaire <degremont@xxxxxxxxxxx> |
| Date: | Mon, 16 May 2005 17:04:48 +0200 |
| Cc: | linux-xfs@xxxxxxxxxxx |
| In-reply-to: | <20050516144914.4C3244FE8A@chewtoy.americas.sgi.com> |
| References: | <20050516144914.4C3244FE8A@chewtoy.americas.sgi.com> |
| Sender: | linux-xfs-bounce@xxxxxxxxxxx |
| User-agent: | Mozilla/5.0 (X11; U; Linux i686; fr-FR; rv:1.2.1) Gecko/20030225 |
Dean Roehrich a écrit:
- fh_to_inode() must test the fid_len field and return the root inode number if its value is zero. I'm sorry if I was unclear here. I never said dmfsfid need to be modified. We just check its fid_len, return the root inode if null or return the file inode refers by the filehandle otherwise. When the inode number is known, try to get it with a iget(), if the iget succeeded, the inode was correct, else, return an error. Here is my full function code, I think it agrees with your explanations : static int
ext3_dm_fh_to_inode(
struct super_block *sb,
struct inode **ip,
struct dm_fsfid *dmfsfid)
{
int error = 0;
ino_t ino = 0;
dm_fid_t fid;/* * Read the inode number from the handle and fetch the corresponding * inode. */
return -error; /* Return negative error to DMAPI */ }
|
| Previous by Date: | Re: [DMAPI] code error in dm_ip_to_handle(), Dean Roehrich |
|---|---|
| Next by Date: | Re: [DMAPI] code error in dm_ip_to_handle(), Dean Roehrich |
| Previous by Thread: | Re: [DMAPI] code error in dm_ip_to_handle(), Dean Roehrich |
| Next by Thread: | Re: [DMAPI] code error in dm_ip_to_handle(), Dean Roehrich |
| Indexes: | [Date] [Thread] [Top] [All Lists] |