mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-01 22:54:01 +00:00
scsi: mvumi: Use pci_dev_id() to simplify the code
PCI core API pci_dev_id() can be used to get the BDF number for a PCI device. We don't need to compose it mannally. Use pci_dev_id() to simplify the code a little bit. Signed-off-by: Jialin Zhang <zhangjialin11@huawei.com> Link: https://lore.kernel.org/r/20230815025419.3523236-2-zhangjialin11@huawei.com Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
parent
517f8eb3fa
commit
48e590218d
1 changed files with 1 additions and 1 deletions
|
@ -2490,7 +2490,7 @@ static int mvumi_probe_one(struct pci_dev *pdev, const struct pci_device_id *id)
|
|||
|
||||
mhba->pdev = pdev;
|
||||
mhba->shost = host;
|
||||
mhba->unique_id = pdev->bus->number << 8 | pdev->devfn;
|
||||
mhba->unique_id = pci_dev_id(pdev);
|
||||
|
||||
ret = mvumi_init_fw(mhba);
|
||||
if (ret)
|
||||
|
|
Loading…
Reference in a new issue