From: Wang Chen <wangchen@cn.fujitsu.com>
To: "David S. Miller" <davem@davemloft.net>, NETDEV <netdev@vger.kernel.org>
Subject: [PATCH next] sgi-xp: Kill directly reference of netdev->priv
Date: Thu, 04 Dec 2008 20:56:47 +0800 [thread overview]
Message-ID: <4937D38F.6010102@cn.fujitsu.com> (raw)
Simply replace netdev->priv with netdev_priv().
Not do compile test, because no IA64 or x86_64 box.
Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
---
drivers/misc/sgi-xp/xpnet.c | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/misc/sgi-xp/xpnet.c b/drivers/misc/sgi-xp/xpnet.c
index 71513b3..9e5233a 100644
--- a/drivers/misc/sgi-xp/xpnet.c
+++ b/drivers/misc/sgi-xp/xpnet.c
@@ -154,7 +154,7 @@ xpnet_receive(short partid, int channel, struct xpnet_message *msg)
void *dst;
enum xp_retval ret;
struct xpnet_dev_private *priv =
- (struct xpnet_dev_private *)xpnet_device->priv;
+ (struct xpnet_dev_private *)netdev_priv(xpnet_device);
if (!XPNET_VALID_MSG(msg)) {
/*
@@ -370,7 +370,7 @@ xpnet_dev_get_stats(struct net_device *dev)
{
struct xpnet_dev_private *priv;
- priv = (struct xpnet_dev_private *)dev->priv;
+ priv = (struct xpnet_dev_private *)netdev_priv(dev);
return &priv->stats;
}
@@ -456,7 +456,8 @@ xpnet_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
struct xpnet_pending_msg *queued_msg;
u64 start_addr, end_addr;
short dest_partid;
- struct xpnet_dev_private *priv = (struct xpnet_dev_private *)dev->priv;
+ struct xpnet_dev_private *priv =
+ (struct xpnet_dev_private *)netdev_priv(dev);
u16 embedded_bytes = 0;
dev_dbg(xpnet, ">skb->head=0x%p skb->data=0x%p skb->tail=0x%p "
@@ -543,7 +544,7 @@ xpnet_dev_tx_timeout(struct net_device *dev)
{
struct xpnet_dev_private *priv;
- priv = (struct xpnet_dev_private *)dev->priv;
+ priv = (struct xpnet_dev_private *)netdev_priv(dev);
priv->stats.tx_errors++;
return;
--
1.5.3.4
next reply other threads:[~2008-12-04 12:56 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-04 12:56 Wang Chen [this message]
2008-12-04 13:41 ` [PATCH next] sgi-xp: Kill directly reference of netdev->priv Ilpo Järvinen
2008-12-04 23:12 ` David Miller
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=4937D38F.6010102@cn.fujitsu.com \
--to=wangchen@cn.fujitsu.com \
--cc=davem@davemloft.net \
--cc=netdev@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 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).