From: Michael Ellerman <michael@ellerman.id.au>
To: <jgarzik@pobox.com>
Cc: Andrew Morton <akpm@osdl.org>, <netdev@vger.kernel.org>,
<santil@us.ibm.com>
Subject: [PATCH] Fix sparse errors in drivers/net/ibmveth.c
Date: Tue, 17 Apr 2007 13:12:55 +1000 [thread overview]
Message-ID: <20070417031314.BC404DDED4@ozlabs.org> (raw)
drivers/net/ibmveth.c:96:46: error: marked inline, but without a definition
drivers/net/ibmveth.c:96: warning: 'ibmveth_rxq_harvest_buffer' declared inline after being called
drivers/net/ibmveth.c:96: warning: previous declaration of 'ibmveth_rxq_harvest_buffer' was here
Just let the compiler decide, as it happens gcc 4.~ inlines it anyway.
drivers/net/ibmveth.c:957:71: warning: Using plain integer as NULL pointer
drivers/net/ibmveth.c:964:85: warning: Using plain integer as NULL pointer
Split the long lines as well, ugly, but < 80 columns.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
---
drivers/net/ibmveth.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
Index: powerpc/drivers/net/ibmveth.c
===================================================================
--- powerpc.orig/drivers/net/ibmveth.c
+++ powerpc/drivers/net/ibmveth.c
@@ -93,7 +93,7 @@ static void ibmveth_proc_unregister_driv
static void ibmveth_proc_register_adapter(struct ibmveth_adapter *adapter);
static void ibmveth_proc_unregister_adapter(struct ibmveth_adapter *adapter);
static irqreturn_t ibmveth_interrupt(int irq, void *dev_instance);
-static inline void ibmveth_rxq_harvest_buffer(struct ibmveth_adapter *adapter);
+static void ibmveth_rxq_harvest_buffer(struct ibmveth_adapter *adapter);
static struct kobj_type ktype_veth_pool;
#ifdef CONFIG_PROC_FS
@@ -389,7 +389,7 @@ static void ibmveth_rxq_recycle_buffer(s
}
}
-static inline void ibmveth_rxq_harvest_buffer(struct ibmveth_adapter *adapter)
+static void ibmveth_rxq_harvest_buffer(struct ibmveth_adapter *adapter)
{
ibmveth_remove_buffer_from_pool(adapter, adapter->rx_queue.queue_addr[adapter->rx_queue.index].correlator);
@@ -954,14 +954,16 @@ static int __devinit ibmveth_probe(struc
ibmveth_debug_printk_no_adapter("entering ibmveth_probe for UA 0x%x\n",
dev->unit_address);
- mac_addr_p = (unsigned char *) vio_get_attribute(dev, VETH_MAC_ADDR, 0);
+ mac_addr_p = (unsigned char *) vio_get_attribute(dev,
+ VETH_MAC_ADDR, NULL);
if(!mac_addr_p) {
printk(KERN_ERR "(%s:%3.3d) ERROR: Can't find VETH_MAC_ADDR "
"attribute\n", __FILE__, __LINE__);
return 0;
}
- mcastFilterSize_p= (unsigned int *) vio_get_attribute(dev, VETH_MCAST_FILTER_SIZE, 0);
+ mcastFilterSize_p = (unsigned int *) vio_get_attribute(dev,
+ VETH_MCAST_FILTER_SIZE, NULL);
if(!mcastFilterSize_p) {
printk(KERN_ERR "(%s:%3.3d) ERROR: Can't find "
"VETH_MCAST_FILTER_SIZE attribute\n",
next reply other threads:[~2007-04-17 3:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-17 3:12 Michael Ellerman [this message]
2007-04-24 18:02 ` [PATCH] Fix sparse errors in drivers/net/ibmveth.c Jeff Garzik
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=20070417031314.BC404DDED4@ozlabs.org \
--to=michael@ellerman.id.au \
--cc=akpm@osdl.org \
--cc=jgarzik@pobox.com \
--cc=netdev@vger.kernel.org \
--cc=santil@us.ibm.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;
as well as URLs for NNTP newsgroup(s).