From: Lars Ellenberg <lars.ellenberg@linbit.com>
To: drbd-dev@lists.linbit.com
Subject: Re: [Drbd-dev] [PATCH] DRBD: Delete superfluous defn of "ARRY_SIZE".
Date: Tue, 9 Mar 2010 15:50:13 +0100 [thread overview]
Message-ID: <20100309145013.GJ4199@soda.linbit> (raw)
In-Reply-To: <alpine.LFD.2.00.1003090743100.22662@localhost>
On Tue, Mar 09, 2010 at 07:44:36AM -0500, Robert P. J. Day wrote:
>
> Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
>
> ---
>
> 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.
>
> diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c
> index ab871e0..36508ea 100644
> --- a/drivers/block/drbd/drbd_main.c
> +++ b/drivers/block/drbd/drbd_main.c
> @@ -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
;-)
--
: 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.
prev parent reply other threads:[~2010-03-09 14:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-09 12:44 [Drbd-dev] [PATCH] DRBD: Delete superfluous defn of "ARRY_SIZE" Robert P. J. Day
2010-03-09 14:50 ` Lars Ellenberg [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100309145013.GJ4199@soda.linbit \
--to=lars.ellenberg@linbit.com \
--cc=drbd-dev@lists.linbit.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.