Re: [PATCH 16/22] pnfs-submit: rewrite of layout state handling and cb_layoutrecall

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

 



On 2010-11-14 13:44, Benny Halevy wrote:
> On 2010-11-13 11:11, Trond Myklebust wrote:
>> On Fri, 2010-11-12 at 03:48 -0500, Fred Isaman wrote:
>>> +	switch (cb_args->cbl_recall_type) {
>>> +	case RETURN_ALL:
>>> +		return true;
>>> +	case RETURN_FSID:
>>> +		return !memcmp(&NFS_SERVER(ino)->fsid, &cb_args->cbl_fsid,
>>> +			       sizeof(struct nfs_fsid));
>>> +	case RETURN_FILE:
>>> +		return (ino == cb_info->pcl_ino) &&
>>> +			should_free_lseg(range, &cb_args->cbl_range);
>>> +	default:
>>> +		BUG();
>>
>> Why should we BUG() just because the server is screwed up? That's not a
>> client bug.
>>
> 
> Agreed.  This should be handled earlier in nfs4_callback_layoutrecall
> or do_callback_layoutrecall so that we can return NFS4ERR_INVALID.
> 

Actually NFS4ERR_BADXDR is the right error to return for a
"value within the input stream that is not valid for the enum"

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


[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux