projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
22441cf
)
decnet: Fix compiler warning in dn_dev.c
author
David S. Miller
<davem@davemloft.net>
Wed, 15 Oct 2008 22:59:50 +0000
(15:59 -0700)
committer
David S. Miller
<davem@davemloft.net>
Wed, 15 Oct 2008 23:03:02 +0000
(16:03 -0700)
Use offsetof() instead of home-brewed version.
Based upon initial patch by Steven Whitehouse and suggestions
by Ben Hutchings.
Signed-off-by: David S. Miller <davem@davemloft.net>
net/decnet/dn_dev.c
patch
|
blob
|
blame
|
history
diff --git
a/net/decnet/dn_dev.c
b/net/decnet/dn_dev.c
index 2f0ac3c3eb710e409ee41323b22f6f64fa2a5342..ba352588e344f2eb79e853877c1af30028c6331d 100644
(file)
--- a/
net/decnet/dn_dev.c
+++ b/
net/decnet/dn_dev.c
@@
-152,7
+152,7
@@
static struct dn_dev_parms dn_dev_list[] = {
#define DN_DEV_LIST_SIZE ARRAY_SIZE(dn_dev_list)
-#define DN_DEV_PARMS_OFFSET(x)
((int) ((char *) &((struct dn_dev_parms *)0)->x)
)
+#define DN_DEV_PARMS_OFFSET(x)
offsetof(struct dn_dev_parms, x
)
#ifdef CONFIG_SYSCTL