• Jacob Keller's avatar
    scsi: qedf: Use pci_get_dsn() · dbce64cb
    Jacob Keller authored
    Replace the open-coded implementation for reading the PCIe DSN with
    pci_get_dsn().
    
    The original code used a for-loop that looped over each of the 8 bytes
    and copied them into a temporary buffer. pci_get_dsn() uses two calls to
    pci_read_config_dword, and correctly bitwise ORs them into a u64. Thus,
    we can simplify the snprintf significantly using %016llX on a u64 value.
    Signed-off-by: default avatarJacob Keller <jacob.e.keller@intel.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    dbce64cb
qedf_main.c 105 KB