ntb.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Jon Mason <jdmason@kudzu.us>
To: Serge Semin <fancer.lancer@gmail.com>
Cc: Wang Qing <wangqing@vivo.com>, Dave Jiang <dave.jiang@intel.com>,
	Allen Hubbe <allenbh@gmail.com>,
	linux-ntb@googlegroups.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ntb: idt: fix error check in ntb_hw_idt.c
Date: Sun, 6 Dec 2020 18:25:44 -0500	[thread overview]
Message-ID: <20201206232544.GB11795@kudzu.us> (raw)
In-Reply-To: <20201110183340.77xcobfsnz43vsa2@mobilestation>

On Tue, Nov 10, 2020 at 09:33:40PM +0300, Serge Semin wrote:
> Hello Wang
> 
> On Fri, Nov 06, 2020 at 05:43:31PM +0800, Wang Qing wrote:
> > idt_create_dev never return NULL and fix smatch warning.
> 
> Thanks for submitting this. For the both changes
> Acked-by: Serge Semin <fancer.lancer@gmail.com>

Applied to the ntb branch.

Thanks,
Jon

> 
> They are mostly unrelated though. If they weren't trivial I'd have
> suggested to split them up into the dedicated patches. Since they
> aren't I suppose leaving the patch 'as is' is ok, unless the subsystem
> maintainer thinks differently.
> 
> -Sergey
> 
> > 
> > Signed-off-by: Wang Qing <wangqing@vivo.com>
> > ---
> >  drivers/ntb/hw/idt/ntb_hw_idt.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> > 
> > diff --git a/drivers/ntb/hw/idt/ntb_hw_idt.c b/drivers/ntb/hw/idt/ntb_hw_idt.c
> > index d54261f..e7a4c2a
> > --- a/drivers/ntb/hw/idt/ntb_hw_idt.c
> > +++ b/drivers/ntb/hw/idt/ntb_hw_idt.c
> > @@ -2511,7 +2511,7 @@ static int idt_init_dbgfs(struct idt_ntb_dev *ndev)
> >  	/* If the top directory is not created then do nothing */
> >  	if (IS_ERR_OR_NULL(dbgfs_topdir)) {
> >  		dev_info(&ndev->ntb.pdev->dev, "Top DebugFS directory absent");
> > -		return PTR_ERR(dbgfs_topdir);
> > +		return PTR_ERR_OR_ZERO(dbgfs_topdir);
> >  	}
> >  
> >  	/* Create the info file node */
> > @@ -2756,7 +2756,7 @@ static int idt_pci_probe(struct pci_dev *pdev,
> >  
> >  	/* Allocate the memory for IDT NTB device data */
> >  	ndev = idt_create_dev(pdev, id);
> > -	if (IS_ERR_OR_NULL(ndev))
> > +	if (IS_ERR(ndev))
> >  		return PTR_ERR(ndev);
> >  
> >  	/* Initialize the basic PCI subsystem of the device */
> > -- 
> > 2.7.4
> > 

      reply	other threads:[~2020-12-06 23:25 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-06  9:43 [PATCH] ntb: idt: fix error check in ntb_hw_idt.c Wang Qing
2020-11-10 18:33 ` Serge Semin
2020-12-06 23:25   ` 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=20201206232544.GB11795@kudzu.us \
    --to=jdmason@kudzu.us \
    --cc=allenbh@gmail.com \
    --cc=dave.jiang@intel.com \
    --cc=fancer.lancer@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-ntb@googlegroups.com \
    --cc=wangqing@vivo.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).