[PATCH] PPC64 iSeries virtual ethernet minor optimisation
Stephen Rothwell
sfr at canb.auug.org.au
Mon May 31 18:34:16 EST 2004
Hi Linus, Andrew,
This has only been adjusted by me to apply after David Gibson's patch to
add a watchdog timer. Please apply.
Name: Minor Optimization for iseries_veth Driver
Status: Untested
Version: ppc64
Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> (a)
The iseries_veth driver does skb_clone, it should only need to
skb_get, which is cheaper. Should help performance a little.
Signed-off-by: Stephen Rothwell <sfr at canb.auug.org.au>
--
Cheers,
Stephen Rothwell sfr at canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
-------------- next part --------------
diff -ruN 2.6.7-rc2.wd/drivers/net/iseries_veth.c 2.6.7-rc2.wd.rusty/drivers/net/iseries_veth.c
--- 2.6.7-rc2.wd/drivers/net/iseries_veth.c 2004-05-31 17:49:10.000000000 +1000
+++ 2.6.7-rc2.wd.rusty/drivers/net/iseries_veth.c 2004-05-31 18:10:30.000000000 +1000
@@ -983,19 +983,10 @@
int rc;
for (i = 0; i < HVMAXARCHITECTEDLPS; i++) {
- struct sk_buff *clone;
-
if ((lpmask & (1 << i)) == 0)
continue;
- clone = skb_clone(skb, GFP_ATOMIC);
- if (! clone) {
- veth_error("%s: skb_clone failed %p\n",
- dev->name, skb);
- continue;
- }
-
- rc = veth_transmit_to_one(clone, i, dev);
+ rc = veth_transmit_to_one(skb_get(skb), i, dev);
if (! rc)
lpmask &= ~(1<<i);
}
More information about the Linuxppc64-dev
mailing list