ntb.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Jon Mason <jdmason@kudzu.us>
To: Kaige Li <likaige@loongson.cn>
Cc: Sanjay R Mehta <sanju.mehta@amd.com>,
	Shyam Sundar S K <Shyam-sundar.S-k@amd.com>,
	Dave Jiang <dave.jiang@intel.com>,
	Allen Hubbe <allenbh@gmail.com>,
	linux-ntb@googlegroups.com, linux-kernel@vger.kernel.org
Subject: Re: [RESEND] NTB: hw: amd: fix an issue about leak system resources
Date: Mon, 24 Aug 2020 10:52:47 -0400	[thread overview]
Message-ID: <20200824145246.GB27238@kudzu.us> (raw)
In-Reply-To: <1597111197-28563-1-git-send-email-likaige@loongson.cn>

On Tue, Aug 11, 2020 at 09:59:57AM +0800, Kaige Li wrote:
> The related system resources were not released when pci_set_dma_mask(),
> pci_set_consistent_dma_mask(), or pci_iomap() return error in the
> amd_ntb_init_pci() function. Add pci_release_regions() to fix it.
> 
> Signed-off-by: Kaige Li <likaige@loongson.cn>

Pulled into my ntb branch.  I added:
    Fixes: a1b3695820aa ("NTB: Add support for AMD PCI-Express Non-Transparent Bridge")

Thanks,
Jon

> ---
> 
> changed commit massage.
> 
>  drivers/ntb/hw/amd/ntb_hw_amd.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/ntb/hw/amd/ntb_hw_amd.c b/drivers/ntb/hw/amd/ntb_hw_amd.c
> index 88e1db6..71428d8 100644
> --- a/drivers/ntb/hw/amd/ntb_hw_amd.c
> +++ b/drivers/ntb/hw/amd/ntb_hw_amd.c
> @@ -1203,6 +1203,7 @@ static int amd_ntb_init_pci(struct amd_ntb_dev *ndev,
>  
>  err_dma_mask:
>  	pci_clear_master(pdev);
> +	pci_release_regions(pdev);
>  err_pci_regions:
>  	pci_disable_device(pdev);
>  err_pci_enable:
> -- 
> 2.1.0
> 

      reply	other threads:[~2020-08-24 14:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-11  1:59 [RESEND] NTB: hw: amd: fix an issue about leak system resources Kaige Li
2020-08-24 14:52 ` Jon Mason [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200824145246.GB27238@kudzu.us \
    --to=jdmason@kudzu.us \
    --cc=Shyam-sundar.S-k@amd.com \
    --cc=allenbh@gmail.com \
    --cc=dave.jiang@intel.com \
    --cc=likaige@loongson.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-ntb@googlegroups.com \
    --cc=sanju.mehta@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).