Commit 72c93bcc authored by Ingo Molnar's avatar Ingo Molnar Committed by Nathan Scott

[XFS] lock validator: lockdep: small xfs init_rwsem() cleanup

init_rwsem() has no return value.  This is not a problem if init_rwsem()
is a function, but it's a problem if it's a do { ...  } while (0) macro. 
(which lockdep introduces) 

SGI-PV: 904196
SGI-Modid: xfs-linux-melb:xfs-kern:26082a
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarArjan van de Ven <arjan@linux.intel.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarNathan Scott <nathans@sgi.com>
parent 87c199c2
/* /*
* Copyright (c) 2000-2005 Silicon Graphics, Inc. * Copyright (c) 2000-2006 Silicon Graphics, Inc.
* All Rights Reserved. * All Rights Reserved.
* *
* This program is free software; you can redistribute it and/or * This program is free software; you can redistribute it and/or
...@@ -28,7 +28,7 @@ typedef struct { ...@@ -28,7 +28,7 @@ typedef struct {
} mrlock_t; } mrlock_t;
#define mrinit(mrp, name) \ #define mrinit(mrp, name) \
( (mrp)->mr_writer = 0, init_rwsem(&(mrp)->mr_lock) ) do { (mrp)->mr_writer = 0; init_rwsem(&(mrp)->mr_lock); } while (0)
#define mrlock_init(mrp, t,n,s) mrinit(mrp, n) #define mrlock_init(mrp, t,n,s) mrinit(mrp, n)
#define mrfree(mrp) do { } while (0) #define mrfree(mrp) do { } while (0)
#define mraccess(mrp) mraccessf(mrp, 0) #define mraccess(mrp) mraccessf(mrp, 0)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment