linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Yi Wang <wang.yi59@zte.com.cn>
Cc: bhelgaas@google.com, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, xue.zhihong@zte.com.cn,
	wang.liang82@zte.com.cn, Liao Pingfang <liao.pingfang@zte.com.cn>
Subject: Re: [PATCH] PCI: Replace kmalloc with kzalloc in the comment/message
Date: Tue, 7 Jul 2020 17:26:00 -0500	[thread overview]
Message-ID: <20200707222600.GA391475@bjorn-Precision-5520> (raw)
In-Reply-To: <1590714119-15744-1-git-send-email-wang.yi59@zte.com.cn>

On Fri, May 29, 2020 at 09:01:59AM +0800, Yi Wang wrote:
> From: Liao Pingfang <liao.pingfang@zte.com.cn>
> 
> Use kzalloc instead of kmalloc in the comment/message according to
> the previous kzalloc() call.
> 
> Signed-off-by: Liao Pingfang <liao.pingfang@zte.com.cn>

I would be happy to apply this, but this needs to show a connection
between Liao Pingfang and Yi Wang.

Ideally this patch would be sent directly by Liao Pingfang.  The
sender should at least appear in the Signed-off-by chain.  See
Documentation/process/submitting-patches.rst

> ---
>  drivers/pci/hotplug/ibmphp_pci.c | 2 +-
>  drivers/pci/setup-bus.c          | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/pci/hotplug/ibmphp_pci.c b/drivers/pci/hotplug/ibmphp_pci.c
> index e22d023..2d36992 100644
> --- a/drivers/pci/hotplug/ibmphp_pci.c
> +++ b/drivers/pci/hotplug/ibmphp_pci.c
> @@ -205,7 +205,7 @@ int ibmphp_configure_card(struct pci_func *func, u8 slotno)
>  								cur_func->next = newfunc;
>  
>  							rc = ibmphp_configure_card(newfunc, slotno);
> -							/* This could only happen if kmalloc failed */
> +							/* This could only happen if kzalloc failed */
>  							if (rc) {
>  								/* We need to do this in case bridge itself got configured properly, but devices behind it failed */
>  								func->bus = 1; /* To indicate to the unconfigure function that this is a PPB */
> diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c
> index bbcef1a..13c5a44 100644
> --- a/drivers/pci/setup-bus.c
> +++ b/drivers/pci/setup-bus.c
> @@ -151,7 +151,7 @@ static void pdev_sort_resources(struct pci_dev *dev, struct list_head *head)
>  
>  		tmp = kzalloc(sizeof(*tmp), GFP_KERNEL);
>  		if (!tmp)
> -			panic("pdev_sort_resources(): kmalloc() failed!\n");
> +			panic("%s: kzalloc() failed!\n", __func__);
>  		tmp->res = r;
>  		tmp->dev = dev;
>  
> -- 
> 2.9.5
> 

  reply	other threads:[~2020-07-07 22:26 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-29  1:01 [PATCH] PCI: Replace kmalloc with kzalloc in the comment/message Yi Wang
2020-07-07 22:26 ` Bjorn Helgaas [this message]
     [not found] <202007081722099680673@zte.com.cn>
2020-07-08 15:29 ` Bjorn Helgaas
2020-07-09  7:28 Yi Wang
2020-07-09 21:05 ` Bjorn Helgaas

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=20200707222600.GA391475@bjorn-Precision-5520 \
    --to=helgaas@kernel.org \
    --cc=bhelgaas@google.com \
    --cc=liao.pingfang@zte.com.cn \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=wang.liang82@zte.com.cn \
    --cc=wang.yi59@zte.com.cn \
    --cc=xue.zhihong@zte.com.cn \
    /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 NNTP newsgroup(s).