mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Dongliang Mu <dzm91@hust.edu.cn>
To: Mark Brown <broonie@kernel.org>
Cc: Li Ningke <lnk_01@hust.edu.cn>,
	hust-os-kernel-patches@googlegroups.com,
	linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org,
	Dan Carpenter <error27@gmail.com>
Subject: Re: [PATCH] spi: davinci: Remove dead code in `davinci_spi_probe()`
Date: Wed, 26 Apr 2023 09:50:26 +0800	[thread overview]
Message-ID: <1488abfa-9a0e-970b-e074-11842a6c6413@hust.edu.cn> (raw)
In-Reply-To: <ed846afc-7155-4998-9a8d-e9d9e8aaf8e2@sirena.org.uk>


On 2023/4/24 23:52, Mark Brown wrote:
> On Mon, Apr 24, 2023 at 08:03:42PM +0800, Dongliang Mu wrote:
>> On 2023/4/24 19:48, Mark Brown wrote:
>>> Is that check valid?  0 was a valid interrupt for some architectures...
>> We just follow the comments of platform_get_irq().
>>   * Gets an IRQ for a platform device and prints an error message if finding
>> the
>>   * IRQ fails. Device drivers should check the return value for errors so as
>> to
>>   * not pass a negative integer value to the request_irq() APIs.
> I'm not sure that's universally true yet, though there were some moves
> to try to get us there.  arm, where this driver is used, was one of the
> platforms with 0 as a valid interrupt.

Hi Brown,

First, we're sorry about the fact that our internal robot(beta) made a 
mistake and sent our testing message to LKML. We have fixed the 
incorrect logic.

Second, from code review of platform_get_irq / 
platform_get_irq_optional, it would warn IRQ 0 as an invalid IRQ number.

out:
	if (WARN(!ret, "0 is an invalid IRQ number\n"))
		return -EINVAL;
	return ret;

Dongliang Mu


  reply	other threads:[~2023-04-26  1:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-23  3:24 Li Ningke
2023-04-24 11:48 ` Mark Brown
2023-04-24 12:03   ` Dongliang Mu
2023-04-24 15:52     ` Mark Brown
2023-04-26  1:50       ` Dongliang Mu [this message]
2023-04-26 14:13         ` Mark Brown
2023-04-26 15:07           ` Dongliang Mu

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=1488abfa-9a0e-970b-e074-11842a6c6413@hust.edu.cn \
    --to=dzm91@hust.edu.cn \
    --cc=broonie@kernel.org \
    --cc=error27@gmail.com \
    --cc=hust-os-kernel-patches@googlegroups.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=lnk_01@hust.edu.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

all inboxes | Powered by JetHome®