All of lore.kernel.org
 help / color / mirror / Atom feed
* [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo?
@ 2009-07-02 14:13 Jeff Liu
  2009-07-02 22:21 ` TaoMa
  0 siblings, 1 reply; 4+ messages in thread
From: Jeff Liu @ 2009-07-02 14:13 UTC (permalink / raw)
  To: ocfs2-devel

I've read fs/ocfs2/dlm/dlmcommon.h to study the structure of dlm_migratable_lockres.
However, I may find a typo for the DLM_MIG_LOCKRES_MAX_LEN,
the NET_MAX_PAYLOAD_BYTES should be O2NET_MAX_PAYLOAD_BYTES, I think.
In comments, the sizeof(net_msg) should be sizeof(o2net_msg) by referring to fs/ocfs2/cluster/tcp.h.

Signed-off-by: Jeff Liu <jeff.liu@oracle.com>
---
 fs/ocfs2/dlm/dlmcommon.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h
index 0102be3..2dfe89e 100644
--- a/fs/ocfs2/dlm/dlmcommon.h
+++ b/fs/ocfs2/dlm/dlmcommon.h
@@ -540,7 +540,7 @@ struct dlm_master_requery
  * };
  *
  * from ../cluster/tcp.h
- *    NET_MAX_PAYLOAD_BYTES  (4096 - sizeof(net_msg))
+ *    O2NET_MAX_PAYLOAD_BYTES  (4096 - sizeof(o2net_msg))
  *    (roughly 4080 bytes)
  * and sizeof(dlm_migratable_lockres) = 112 bytes
  * and sizeof(dlm_migratable_lock) = 16 bytes
@@ -581,7 +581,7 @@ struct dlm_migratable_lockres
 
 /* from above, 128 bytes
  * for some undetermined future use */
-#define DLM_MIG_LOCKRES_RESERVED   (NET_MAX_PAYLOAD_BYTES - \
+#define DLM_MIG_LOCKRES_RESERVED   (O2NET_MAX_PAYLOAD_BYTES - \
 				    DLM_MIG_LOCKRES_MAX_LEN)
 
 struct dlm_create_lock
-- 
1.5.4.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo?
  2009-07-02 22:21 ` TaoMa
@ 2009-07-02 14:32   ` Sunil Mushran
  2009-07-02 14:35   ` jeff.liu
  1 sibling, 0 replies; 4+ messages in thread
From: Sunil Mushran @ 2009-07-02 14:32 UTC (permalink / raw)
  To: ocfs2-devel

TaoMa wrote:
>> I've read fs/ocfs2/dlm/dlmcommon.h to study the structure of dlm_migratable_lockres.
>> However, I may find a typo for the DLM_MIG_LOCKRES_MAX_LEN,
>> the NET_MAX_PAYLOAD_BYTES should be O2NET_MAX_PAYLOAD_BYTES, I think.
>> In comments, the sizeof(net_msg) should be sizeof(o2net_msg) by referring to fs/ocfs2/cluster/tcp.h.
>>   
> yeah, NET_MAX_PAYLOAD_BYTES here should be O2NET_MAX_PAYLOAD_BYTES and I 
> guess the reason why we never find this error is because we never use 
> DLM_MIG_LOCKRES_RESERVED by now.

And if we have not used it by now, chances are we never will. Maybe just
remove it. But let it be for the time being. I'll ask Kurt if he 
remembers what
the reasoning was.

> btw, there is another NET_MAX_PAYLOAD_BYTES you forget to change in 
> fs/ocfs2/dlm/dlmcommon.h
>   

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo?
  2009-07-02 22:21 ` TaoMa
  2009-07-02 14:32   ` Sunil Mushran
@ 2009-07-02 14:35   ` jeff.liu
  1 sibling, 0 replies; 4+ messages in thread
From: jeff.liu @ 2009-07-02 14:35 UTC (permalink / raw)
  To: ocfs2-devel

Hi Tao,

Yes, thanks for your remind.


Regards,
Jeff

TaoMa ??:
> Hi Jeff,
> Jeff Liu wrote:
>> I've read fs/ocfs2/dlm/dlmcommon.h to study the structure of 
>> dlm_migratable_lockres.
>> However, I may find a typo for the DLM_MIG_LOCKRES_MAX_LEN,
>> the NET_MAX_PAYLOAD_BYTES should be O2NET_MAX_PAYLOAD_BYTES, I think.
>> In comments, the sizeof(net_msg) should be sizeof(o2net_msg) by 
>> referring to fs/ocfs2/cluster/tcp.h.
> yeah, NET_MAX_PAYLOAD_BYTES here should be O2NET_MAX_PAYLOAD_BYTES and 
> I guess the reason why we never find this error is because we never 
> use DLM_MIG_LOCKRES_RESERVED by now.
>
> btw, there is another NET_MAX_PAYLOAD_BYTES you forget to change in 
> fs/ocfs2/dlm/dlmcommon.h
>
> Regards,
> Tao
>> Signed-off-by: Jeff Liu <jeff.liu@oracle.com>
>> ---
>> fs/ocfs2/dlm/dlmcommon.h | 4 ++--
>> 1 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h
>> index 0102be3..2dfe89e 100644
>> --- a/fs/ocfs2/dlm/dlmcommon.h
>> +++ b/fs/ocfs2/dlm/dlmcommon.h
>> @@ -540,7 +540,7 @@ struct dlm_master_requery
>> * };
>> *
>> * from ../cluster/tcp.h
>> - * NET_MAX_PAYLOAD_BYTES (4096 - sizeof(net_msg))
>> + * O2NET_MAX_PAYLOAD_BYTES (4096 - sizeof(o2net_msg))
>> * (roughly 4080 bytes)
>> * and sizeof(dlm_migratable_lockres) = 112 bytes
>> * and sizeof(dlm_migratable_lock) = 16 bytes
>> @@ -581,7 +581,7 @@ struct dlm_migratable_lockres
>>
>> /* from above, 128 bytes
>> * for some undetermined future use */
>> -#define DLM_MIG_LOCKRES_RESERVED (NET_MAX_PAYLOAD_BYTES - \
>> +#define DLM_MIG_LOCKRES_RESERVED (O2NET_MAX_PAYLOAD_BYTES - \
>> DLM_MIG_LOCKRES_MAX_LEN)
>>
>> struct dlm_create_lock
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo?
  2009-07-02 14:13 [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo? Jeff Liu
@ 2009-07-02 22:21 ` TaoMa
  2009-07-02 14:32   ` Sunil Mushran
  2009-07-02 14:35   ` jeff.liu
  0 siblings, 2 replies; 4+ messages in thread
From: TaoMa @ 2009-07-02 22:21 UTC (permalink / raw)
  To: ocfs2-devel

Hi Jeff,
Jeff Liu wrote:
> I've read fs/ocfs2/dlm/dlmcommon.h to study the structure of dlm_migratable_lockres.
> However, I may find a typo for the DLM_MIG_LOCKRES_MAX_LEN,
> the NET_MAX_PAYLOAD_BYTES should be O2NET_MAX_PAYLOAD_BYTES, I think.
> In comments, the sizeof(net_msg) should be sizeof(o2net_msg) by referring to fs/ocfs2/cluster/tcp.h.
>   
yeah, NET_MAX_PAYLOAD_BYTES here should be O2NET_MAX_PAYLOAD_BYTES and I 
guess the reason why we never find this error is because we never use 
DLM_MIG_LOCKRES_RESERVED by now.

btw, there is another NET_MAX_PAYLOAD_BYTES you forget to change in 
fs/ocfs2/dlm/dlmcommon.h

Regards,
Tao
> Signed-off-by: Jeff Liu <jeff.liu@oracle.com>
> ---
>  fs/ocfs2/dlm/dlmcommon.h |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/ocfs2/dlm/dlmcommon.h b/fs/ocfs2/dlm/dlmcommon.h
> index 0102be3..2dfe89e 100644
> --- a/fs/ocfs2/dlm/dlmcommon.h
> +++ b/fs/ocfs2/dlm/dlmcommon.h
> @@ -540,7 +540,7 @@ struct dlm_master_requery
>   * };
>   *
>   * from ../cluster/tcp.h
> - *    NET_MAX_PAYLOAD_BYTES  (4096 - sizeof(net_msg))
> + *    O2NET_MAX_PAYLOAD_BYTES  (4096 - sizeof(o2net_msg))
>   *    (roughly 4080 bytes)
>   * and sizeof(dlm_migratable_lockres) = 112 bytes
>   * and sizeof(dlm_migratable_lock) = 16 bytes
> @@ -581,7 +581,7 @@ struct dlm_migratable_lockres
>  
>  /* from above, 128 bytes
>   * for some undetermined future use */
> -#define DLM_MIG_LOCKRES_RESERVED   (NET_MAX_PAYLOAD_BYTES - \
> +#define DLM_MIG_LOCKRES_RESERVED   (O2NET_MAX_PAYLOAD_BYTES - \
>  				    DLM_MIG_LOCKRES_MAX_LEN)
>  
>  struct dlm_create_lock
>   

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-07-02 22:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-02 14:13 [Ocfs2-devel] [PATCH 1/1] [ocfs2-devel] NET_MAX_PAYLOAD_BYTES typo? Jeff Liu
2009-07-02 22:21 ` TaoMa
2009-07-02 14:32   ` Sunil Mushran
2009-07-02 14:35   ` jeff.liu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.