I don't see that we are following notify_type4 either. notify_type4 is
enum 0,1,2,3,.... so notify_deviceid_type4 should be enum 0,1 or 1,2 since
it was already defined this way in the spec. Defining it as 2, 4 make no
sense if it is a bit number, way skip bits?. The use of shift is used for
bit mask which you claim it is not.
Marc.
From: Benny Halevy <[email protected]>
To: Marc Eshel/Almaden/IBM@IBMUS,
Cc: [email protected], NFS list
<[email protected]>, "J. Bruce Fields" <[email protected]>, Trond
Myklebust <[email protected]>
Date: 12/09/2012 11:54 AM
Subject: Re: notify_deviceid_type4
I'm not sure if and whete that's saud explicitly but another example to
support that inrerpretation are the values of notify_type4 that apply to
the same bitmap that too are defined as sequential numbers (though zero
based) and not as single bit masks.
Benny
On Dec 9, 2012 8:05 PM, "Marc Eshel" <[email protected]> wrote:
Can you provide with the spec information that supports your
interpretation?
Marc.
From: Benny Halevy <[email protected]>
To: Marc Eshel/Almaden/IBM@IBMUS,
Cc: [email protected], Trond Myklebust
<[email protected]>, [email protected], "J. Bruce Fields"
<[email protected]>
Date: 12/09/2012 09:50 AM
Subject: Re: notify_deviceid_type4
The enum values in the spec correspond to bit _numbers_ in the bitmap, not
to bitmasks.
On Dec 9, 2012 6:43 PM, "Marc Eshel" <[email protected]> wrote:
I am not sure what you are saying, I am showing the definition from the
spec. that show NOTIFY_DEVICEID4_CHANGE = 1, and nfs4.h has it as (1<< 1)
which is not 1, it is 2.
Marc.
Benny Halevy <[email protected]> wrote on 12/09/2012 01:42:47 AM:
> From: Benny Halevy <[email protected]>
> To: Marc Eshel/Almaden/IBM@IBMUS,
> Cc: Trond Myklebust <[email protected]>, "J. Bruce Fields"
> <[email protected]>, [email protected], linux-
> [email protected]
> Date: 12/09/2012 01:44 AM
> Subject: Re: notify_deviceid_type4
>
> On 2012-12-01 07:54, Marc Eshel wrote:
> > The spec defines notify_deviceid_type4 as:
> >
> > 20.12.1. ARGUMENT
> > /*
> > * Device notification types.
> > */
> > enum notify_deviceid_type4 {
> > NOTIFY_DEVICEID4_CHANGE = 1,
> > NOTIFY_DEVICEID4_DELETE = 2
> > };
> >
> >
> > but the Linux code in nfs4.h has, is that going to be fixed?
> >
> > enum pnfs_notify_deviceid_type4 {
> > NOTIFY_DEVICEID4_CHANGE = 1 << 1,
> > NOTIFY_DEVICEID4_DELETE = 1 << 2,
> > };
>
> notify_deviceid_type4 specifies bit numbers same as notify_type4
> It seems to me like the definition in nfs4.h is correct.
>
> Benny
>
> >
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-nfs"
in
> > the body of a message to [email protected]
> > More majordomo info at http://vger.kernel.org/majordomo-info.html
> >
>