[PATCH v2] [02/10] pasemi_mac: Stop using the pci config space accessors for register read/writes
Stephen Rothwell
sfr at canb.auug.org.au
Fri Aug 24 14:05:31 EST 2007
On Thu, 23 Aug 2007 13:13:10 -0500 Olof Johansson <olof at lixom.net> wrote:
>
> out:
> - pci_dev_put(mac->iob_pdev);
> -out_put_dma_pdev:
> - pci_dev_put(mac->dma_pdev);
> -out_free_netdev:
> + if (mac->iob_pdev)
> + pci_dev_put(mac->iob_pdev);
> + if (mac->dma_pdev)
> + pci_dev_put(mac->dma_pdev);
It is not documented as such (as far as I can see), but pci_dev_put is
safe to call with NULL. And there are other places in the kernel that
explicitly use that fact.
--
Cheers,
Stephen Rothwell sfr at canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20070824/15e2285e/attachment.pgp>
More information about the Linuxppc-dev
mailing list