Skip to content

Commit

Permalink
IB/mad: Ignore iWARP devices on device removal
Browse files Browse the repository at this point in the history
When an iWARP device is unloaded, the ib_mad module logs errors.  It
should be ignoring iWARP devices on device removal just like it does
on device add.

Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Acked-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
  • Loading branch information
Steve Wise authored and Roland Dreier committed Mar 11, 2010
1 parent 25cf84c commit 070e140
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/infiniband/core/mad.c
Original file line number Diff line number Diff line change
Expand Up @@ -2953,6 +2953,9 @@ static void ib_mad_remove_device(struct ib_device *device)
{
int i, num_ports, cur_port;

if (rdma_node_get_transport(device->node_type) != RDMA_TRANSPORT_IB)
return;

if (device->node_type == RDMA_NODE_IB_SWITCH) {
num_ports = 1;
cur_port = 0;
Expand Down

0 comments on commit 070e140

Please sign in to comment.