From patchwork Mon Jul 30 09:44:01 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shlomo Pongratz X-Patchwork-Id: 1254121 Return-Path: X-Original-To: patchwork-linux-rdma@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 919A1DF24C for ; Mon, 30 Jul 2012 09:44:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752539Ab2G3JoM (ORCPT ); Mon, 30 Jul 2012 05:44:12 -0400 Received: from eu1sys200aog117.obsmtp.com ([207.126.144.143]:56921 "HELO eu1sys200aog117.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1751897Ab2G3JoL (ORCPT ); Mon, 30 Jul 2012 05:44:11 -0400 Received: from mtlsws123.lab.mtl.com ([82.166.227.17]) (using TLSv1) by eu1sys200aob117.postini.com ([207.126.147.11]) with SMTP ID DSNKUBZXZd/gAZ2VSq+K4rgRA5rFtsYf1YzS@postini.com; Mon, 30 Jul 2012 09:44:10 UTC Received: from r-vnc04.lab.mtl.com (r-vnc04.lab.mtl.com [10.208.0.116]) by mtlsws123.lab.mtl.com (8.13.8/8.13.8) with ESMTP id q6U9i25M019843; Mon, 30 Jul 2012 12:44:03 +0300 From: Shlomo Pongratz To: linux-rdma@vger.kernel.org Cc: ogerlitz@mellanox.com, kernel-janitors@vger.kernel.org, wfg@linux.intel.com, roland@kernel.org, Shlomo Pongratz Subject: [for-next PATCH] IB/IPoIB: correct typo errors Date: Mon, 30 Jul 2012 12:44:01 +0300 Message-Id: <1343641441-11942-1-git-send-email-shlomop@mellanox.com> X-Mailer: git-send-email 1.7.8.2 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org used 'ntbl->lock' instead of 'ntbl->rwlock'. wrong pointer type in non CM stub 'ipoib_cm_enabled' in function prototype. Reported-by: Fengguang Wu Signed-off-by: Shlomo Pongratz --- drivers/infiniband/ulp/ipoib/ipoib.h | 2 +- drivers/infiniband/ulp/ipoib/ipoib_main.c | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/infiniband/ulp/ipoib/ipoib.h b/drivers/infiniband/ulp/ipoib/ipoib.h index 4965f90..ca43901 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib.h +++ b/drivers/infiniband/ulp/ipoib/ipoib.h @@ -591,7 +591,7 @@ static inline int ipoib_cm_admin_enabled(struct net_device *dev) { return 0; } -static inline int ipoib_cm_enabled(struct net_device *dev, struct neighbour *n) +static inline int ipoib_cm_enabled(struct net_device *dev, u8 *hwaddr) { return 0; diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c b/drivers/infiniband/ulp/ipoib/ipoib_main.c index a68ce4e..61318a7 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_main.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c @@ -882,7 +882,7 @@ static void __ipoib_reap_neigh(struct ipoib_dev_priv *priv) struct ipoib_neigh __rcu **np = &htbl->buckets[i]; while ((neigh = rcu_dereference_protected(*np, - lockdep_is_held(&ntbl->lock))) != NULL) { + is_held(&ntbl->rwlock))) != NULL) { /* was the neigh idle for two GC periods */ if (time_after(neigh_obsolete, neigh->alive)) { rcu_assign_pointer(*np, @@ -962,7 +962,7 @@ struct ipoib_neigh *ipoib_neigh_alloc(u8 *daddr, lockdep_is_held(&ntbl->rwlock)); neigh != NULL; neigh = rcu_dereference_protected(neigh->hnext, - lockdep_is_held(&ntbl->lock))) { + lockdep_is_held(&ntbl->rwlock))) { if (memcmp(daddr, neigh->daddr, INFINIBAND_ALEN) == 0) { /* found, take one ref on behalf of the caller */ if (!atomic_inc_not_zero(&neigh->refcnt)) { @@ -1051,7 +1051,7 @@ void ipoib_neigh_free(struct ipoib_neigh *neigh) lockdep_is_held(&ntbl->rwlock)); n != NULL; n = rcu_dereference_protected(neigh->hnext, - lockdep_is_held(&ntbl->lock))) { + lockdep_is_held(&ntbl->rwlock))) { if (n == neigh) { /* found */ rcu_assign_pointer(*np, @@ -1135,7 +1135,7 @@ void ipoib_del_neighs_by_gid(struct net_device *dev, u8 *gid) struct ipoib_neigh __rcu **np = &htbl->buckets[i]; while ((neigh = rcu_dereference_protected(*np, - lockdep_is_held(&ntbl->lock))) != NULL) { + lockdep_is_held(&ntbl->rwlock))) != NULL) { /* delete neighs belong to this parent */ if (!memcmp(gid, neigh->daddr + 4, sizeof (union ib_gid))) { rcu_assign_pointer(*np, @@ -1175,7 +1175,7 @@ static void ipoib_flush_neighs(struct ipoib_dev_priv *priv) struct ipoib_neigh __rcu **np = &htbl->buckets[i]; while ((neigh = rcu_dereference_protected(*np, - lockdep_is_held(&ntbl->lock))) != NULL) { + lockdep_is_held(&ntbl->rwlock))) != NULL) { rcu_assign_pointer(*np, rcu_dereference_protected(neigh->hnext, lockdep_is_held(&ntbl->rwlock)));