summaryrefslogtreecommitdiff
path: root/drivers/infiniband/hw/mthca
diff options
context:
space:
mode:
authorJason Gunthorpe <jgg@mellanox.com>2018-09-21 01:42:24 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-09-26 22:51:48 +0300
commit5a738b5d47050b77ac8aa90bd79429940533ef6a (patch)
tree8b7abdd13cfe9635e1f46ed2b8c51901ed2173aa /drivers/infiniband/hw/mthca
parent43c7c851b9bce9e6091f2c882871a3b388aa38c3 (diff)
downloadlinux-5a738b5d47050b77ac8aa90bd79429940533ef6a.tar.xz
RDMA/drivers: Use dev_err/dbg/etc instead of pr_* + ibdev->name
Kernel convention is that a driver for a subsystem will print using dev_* on the subsystem's struct device, or with dev_* on the physical device. Drivers should rarely use a pr_* function. Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/mthca')
-rw-r--r--drivers/infiniband/hw/mthca/mthca_mad.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/mthca/mthca_mad.c b/drivers/infiniband/hw/mthca/mthca_mad.c
index 093f7755c843..2e5dc0a67cfc 100644
--- a/drivers/infiniband/hw/mthca/mthca_mad.c
+++ b/drivers/infiniband/hw/mthca/mthca_mad.c
@@ -58,8 +58,9 @@ static int mthca_update_rate(struct mthca_dev *dev, u8 port_num)
ret = ib_query_port(&dev->ib_dev, port_num, tprops);
if (ret) {
- printk(KERN_WARNING "ib_query_port failed (%d) for %s port %d\n",
- ret, dev->ib_dev.name, port_num);
+ dev_warn(&dev->ib_dev.dev,
+ "ib_query_port failed (%d) forport %d\n", ret,
+ port_num);
goto out;
}