All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Cc: kishon@ti.com, lpieralisi@kernel.org, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, mie@igel.co.jp, kw@linux.com,
	stable@vger.kernel.org
Subject: Re: [PATCH v2 2/5] tools: PCI: Fix parsing the return value of IOCTLs
Date: Wed, 24 Aug 2022 14:44:06 +0200	[thread overview]
Message-ID: <YwYdFt6sc7lZGRcg@kroah.com> (raw)
In-Reply-To: <20220824123010.51763-3-manivannan.sadhasivam@linaro.org>

On Wed, Aug 24, 2022 at 06:00:07PM +0530, Manivannan Sadhasivam wrote:
> "pci_endpoint_test" driver now returns 0 for success and negative error
> code for failure. So adapt to the change by reporting FAILURE if the
> return value is < 0, and SUCCESS otherwise.
> 
> Cc: stable@vger.kernel.org #5.10
> Fixes: 3f2ed8134834 ("tools: PCI: Add a userspace tool to test PCI endpoint")
> Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
> ---
>  tools/pci/pcitest.c | 41 +++++++++++++++++++++--------------------
>  1 file changed, 21 insertions(+), 20 deletions(-)
> 
> diff --git a/tools/pci/pcitest.c b/tools/pci/pcitest.c
> index 441b54234635..a4e5b17cc3b5 100644
> --- a/tools/pci/pcitest.c
> +++ b/tools/pci/pcitest.c
> @@ -18,7 +18,6 @@
>  
>  #define BILLION 1E9
>  
> -static char *result[] = { "NOT OKAY", "OKAY" };
>  static char *irq[] = { "LEGACY", "MSI", "MSI-X" };
>  
>  struct pci_test {
> @@ -54,9 +53,9 @@ static int run_test(struct pci_test *test)
>  		ret = ioctl(fd, PCITEST_BAR, test->barnum);
>  		fprintf(stdout, "BAR%d:\t\t", test->barnum);
>  		if (ret < 0)
> -			fprintf(stdout, "TEST FAILED\n");
> +			fprintf(stdout, "FAILED\n");
>  		else
> -			fprintf(stdout, "%s\n", result[ret]);
> +			fprintf(stdout, "SUCCESS\n");

Is this following the kernel TAP output rules?  If not, why not?  If so,
say that you are fixing that issue up in the changelog text.

thanks,

greg k-h

  reply	other threads:[~2022-08-24 12:44 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-24 12:30 [PATCH v2 0/5] pci_endpoint_test: Fix the return value of IOCTLs Manivannan Sadhasivam
2022-08-24 12:30 ` [PATCH v2 1/5] misc: pci_endpoint_test: Fix the return value of IOCTL Manivannan Sadhasivam
2024-08-02 11:44   ` Hrishikesh Deleep
2022-08-24 12:43   ` Greg KH
2022-08-24 14:25     ` Manivannan Sadhasivam
2022-08-24 12:30 ` [PATCH v2 2/5] tools: PCI: Fix parsing the return value of IOCTLs Manivannan Sadhasivam
2022-08-24 12:44   ` Greg KH [this message]
2022-08-24 14:28     ` Manivannan Sadhasivam
2022-11-01 14:15     ` Manivannan Sadhasivam
2022-11-01 17:11       ` Greg KH
2022-08-24 12:30 ` [PATCH v2 3/5] Documentation: PCI: endpoint: Use the correct return value of pcitest.sh Manivannan Sadhasivam
2022-08-24 12:30 ` [PATCH v2 4/5] misc: pci_endpoint_test: Remove unnecessary WARN_ON Manivannan Sadhasivam
2022-08-24 12:30 ` [PATCH v2 5/5] tools: PCI: Fix memory leak Manivannan Sadhasivam
2022-09-09 13:09 ` [PATCH v2 0/5] pci_endpoint_test: Fix the return value of IOCTLs Lorenzo Pieralisi
2022-11-01 14:03   ` Manivannan Sadhasivam

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=YwYdFt6sc7lZGRcg@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=kishon@ti.com \
    --cc=kw@linux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lpieralisi@kernel.org \
    --cc=manivannan.sadhasivam@linaro.org \
    --cc=mie@igel.co.jp \
    --cc=stable@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.