提交 8cc0698f 编写于 作者: L Leon Romanovsky 提交者: Jason Gunthorpe

RDMA/ocrdma: Use PCI-ID as an identification in debugfs

In opposite to current implementation of identification based on device
name, PCI-ID identification provides stable names suitable for device
rename. Change ocrdma debugfs representation to use PCI-ID.
Signed-off-by: NLeon Romanovsky <leonro@mellanox.com>
Reviewed-by: NYuval Shaia <yuval.shaia@oracle.com>
Acked-by: NSelvin Xavier <selvin.xavier@broadcom.com>
Signed-off-by: NJason Gunthorpe <jgg@mellanox.com>
上级 9435ef4c
......@@ -760,12 +760,13 @@ static const struct file_operations ocrdma_dbg_ops = {
void ocrdma_add_port_stats(struct ocrdma_dev *dev)
{
const struct pci_dev *pdev = dev->nic_info.pdev;
if (!ocrdma_dbgfs_dir)
return;
/* Create post stats base dir */
dev->dir =
debugfs_create_dir(dev_name(&dev->ibdev.dev), ocrdma_dbgfs_dir);
dev->dir = debugfs_create_dir(pci_name(pdev), ocrdma_dbgfs_dir);
if (!dev->dir)
goto err;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册