Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 1406276c authored by Jan Beulich's avatar Jan Beulich Committed by Bjorn Helgaas
Browse files

PCI/MSI: Simplify populate_msi_sysfs()



Simplify populate_msi_sysfs() by

  - Swapping the order of the two allocations and storing the
    msi_dev_attr-derived pointer right after allocation, allowing the
    cleanup code to pick things up without extra effort.

  - Using kasprintf() instead of the kmalloc()/sprintf() pair.

Signed-off-by: default avatarJan Beulich <jbeulich@suse.com>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
Acked-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9ada07b1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment