Skip to content

Commit

Permalink
Merge tag 'rdma-for-linus' of git://git.kernel.org/pub/scm/linux/kern…
Browse files Browse the repository at this point in the history
…el/git/roland/infiniband

Pull infiniband fixes from Roland Dreier:
 - qib RCU/lockdep fix
 - iser device removal fix, plus doc fixes

* tag 'rdma-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
  IB/qib: Fix lockdep splat in qib_alloc_lkey()
  MAINTAINERS: Add entry for iSCSI Extensions for RDMA (iSER) initiator
  IB/iser: Add Mellanox copyright
  IB/iser: Fix device removal flow
  • Loading branch information
torvalds committed Jun 7, 2013
2 parents 5125ed5 + c9a2433 commit e8193ce
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 8 deletions.
10 changes: 10 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -4448,6 +4448,16 @@ S: Maintained
F: drivers/scsi/*iscsi*
F: include/scsi/*iscsi*

ISCSI EXTENSIONS FOR RDMA (ISER) INITIATOR
M: Or Gerlitz <[email protected]>
M: Roi Dayan <[email protected]>
L: [email protected]
S: Supported
W: http://www.openfabrics.org
W: www.open-iscsi.org
Q: http://patchwork.kernel.org/project/linux-rdma/list/
F: drivers/infiniband/ulp/iser

ISDN SUBSYSTEM
M: Karsten Keil <[email protected]>
L: [email protected] (subscribers-only)
Expand Down
2 changes: 1 addition & 1 deletion drivers/infiniband/hw/qib/qib_keys.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ int qib_alloc_lkey(struct qib_mregion *mr, int dma_region)
if (dma_region) {
struct qib_mregion *tmr;

tmr = rcu_dereference(dev->dma_mr);
tmr = rcu_access_pointer(dev->dma_mr);
if (!tmr) {
qib_get_mr(mr);
rcu_assign_pointer(dev->dma_mr, mr);
Expand Down
1 change: 1 addition & 0 deletions drivers/infiniband/ulp/iser/iscsi_iser.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* Copyright (C) 2004 Alex Aizman
* Copyright (C) 2005 Mike Christie
* Copyright (c) 2005, 2006 Voltaire, Inc. All rights reserved.
* Copyright (c) 2013 Mellanox Technologies. All rights reserved.
* maintained by [email protected]
*
* This software is available to you under a choice of one of two
Expand Down
1 change: 1 addition & 0 deletions drivers/infiniband/ulp/iser/iscsi_iser.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*
* Copyright (c) 2004, 2005, 2006 Voltaire, Inc. All rights reserved.
* Copyright (c) 2005, 2006 Cisco Systems. All rights reserved.
* Copyright (c) 2013 Mellanox Technologies. All rights reserved.
*
* This software is available to you under a choice of one of two
* licenses. You may choose to be licensed under the terms of the GNU
Expand Down
1 change: 1 addition & 0 deletions drivers/infiniband/ulp/iser/iser_initiator.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
* Copyright (c) 2004, 2005, 2006 Voltaire, Inc. All rights reserved.
* Copyright (c) 2013 Mellanox Technologies. All rights reserved.
*
* This software is available to you under a choice of one of two
* licenses. You may choose to be licensed under the terms of the GNU
Expand Down
1 change: 1 addition & 0 deletions drivers/infiniband/ulp/iser/iser_memory.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
* Copyright (c) 2004, 2005, 2006 Voltaire, Inc. All rights reserved.
* Copyright (c) 2013 Mellanox Technologies. All rights reserved.
*
* This software is available to you under a choice of one of two
* licenses. You may choose to be licensed under the terms of the GNU
Expand Down
16 changes: 9 additions & 7 deletions drivers/infiniband/ulp/iser/iser_verbs.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/*
* Copyright (c) 2004, 2005, 2006 Voltaire, Inc. All rights reserved.
* Copyright (c) 2005, 2006 Cisco Systems. All rights reserved.
* Copyright (c) 2013 Mellanox Technologies. All rights reserved.
*
* This software is available to you under a choice of one of two
* licenses. You may choose to be licensed under the terms of the GNU
Expand Down Expand Up @@ -292,10 +293,10 @@ static int iser_create_ib_conn_res(struct iser_conn *ib_conn)
}

/**
* releases the FMR pool, QP and CMA ID objects, returns 0 on success,
* releases the FMR pool and QP objects, returns 0 on success,
* -1 on failure
*/
static int iser_free_ib_conn_res(struct iser_conn *ib_conn, int can_destroy_id)
static int iser_free_ib_conn_res(struct iser_conn *ib_conn)
{
int cq_index;
BUG_ON(ib_conn == NULL);
Expand All @@ -314,13 +315,9 @@ static int iser_free_ib_conn_res(struct iser_conn *ib_conn, int can_destroy_id)

rdma_destroy_qp(ib_conn->cma_id);
}
/* if cma handler context, the caller acts s.t the cma destroy the id */
if (ib_conn->cma_id != NULL && can_destroy_id)
rdma_destroy_id(ib_conn->cma_id);

ib_conn->fmr_pool = NULL;
ib_conn->qp = NULL;
ib_conn->cma_id = NULL;
kfree(ib_conn->page_vec);

if (ib_conn->login_buf) {
Expand Down Expand Up @@ -415,11 +412,16 @@ static void iser_conn_release(struct iser_conn *ib_conn, int can_destroy_id)
list_del(&ib_conn->conn_list);
mutex_unlock(&ig.connlist_mutex);
iser_free_rx_descriptors(ib_conn);
iser_free_ib_conn_res(ib_conn, can_destroy_id);
iser_free_ib_conn_res(ib_conn);
ib_conn->device = NULL;
/* on EVENT_ADDR_ERROR there's no device yet for this conn */
if (device != NULL)
iser_device_try_release(device);
/* if cma handler context, the caller actually destroy the id */
if (ib_conn->cma_id != NULL && can_destroy_id) {
rdma_destroy_id(ib_conn->cma_id);
ib_conn->cma_id = NULL;
}
iscsi_destroy_endpoint(ib_conn->ep);
}

Expand Down

0 comments on commit e8193ce

Please sign in to comment.