From: Rusty Russell <rusty@rustcorp.com.au>
To: torvalds@transmeta.com
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] bitops cleanup
Date: Thu, 11 Jul 2002 17:55:02 +1000 [thread overview]
Message-ID: <20020711081915.1A4144506@lists.samba.org> (raw)
Nomenclature tweak and move to bitops.h (also deleted redundant
<asm/bitops.h> double include.
Please apply,
Rusty.
Name: Bitops Cleanup
Author: Rusty Russell
Status: Trivial
D: This renames bitmap_member to DECLARE_BITMAP, and moves it to bitops.h.
diff -urN -I $.*$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.24.7405/include/linux/bitops.h linux-2.5.24.7405.updated/include/linux/bitops.h
--- linux-2.5.24.7405/include/linux/bitops.h Fri Jun 7 13:59:07 2002
+++ linux-2.5.24.7405.updated/include/linux/bitops.h Sat Jun 22 05:07:14 2002
@@ -2,6 +2,9 @@
#define _LINUX_BITOPS_H
#include <asm/bitops.h>
+#define DECLARE_BITMAP(name,bits)
+ unsigned long name[((bits)+BITS_PER_LONG-1)/BITS_PER_LONG]
+
/*
* ffs: find first bit set. This is defined the same way as
* the libc and compiler builtin ffs routines, therefore
@@ -106,8 +109,5 @@
res = (res & 0x33) + ((res >> 2) & 0x33);
return (res & 0x0F) + ((res >> 4) & 0x0F);
}
-
-#include <asm/bitops.h>
-
#endif
diff -urN -I $.*$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.24.7405/include/linux/types.h linux-2.5.24.7405.updated/include/linux/types.h
--- linux-2.5.24.7405/include/linux/types.h Mon Jun 17 23:19:25 2002
+++ linux-2.5.24.7405.updated/include/linux/types.h Sat Jun 22 05:07:14 2002
@@ -3,9 +3,6 @@
#ifdef __KERNEL__
#include <linux/config.h>
-
-#define bitmap_member(name,bits)
- unsigned long name[((bits)+BITS_PER_LONG-1)/BITS_PER_LONG]
#endif
#include <linux/posix_types.h>
diff -urN -I $.*$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.24.7405/include/sound/ac97_codec.h linux-2.5.24.7405.updated/include/sound/ac97_codec.h
--- linux-2.5.24.7405/include/sound/ac97_codec.h Fri Jun 21 09:41:55 2002
+++ linux-2.5.24.7405.updated/include/sound/ac97_codec.h Sat Jun 22 05:21:08 2002
@@ -25,6 +25,7 @@
*
*/
+#include <linux/bitops.h>
#include "control.h"
#include "info.h"
@@ -169,7 +170,7 @@
unsigned int rates_mic_adc;
unsigned int spdif_status;
unsigned short regs[0x80]; /* register cache */
- bitmap_member(reg_accessed,0x80); /* bit flags */
+ DECLARE_BITMAP(reg_accessed, 0x80); /* bit flags */
union { /* vendor specific code */
struct {
unsigned short unchained[3]; // 0 = C34, 1 = C79, 2 = C69
diff -urN -I $.*$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.24.7405/sound/core/seq/seq_clientmgr.h linux-2.5.24.7405.updated/sound/core/seq/seq_clientmgr.h
--- linux-2.5.24.7405/sound/core/seq/seq_clientmgr.h Fri Jun 21 09:41:57 2002
+++ linux-2.5.24.7405.updated/sound/core/seq/seq_clientmgr.h Sat Jun 22 05:20:37 2002
@@ -53,7 +53,7 @@
char name[64]; /* client name */
int number; /* client number */
unsigned int filter; /* filter flags */
- bitmap_member(event_filter, 256);
+ DECLARE_BITMAP(event_filter, 256);
snd_use_lock_t use_lock;
int event_lost;
/* ports */
diff -urN -I $.*$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.24.7405/sound/core/seq/seq_queue.h linux-2.5.24.7405.updated/sound/core/seq/seq_queue.h
--- linux-2.5.24.7405/sound/core/seq/seq_queue.h Fri Jun 21 09:41:57 2002
+++ linux-2.5.24.7405.updated/sound/core/seq/seq_queue.h Sat Jun 22 05:08:27 2002
@@ -26,6 +26,7 @@
#include "seq_lock.h"
#include <linux/interrupt.h>
#include <linux/list.h>
+#include <linux/bitops.h>
#define SEQ_QUEUE_NO_OWNER (-1)
@@ -51,7 +52,7 @@
spinlock_t check_lock;
/* clients which uses this queue (bitmap) */
- bitmap_member(clients_bitmap, SNDRV_SEQ_MAX_CLIENTS);
+ DECLARE_BITMAP(clients_bitmap, SNDRV_SEQ_MAX_CLIENTS);
unsigned int clients; /* users of this queue */
struct semaphore timer_mutex;
--
Anyone who quotes me in their sig is an idiot. -- Rusty Russell.
reply other threads:[~2002-07-11 8:16 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20020711081915.1A4144506@lists.samba.org \
--to=rusty@rustcorp.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®