aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorJeremy Sowden <[email protected]>2019-05-21 11:35:20 +0100
committerGreg Kroah-Hartman <[email protected]>2019-05-22 14:44:21 +0200
commita986d796395c18e607703af11e1afc1d3a8a5908 (patch)
tree4d439b5a9ee614a6247b9660a5ad39ff46050fe6 /tools/perf/scripts/python
parentd8ac35939632f25d6b1465a921f8a4d63064e3ae (diff)
staging: kpc2000: added a helper to get struct kp2000_device from struct device.
The attribute call-backs all use the same formula to get the pcard from dev: struct pci_dev *pdev = to_pci_dev(dev); struct kp2000_device *pcard; if (!pdev) return -ENXIO; pcard = pci_get_drvdata(pdev); if (!pcard) return -ENXIO; Added a function to reduce the duplicated code. Signed-off-by: Jeremy Sowden <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions