diff options
author | Bart Van Assche <bart.vanassche@sandisk.com> | 2016-02-11 11:04:20 -0800 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2016-02-29 17:12:34 -0500 |
commit | f68cba4e9f7cdd3808631af286cc3244c5e57dab (patch) | |
tree | 34156515df3a8e24df1b5652899cca62996c70d9 /drivers/infiniband/ulp/srpt/ib_srpt.c | |
parent | 697a35d709b828c406c1061b38251866a7871aa0 (diff) | |
download | op-kernel-dev-f68cba4e9f7cdd3808631af286cc3244c5e57dab.zip op-kernel-dev-f68cba4e9f7cdd3808631af286cc3244c5e57dab.tar.gz |
IB/srpt: Inline srpt_sdev_name()
srpt_sdev_name() is too trivial to keep it as a separate function.
Hence inline this function.
Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Sagi Grimberg <sagig@mellanox.com>
Cc: Alex Estrin <alex.estrin@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/ulp/srpt/ib_srpt.c')
-rw-r--r-- | drivers/infiniband/ulp/srpt/ib_srpt.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c index 9f5cd3f..babc15b 100644 --- a/drivers/infiniband/ulp/srpt/ib_srpt.c +++ b/drivers/infiniband/ulp/srpt/ib_srpt.c @@ -109,16 +109,6 @@ enum dma_data_direction opposite_dma_dir(enum dma_data_direction dir) } } -/** - * srpt_sdev_name() - Return the name associated with the HCA. - * - * Examples are ib0, ib1, ... - */ -static inline const char *srpt_sdev_name(struct srpt_device *sdev) -{ - return sdev->device->name; -} - static enum rdma_ch_state srpt_get_ch_state(struct srpt_rdma_ch *ch) { unsigned long flags; @@ -182,7 +172,7 @@ static void srpt_event_handler(struct ib_event_handler *handler, return; pr_debug("ASYNC event= %d on device= %s\n", event->event, - srpt_sdev_name(sdev)); + sdev->device->name); switch (event->event) { case IB_EVENT_PORT_ERR: @@ -3025,7 +3015,7 @@ static void srpt_add_one(struct ib_device *device) if (srpt_refresh_port(sport)) { pr_err("MAD registration failed for %s-%d.\n", - srpt_sdev_name(sdev), i); + sdev->device->name, i); goto err_ring; } snprintf(sport->port_guid, sizeof(sport->port_guid), |