DRBD: Delete superfluous defn of "ARRY_SIZE".
Subsystems (2)
PATCH 1/1 DRBD: Delete superfluous defn of "ARRY_SIZE".
---
given that the macro is misspelled, no one appears to use it, and
there already is an ARRAY_SIZE() macro defined in kernel.h for general use, there's really no reason for this to be here.
drivers/block/drbd/drbd_main.c +0 -2
@@ -156,8 +156,6 @@ static const struct block_device_operations drbd_ops = { .release = drbd_release, }; -#define ARRY_SIZE (A ) (sizeof(A)/sizeof(A[0])) -#ifdef __CHECKER__/* When checking with sparse, and this is an inline function, sparse will give tons of false positives. When this is a real functions sparse works.
rday
--
========================================================================
Robert P. J. Day Waterloo, Ontario, CANADA
Linux Consulting, Training and Kernel Pedantry.
Web page: http://crashcourse.ca Twitter: http://twitter.com/rpjday
========================================================================
Lars Ellenberg
maintainerQuoted 14 lines · Robert P. J. Day
Signed-off-by Robert P. J. Day <[email protected]>---
given that the macro is misspelled, no one appears to use it, and
there already is anARRAY_SIZE()macro defined inkernel.hfor general use, there's really no reason for this to be here.drivers/block/drbd/drbd_main.c +0
-0
drivers/block/drbd/drbd_main.c static const struct block_device_operations drbd_ops = { · line 159
Quoted 4 lines
drivers/block/drbd/drbd_main.c +0
-1@@ -156,8 +156,6 @@ static const struct block_device_operations drbd_ops = { .release = drbd_release, }; -#define ARRY_SIZE (A ) (sizeof(A)/sizeof(A[0]))
Wow.
Thats a leftover from 2001 ... linux-2.4.4 days. And even then it was unused, and the ARRAY_SIZE macro was already in linux/kernel.h
;-)
Signature · 5 lines
: Lars Ellenberg : LINBIT | Your Way to High Availability : DRBD/HA support and consulting http://www.linbit.com DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.