From: Adrian Bunk <bunk@stusta.de>
To: Andrew Morton <akpm@osdl.org>,
"Ed L. Cashin" <ecashin@coraid.com>, Greg K-H <greg@kroah.com>
Cc: linux-kernel@vger.kernel.org
Subject: [-mm patch] drivers/block/aoe/aoecmd.c: make aoecmd_cfg_pkts() static
Date: Thu, 12 Jan 2006 11:48:33 +0100 [thread overview]
Message-ID: <20060112104833.GS29663@stusta.de> (raw)
In-Reply-To: <20060111042135.24faf878.akpm@osdl.org>
On Wed, Jan 11, 2006 at 04:21:35AM -0800, Andrew Morton wrote:
>...
> Changes since 2.6.15-mm2:
>...
> +gregkh-driver-aoe-support-dynamic-resizing-of-aoe-devices.patch
>...
> driver tree updates
>...
aoecmd_cfg_pkts() can be static.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
---
drivers/block/aoe/aoe.h | 1
drivers/block/aoe/aoecmd.c | 94 ++++++++++++++++++-------------------
2 files changed, 47 insertions(+), 48 deletions(-)
--- linux-2.6.15-mm3-full/drivers/block/aoe/aoe.h.old 2006-01-12 00:56:33.000000000 +0100
+++ linux-2.6.15-mm3-full/drivers/block/aoe/aoe.h 2006-01-12 00:56:38.000000000 +0100
@@ -154,7 +154,6 @@
void aoecmd_work(struct aoedev *d);
void aoecmd_cfg(ushort aoemajor, unsigned char aoeminor);
-struct sk_buff *aoecmd_cfg_pkts(ushort, unsigned char, struct sk_buff **);
void aoecmd_ata_rsp(struct sk_buff *);
void aoecmd_cfg_rsp(struct sk_buff *);
void aoecmd_sleepwork(void *vp);
--- linux-2.6.15-mm3-full/drivers/block/aoe/aoecmd.c.old 2006-01-12 00:56:47.000000000 +0100
+++ linux-2.6.15-mm3-full/drivers/block/aoe/aoecmd.c 2006-01-12 00:57:29.000000000 +0100
@@ -190,6 +190,53 @@
}
}
+/* some callers cannot sleep, and they can call this function,
+ * transmitting the packets later, when interrupts are on
+ */
+static struct sk_buff *
+aoecmd_cfg_pkts(ushort aoemajor, unsigned char aoeminor, struct sk_buff **tail)
+{
+ struct aoe_hdr *h;
+ struct aoe_cfghdr *ch;
+ struct sk_buff *skb, *sl, *sl_tail;
+ struct net_device *ifp;
+
+ sl = sl_tail = NULL;
+
+ read_lock(&dev_base_lock);
+ for (ifp = dev_base; ifp; dev_put(ifp), ifp = ifp->next) {
+ dev_hold(ifp);
+ if (!is_aoe_netif(ifp))
+ continue;
+
+ skb = new_skb(ifp, sizeof *h + sizeof *ch);
+ if (skb == NULL) {
+ printk(KERN_INFO "aoe: aoecmd_cfg: skb alloc failure\n");
+ continue;
+ }
+ if (sl_tail == NULL)
+ sl_tail = skb;
+ h = (struct aoe_hdr *) skb->mac.raw;
+ memset(h, 0, sizeof *h + sizeof *ch);
+
+ memset(h->dst, 0xff, sizeof h->dst);
+ memcpy(h->src, ifp->dev_addr, sizeof h->src);
+ h->type = __constant_cpu_to_be16(ETH_P_AOE);
+ h->verfl = AOE_HVER;
+ h->major = cpu_to_be16(aoemajor);
+ h->minor = aoeminor;
+ h->cmd = AOECMD_CFG;
+
+ skb->next = sl;
+ sl = skb;
+ }
+ read_unlock(&dev_base_lock);
+
+ if (tail != NULL)
+ *tail = sl_tail;
+ return sl;
+}
+
/* enters with d->lock held */
void
aoecmd_work(struct aoedev *d)
@@ -543,53 +590,6 @@
aoenet_xmit(sl);
}
-/* some callers cannot sleep, and they can call this function,
- * transmitting the packets later, when interrupts are on
- */
-struct sk_buff *
-aoecmd_cfg_pkts(ushort aoemajor, unsigned char aoeminor, struct sk_buff **tail)
-{
- struct aoe_hdr *h;
- struct aoe_cfghdr *ch;
- struct sk_buff *skb, *sl, *sl_tail;
- struct net_device *ifp;
-
- sl = sl_tail = NULL;
-
- read_lock(&dev_base_lock);
- for (ifp = dev_base; ifp; dev_put(ifp), ifp = ifp->next) {
- dev_hold(ifp);
- if (!is_aoe_netif(ifp))
- continue;
-
- skb = new_skb(ifp, sizeof *h + sizeof *ch);
- if (skb == NULL) {
- printk(KERN_INFO "aoe: aoecmd_cfg: skb alloc failure\n");
- continue;
- }
- if (sl_tail == NULL)
- sl_tail = skb;
- h = (struct aoe_hdr *) skb->mac.raw;
- memset(h, 0, sizeof *h + sizeof *ch);
-
- memset(h->dst, 0xff, sizeof h->dst);
- memcpy(h->src, ifp->dev_addr, sizeof h->src);
- h->type = __constant_cpu_to_be16(ETH_P_AOE);
- h->verfl = AOE_HVER;
- h->major = cpu_to_be16(aoemajor);
- h->minor = aoeminor;
- h->cmd = AOECMD_CFG;
-
- skb->next = sl;
- sl = skb;
- }
- read_unlock(&dev_base_lock);
-
- if (tail != NULL)
- *tail = sl_tail;
- return sl;
-}
-
void
aoecmd_cfg(ushort aoemajor, unsigned char aoeminor)
{
next prev parent reply other threads:[~2006-01-12 10:48 UTC|newest]
Thread overview: 72+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-11 12:21 2.6.15-mm3 Andrew Morton
2006-01-11 13:43 ` 2.6.15-mm3 Pekka Enberg
2006-01-11 14:27 ` 2.6.15-mm3 Ashutosh Naik
2006-01-11 16:21 ` 2.6.15-mm3 Dominik Karall
2006-01-11 22:22 ` 2.6.15-mm3, current -git: drivers/media/video/ compile errors Adrian Bunk
2006-01-11 22:48 ` Mauro Carvalho Chehab
2006-01-11 16:57 ` [PATCH -mm] mm/rmap.c: don't forget to include module.h Alexey Dobriyan
2006-01-11 21:42 ` Adrian Bunk
2006-01-11 21:50 ` Christoph Lameter
2006-01-11 18:25 ` 2.6.15-mm3 Roman Zippel
2006-01-11 18:45 ` 2.6.15-mm3 Andrew Morton
2006-01-11 22:26 ` 2.6.15-mm3 Roman Zippel
2006-01-11 18:34 ` 2.6.15-mm3 Brice Goglin
2006-01-11 18:40 ` 2.6.15-mm3 Dominik Brodowski
2006-01-11 19:07 ` 2.6.15-mm3 Brice Goglin
2006-01-11 19:55 ` 2.6.15-mm3 Dominik Brodowski
2006-01-11 20:28 ` 2.6.15-mm3 Brice Goglin
2006-01-11 21:21 ` 2.6.15-mm3 Dominik Brodowski
2006-01-11 22:47 ` 2.6.15-mm3 Brice Goglin
2006-01-11 23:00 ` 2.6.15-mm3 Dominik Brodowski
2006-01-11 23:23 ` 2.6.15-mm3 Brice Goglin
2006-01-11 18:49 ` 2.6.15-mm3 Andrew Morton
2006-01-11 21:39 ` 2.6.15-mm3 Grant Coady
2006-01-11 23:41 ` 2.6.15-mm3: arch/ia64/sn/kernel/sn2/sn_proc_fs.c compile error Adrian Bunk
2006-01-11 23:41 ` Adrian Bunk
2006-01-12 0:01 ` Andrew Morton
2006-01-12 0:01 ` Andrew Morton
2006-01-12 0:17 ` Adrian Bunk
2006-01-12 0:17 ` Adrian Bunk
2006-01-12 0:23 ` Andrew Morton
2006-01-12 0:23 ` Andrew Morton
2006-01-12 0:54 ` Adrian Bunk
2006-01-12 0:54 ` Adrian Bunk
2006-01-12 1:02 ` [-mm patch] fix arch/ia64/sn/kernel/tiocx.c compilation Adrian Bunk
2006-01-12 1:02 ` Adrian Bunk
2006-01-12 16:43 ` Greg KH
2006-01-12 16:43 ` Greg KH
2006-01-12 4:04 ` 2.6.15-mm3 Reuben Farrelly
[not found] ` <43C5D537.7020800-MwA23MxOyI4@public.gmane.org>
2006-01-12 4:33 ` 2.6.15-mm3 Andrew Morton
2006-01-12 4:33 ` 2.6.15-mm3 Andrew Morton
[not found] ` <20060111203332.50c45031.akpm-3NddpPZAyC0@public.gmane.org>
2006-01-12 4:38 ` 2.6.15-mm3 Reuben Farrelly
2006-01-12 4:38 ` 2.6.15-mm3 Reuben Farrelly
2006-01-12 8:54 ` 2.6.15-mm3 [USB lost interrupt bug] Reuben Farrelly
2006-01-12 8:54 ` Reuben Farrelly
[not found] ` <43C6194C.1070107-MwA23MxOyI4@public.gmane.org>
2006-01-12 15:53 ` [linux-usb-devel] " Alan Stern
2006-01-12 15:53 ` Alan Stern
[not found] ` <Pine.LNX.4.44L0.0601121052190.5383-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2006-01-15 22:50 ` Reuben Farrelly
2006-01-15 22:50 ` Reuben Farrelly
[not found] ` <43CAD1BB.60301-MwA23MxOyI4@public.gmane.org>
2006-01-16 3:22 ` Alan Stern
2006-01-16 3:22 ` Alan Stern
[not found] ` <Pine.LNX.4.44L0.0601152212340.1929-100000-pYrvlCTfrz9XsRXLowluHWD2FQJk+8+b@public.gmane.org>
2006-01-16 3:28 ` Reuben Farrelly
2006-01-16 3:28 ` Reuben Farrelly
[not found] ` <43CB12EA.3040309-MwA23MxOyI4@public.gmane.org>
2006-01-16 3:46 ` Alan Stern
2006-01-16 3:46 ` Alan Stern
2006-01-21 5:21 ` Reuben Farrelly
2006-01-21 5:47 ` Andrew Morton
2006-01-21 5:47 ` [linux-usb-devel] " Andrew Morton
2006-01-21 7:58 ` Reuben Farrelly
2006-01-21 8:32 ` [PATCH] " Jeff Garzik
2006-01-21 10:41 ` Reuben Farrelly
2006-01-12 10:48 ` [RFC: -mm patch] swsusp: make some code static Adrian Bunk
2006-01-12 10:48 ` Adrian Bunk
2006-01-12 15:29 ` Pavel Machek
2006-01-12 16:18 ` Rafael J. Wysocki
2006-01-12 10:48 ` Adrian Bunk [this message]
2006-01-12 23:55 ` [-mm patch] drivers/block/aoe/aoecmd.c: make aoecmd_cfg_pkts() static Ed L. Cashin
2006-01-12 21:05 ` 2.6.15-mm3 Rafael J. Wysocki
2006-01-12 21:58 ` 2.6.15-mm3 Andrew Morton
2006-01-12 22:01 ` 2.6.15-mm3 Patrick McHardy
2006-01-13 8:34 ` 2.6.15-mm3 Sachin Sant
2006-01-13 11:52 ` 2.6.15-mm3 Andrew Morton
2006-01-13 21:59 ` 2.6.15-mm3 Benjamin Herrenschmidt
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=20060112104833.GS29663@stusta.de \
--to=bunk@stusta.de \
--cc=akpm@osdl.org \
--cc=ecashin@coraid.com \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
/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.