2011-11-09 03:52:04

by Boaz Harrosh

[permalink] [raw]
Subject: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS


I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.

While at it I changed nfs4pnfsdlm.c to, also already defined, NFSDDBG_FILELAYOUT
which was unused before this patch.

CC: Steve Dickson <[email protected]>
Signed-off-by: Boaz Harrosh <[email protected]>
---
fs/nfsd/nfs4pnfsd.c | 2 +-
fs/nfsd/nfs4pnfsdlm.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/nfsd/nfs4pnfsd.c b/fs/nfsd/nfs4pnfsd.c
index 18b8fca..f514ebe 100644
--- a/fs/nfsd/nfs4pnfsd.c
+++ b/fs/nfsd/nfs4pnfsd.c
@@ -23,7 +23,7 @@

#include "pnfsd.h"

-#define NFSDDBG_FACILITY NFSDDBG_PROC
+#define NFSDDBG_FACILITY NFSDDBG_PNFS

/* Globals */
static u32 current_layoutid = 1;
diff --git a/fs/nfsd/nfs4pnfsdlm.c b/fs/nfsd/nfs4pnfsdlm.c
index abc4d83..0f0441a 100644
--- a/fs/nfsd/nfs4pnfsdlm.c
+++ b/fs/nfsd/nfs4pnfsdlm.c
@@ -30,7 +30,7 @@
#include "nfsfh.h"
#include "nfsd.h"

-#define NFSDDBG_FACILITY NFSDDBG_PROC
+#define NFSDDBG_FACILITY NFSDDBG_FILELAYOUT

/* Just use a linked list. Do not expect more than 32 dlm_device_entries
* the first implementation will just use one device per cluster file system
--
1.7.6.2




2011-11-10 16:04:37

by Boaz Harrosh

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On 11/09/2011 11:55 AM, J. Bruce Fields wrote:
> On Tue, Nov 08, 2011 at 07:51:50PM -0800, Boaz Harrosh wrote:
>>
>> I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
>> up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
>> It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.
>
> Hey now, nfs4pnfsd.c has enough problems of its own without being
> accused of surliness.
>

Allow me to disagree! the nfs4pnfsd.c is a very nice pretty clean, well formatted and
well implemented pNFS-Server implementation. Believe me I have seen a few other pNFS
and Parallel servers implementation and this is surgery room clean compare to the
other. (If you look at the point before pnfs-exp and spNFS patches)

The only real mess in there is the mess already inherited from nfsd, like the great and grate
messy locking. Though it's better then the rest of the NFSD code.

So you see, I do think it could be accused of "surliness"

> --b.
>
>>

--Be

2011-11-09 19:55:12

by J. Bruce Fields

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On Tue, Nov 08, 2011 at 07:51:50PM -0800, Boaz Harrosh wrote:
>
> I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
> up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
> It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.

Hey now, nfs4pnfsd.c has enough problems of its own without being
accused of surliness.

--b.

>
> While at it I changed nfs4pnfsdlm.c to, also already defined, NFSDDBG_FILELAYOUT
> which was unused before this patch.
>
> CC: Steve Dickson <[email protected]>
> Signed-off-by: Boaz Harrosh <[email protected]>
> ---
> fs/nfsd/nfs4pnfsd.c | 2 +-
> fs/nfsd/nfs4pnfsdlm.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/nfsd/nfs4pnfsd.c b/fs/nfsd/nfs4pnfsd.c
> index 18b8fca..f514ebe 100644
> --- a/fs/nfsd/nfs4pnfsd.c
> +++ b/fs/nfsd/nfs4pnfsd.c
> @@ -23,7 +23,7 @@
>
> #include "pnfsd.h"
>
> -#define NFSDDBG_FACILITY NFSDDBG_PROC
> +#define NFSDDBG_FACILITY NFSDDBG_PNFS
>
> /* Globals */
> static u32 current_layoutid = 1;
> diff --git a/fs/nfsd/nfs4pnfsdlm.c b/fs/nfsd/nfs4pnfsdlm.c
> index abc4d83..0f0441a 100644
> --- a/fs/nfsd/nfs4pnfsdlm.c
> +++ b/fs/nfsd/nfs4pnfsdlm.c
> @@ -30,7 +30,7 @@
> #include "nfsfh.h"
> #include "nfsd.h"
>
> -#define NFSDDBG_FACILITY NFSDDBG_PROC
> +#define NFSDDBG_FACILITY NFSDDBG_FILELAYOUT
>
> /* Just use a linked list. Do not expect more than 32 dlm_device_entries
> * the first implementation will just use one device per cluster file system
> --
> 1.7.6.2
>
>
> --
> 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

2011-11-14 23:53:49

by J. Bruce Fields

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On Mon, Nov 14, 2011 at 03:35:41PM -0800, Boaz Harrosh wrote:
> On 11/14/2011 03:09 PM, J. Bruce Fields wrote:
> > On Thu, Nov 10, 2011 at 08:04:21AM -0800, Boaz Harrosh wrote:
> >
> > You mean the overuse of the state lock, or something else?
> >
>
> Yes and the places that causes to unlock / lock because of
> recursion or bad lock ordering.

That's purely a pNFS problem, right?

--b.

2011-11-10 16:10:04

by Boaz Harrosh

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On 11/10/2011 08:04 AM, Boaz Harrosh wrote:
> On 11/09/2011 11:55 AM, J. Bruce Fields wrote:
>> On Tue, Nov 08, 2011 at 07:51:50PM -0800, Boaz Harrosh wrote:
>>>
>>> I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
>>> up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
>>> It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.
>>
>> Hey now, nfs4pnfsd.c has enough problems of its own without being
>> accused of surliness.
>>
>
> Allow me to disagree! the nfs4pnfsd.c is a very nice pretty clean, well formatted and
> well implemented pNFS-Server implementation. Believe me I have seen a few other pNFS
> and Parallel servers implementation and this is surgery room clean compare to the
> other. (If you look at the point before pnfs-exp and spNFS patches)
>
> The only real mess in there is the mess already inherited from nfsd, like the great and grate
> messy locking. Though it's better then the rest of the NFSD code.
>
> So you see, I do think it could be accused of "surliness"
>

O, by the way I did not mean there is not lots of places for improvements and that the
code is perfect.

If you see things you don't like, or buggy or, could be done better, please tell us
so we can fix them.

>> --b.
>>
>>>
>
> --Be
> --
> 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


2011-11-14 23:09:25

by J. Bruce Fields

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On Thu, Nov 10, 2011 at 08:04:21AM -0800, Boaz Harrosh wrote:
> On 11/09/2011 11:55 AM, J. Bruce Fields wrote:
> > Hey now, nfs4pnfsd.c has enough problems of its own without being
> > accused of surliness.
> >
>
> Allow me to disagree! the nfs4pnfsd.c is a very nice pretty clean,
> well formatted and well implemented pNFS-Server implementation.
> Believe me I have seen a few other pNFS and Parallel servers
> implementation and this is surgery room clean compare to the other.
> (If you look at the point before pnfs-exp and spNFS patches)

OK, I hope so! And we *are* getting closer to finishing off the last of
the 4.1 stuff (though with just me it's not going to happen for 3.3.),
so I hope to be looking at that soon.

> The only real mess in there is the mess already inherited from nfsd,
> like the great and grate messy locking.

You mean the overuse of the state lock, or something else?

--b.

> Though it's better then the rest of the NFSD code.

2011-11-10 06:56:04

by Benny Halevy

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On 2011-11-09 21:55, J. Bruce Fields wrote:
> On Tue, Nov 08, 2011 at 07:51:50PM -0800, Boaz Harrosh wrote:
>>
>> I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
>> up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
>> It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.
>
> Hey now, nfs4pnfsd.c has enough problems of its own without being
> accused of surliness.

:-)

>
> --b.
>
>>
>> While at it I changed nfs4pnfsdlm.c to, also already defined, NFSDDBG_FILELAYOUT
>> which was unused before this patch.
>>
>> CC: Steve Dickson <[email protected]>
>> Signed-off-by: Boaz Harrosh <[email protected]>
>> ---
>> fs/nfsd/nfs4pnfsd.c | 2 +-
>> fs/nfsd/nfs4pnfsdlm.c | 2 +-
>> 2 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/fs/nfsd/nfs4pnfsd.c b/fs/nfsd/nfs4pnfsd.c
>> index 18b8fca..f514ebe 100644
>> --- a/fs/nfsd/nfs4pnfsd.c
>> +++ b/fs/nfsd/nfs4pnfsd.c
>> @@ -23,7 +23,7 @@
>>
>> #include "pnfsd.h"
>>
>> -#define NFSDDBG_FACILITY NFSDDBG_PROC
>> +#define NFSDDBG_FACILITY NFSDDBG_PNFS
>>
>> /* Globals */
>> static u32 current_layoutid = 1;
>> diff --git a/fs/nfsd/nfs4pnfsdlm.c b/fs/nfsd/nfs4pnfsdlm.c
>> index abc4d83..0f0441a 100644
>> --- a/fs/nfsd/nfs4pnfsdlm.c
>> +++ b/fs/nfsd/nfs4pnfsdlm.c
>> @@ -30,7 +30,7 @@
>> #include "nfsfh.h"
>> #include "nfsd.h"
>>
>> -#define NFSDDBG_FACILITY NFSDDBG_PROC
>> +#define NFSDDBG_FACILITY NFSDDBG_FILELAYOUT
>>
>> /* Just use a linked list. Do not expect more than 32 dlm_device_entries
>> * the first implementation will just use one device per cluster file system
>> --
>> 1.7.6.2
>>
>>
>> --
>> 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
> --
> 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

2011-11-10 06:55:40

by Benny Halevy

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On 2011-11-09 05:51, Boaz Harrosh wrote:
>
> I've been squinting at pnfsd dprints for ages and aching under the wait. So I headed
> up to the nfsd/debug.h to add a PNFS channel, and what do you know? there is one!
> It's used by nfs4pnfsds.c. Surly nfs4pnfsd.c is more _PNFS than _PROC.
>
> While at it I changed nfs4pnfsdlm.c to, also already defined, NFSDDBG_FILELAYOUT
> which was unused before this patch.
>
> CC: Steve Dickson <[email protected]>
> Signed-off-by: Boaz Harrosh <[email protected]>

Makes sense. Thanks!

Benny

> ---
> fs/nfsd/nfs4pnfsd.c | 2 +-
> fs/nfsd/nfs4pnfsdlm.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/nfsd/nfs4pnfsd.c b/fs/nfsd/nfs4pnfsd.c
> index 18b8fca..f514ebe 100644
> --- a/fs/nfsd/nfs4pnfsd.c
> +++ b/fs/nfsd/nfs4pnfsd.c
> @@ -23,7 +23,7 @@
>
> #include "pnfsd.h"
>
> -#define NFSDDBG_FACILITY NFSDDBG_PROC
> +#define NFSDDBG_FACILITY NFSDDBG_PNFS
>
> /* Globals */
> static u32 current_layoutid = 1;
> diff --git a/fs/nfsd/nfs4pnfsdlm.c b/fs/nfsd/nfs4pnfsdlm.c
> index abc4d83..0f0441a 100644
> --- a/fs/nfsd/nfs4pnfsdlm.c
> +++ b/fs/nfsd/nfs4pnfsdlm.c
> @@ -30,7 +30,7 @@
> #include "nfsfh.h"
> #include "nfsd.h"
>
> -#define NFSDDBG_FACILITY NFSDDBG_PROC
> +#define NFSDDBG_FACILITY NFSDDBG_FILELAYOUT
>
> /* Just use a linked list. Do not expect more than 32 dlm_device_entries
> * the first implementation will just use one device per cluster file system

2011-11-14 23:36:00

by Boaz Harrosh

[permalink] [raw]
Subject: Re: Subject: [PATCH] SQUASHME: pnfsd: nfs4pnfsd.c should dprint under NFSDDBG_PNFS

On 11/14/2011 03:09 PM, J. Bruce Fields wrote:
> On Thu, Nov 10, 2011 at 08:04:21AM -0800, Boaz Harrosh wrote:
>
> You mean the overuse of the state lock, or something else?
>

Yes and the places that causes to unlock / lock because of
recursion or bad lock ordering.

So it's not as clean as it could be

Thanks
Boaz

> --b.
>
>> Though it's better then the rest of the NFSD code.