[openib-general] [PATCH] [TRIVIAL] Remove unused variable (not debug) from ipoib_mutlicast.c
Roland Dreier
roland at topspin.com
Sat Nov 6 08:44:56 PST 2004
Hal> Remove unused variable (not debug) from ipoib_mutlicast.c
Thanks for pointing this out. I fixed it like this rather than adding
another #ifdef...
Index: infiniband/ulp/ipoib/ipoib_multicast.c
===================================================================
--- infiniband/ulp/ipoib/ipoib_multicast.c (revision 1167)
+++ infiniband/ulp/ipoib/ipoib_multicast.c (working copy)
@@ -259,14 +259,13 @@
{
struct ipoib_mcast *mcast = mcast_ptr;
struct net_device *dev = mcast->dev;
- struct ipoib_dev_priv *priv = netdev_priv(dev);
if (!status)
ipoib_mcast_join_finish(mcast, mcmember);
else {
if (mcast->logcount++ < 20)
- ipoib_dbg_mcast(priv, "multicast join failed for " IPOIB_GID_FMT
- ", status %d\n",
+ ipoib_dbg_mcast(netdev_priv(dev), "multicast join failed for "
+ IPOIB_GID_FMT ", status %d\n",
IPOIB_GID_ARG(mcast->mcmember.mgid), status);
/* Flush out any queued packets */
Index: infiniband/ulp/ipoib/ipoib.h
===================================================================
--- infiniband/ulp/ipoib/ipoib.h (revision 1167)
+++ infiniband/ulp/ipoib/ipoib.h (working copy)
@@ -228,7 +228,7 @@
#define ipoib_printk(level, priv, format, arg...) \
- printk(level "%s: " format, (priv)->dev->name , ## arg)
+ printk(level "%s: " format, ((struct ipoib_dev_priv *) priv)->dev->name , ## arg)
#define ipoib_warn(priv, format, arg...) \
ipoib_printk(KERN_WARNING, priv, format , ## arg)
Index: infiniband/ulp/ipoib/ipoib_ib.c
===================================================================
--- infiniband/ulp/ipoib/ipoib_ib.c (revision 1167)
+++ infiniband/ulp/ipoib/ipoib_ib.c (working copy)
@@ -461,12 +461,8 @@
/*..ipoib_ib_dev_cleanup -- clean up IB resources for iface */
void ipoib_ib_dev_cleanup(struct net_device *dev)
{
- struct ipoib_dev_priv *priv = netdev_priv(dev);
+ ipoib_dbg(netdev_priv(dev), "cleaning up ib_dev\n");
- /* Avoid unused warning if DEBUG is off */
- (void) priv;
- ipoib_dbg(priv, "cleaning up ib_dev\n");
-
ipoib_mcast_stop_thread(dev);
/* Delete the broadcast address and the local address */
More information about the general
mailing list