lkml.org 
[lkml]   [2012]   [Sep]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 12/20] Staging: ipack/bridges/tpci200: increment the reference counter of the pci_dev
    Date
    As indicated in the documentation of pci_dev_get.

    Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
    ---
    drivers/staging/ipack/bridges/tpci200.c | 3 +++
    1 file changed, 3 insertions(+)

    diff --git a/drivers/staging/ipack/bridges/tpci200.c b/drivers/staging/ipack/bridges/tpci200.c
    index 5150794..c1ce311 100644
    --- a/drivers/staging/ipack/bridges/tpci200.c
    +++ b/drivers/staging/ipack/bridges/tpci200.c
    @@ -672,6 +672,8 @@ static int tpci200_pciprobe(struct pci_dev *pdev,
    goto out_err_info;
    }

    + pci_dev_get(pdev);
    +
    /* Obtain a mapping of the carrier's PCI configuration registers */
    ret = pci_request_region(pdev, TPCI200_CFG_MEM_BAR,
    KBUILD_MODNAME " Configuration Memory");
    @@ -743,6 +745,7 @@ out_err_install:
    out_err_ioremap:
    pci_release_region(pdev, TPCI200_CFG_MEM_BAR);
    out_err_pci_request:
    + pci_dev_put(pdev);
    kfree(tpci200->info);
    out_err_info:
    kfree(tpci200);
    --
    1.7.10.4
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2012-09-10 11:41    [W:5.478 / U:0.480 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site