diff options
author | Max Gurtovoy <maxg@mellanox.com> | 2020-03-09 16:04:12 +0100 |
---|---|---|
committer | Keith Busch <kbusch@kernel.org> | 2020-03-25 20:51:54 +0100 |
commit | 2db24e4a22bc97c713261a81fc75e2a36db65715 (patch) | |
tree | 8282f56d98e92a3e1dd0f57a5e872d2d2b8e672d /drivers/nvme/host/pci.c | |
parent | nvme-tcp: break from io_work loop if recv failed (diff) | |
download | linux-2db24e4a22bc97c713261a81fc75e2a36db65715.tar.xz linux-2db24e4a22bc97c713261a81fc75e2a36db65715.zip |
nvme-pci: properly print controller address
Align PCI address print with fabrics address that is printed with
newline character.
Before:
[root@server40 linux]# cat /sys/class/nvme/nvme2/address
0000:0b:00.0[root@server40 linux]#
After:
[root@server40 linux]# cat /sys/class/nvme/nvme2/address
0000:0b:00.0
[root@server40 linux]#
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Max Gurtovoy <maxg@mellanox.com>
Diffstat (limited to 'drivers/nvme/host/pci.c')
-rw-r--r-- | drivers/nvme/host/pci.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c index f45e26e6af7e..e6fa0c7bb96c 100644 --- a/drivers/nvme/host/pci.c +++ b/drivers/nvme/host/pci.c @@ -2656,7 +2656,7 @@ static int nvme_pci_get_address(struct nvme_ctrl *ctrl, char *buf, int size) { struct pci_dev *pdev = to_pci_dev(to_nvme_dev(ctrl)->dev); - return snprintf(buf, size, "%s", dev_name(&pdev->dev)); + return snprintf(buf, size, "%s\n", dev_name(&pdev->dev)); } static const struct nvme_ctrl_ops nvme_pci_ctrl_ops = { |