From: Alexey Kardashevskiy <aik@ozlabs.ru>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: "Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>,
"Cédric Le Goater" <clg@kaod.org>,
"Frederic Barrat" <fbarrat@linux.ibm.com>,
"Michal Suchánek" <msuchanek@suse.de>,
"Oliver O'Halloran" <oohall@gmail.com>,
"Marc Zyngier" <maz@kernel.org>,
"Thomas Gleixner" <tglx@linutronix.de>,
"linux-arm Mailing List" <linux-arm-kernel@lists.infradead.org>,
"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
"maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)"
<x86@kernel.org>,
"open list:LINUX FOR POWERPC PA SEMI PWRFICIENT"
<linuxppc-dev@lists.ozlabs.org>
Subject: Re: [PATCH kernel v4 2/8] genirq/irqdomain: Clean legacy IRQ allocation
Date: Tue, 24 Nov 2020 21:56:36 +1100 [thread overview]
Message-ID: <38b803db-2d67-dfa0-7e7b-e4ce816576ad@ozlabs.ru> (raw)
In-Reply-To: <CAHp75VfV4mG23C9Ep1vNLk2oBjB=LTQGyU=fhWPhw4PX-Ci-7A@mail.gmail.com>
On 11/24/20 8:19 PM, Andy Shevchenko wrote:
> On Tue, Nov 24, 2020 at 8:20 AM Alexey Kardashevskiy <aik@ozlabs.ru> wrote:
>>
>> There are 10 users of __irq_domain_alloc_irqs() and only one - IOAPIC -
>> passes realloc==true. There is no obvious reason for handling this
>> specific case in the generic code.
>>
>> This splits out __irq_domain_alloc_irqs_data() to make it clear what
>> IOAPIC does and makes __irq_domain_alloc_irqs() cleaner.
>>
>> This should cause no behavioral change.
>
>> + ret = __irq_domain_alloc_irqs_data(domain, virq, nr_irqs, node, arg, affinity);
>> + if (ret <= 0)
>> goto out_free_desc;
>
> Was or wasn't 0 considered as error code previously?
Oh. I need to clean this up, the idea is since this does not allocate
IRQs, this should return error code and not an irq, I'll make this explicit.
>
>> return virq;
>
>> out_free_desc:
>> irq_free_descs(virq, nr_irqs);
>> return ret;
>
--
Alexey
next prev parent reply other threads:[~2020-11-24 10:56 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-24 6:17 [PATCH kernel v4 0/8] genirq/irqdomain: Add reference counting to IRQs Alexey Kardashevskiy
2020-11-24 6:17 ` [PATCH kernel v4 1/8] genirq/ipi: Simplify irq_reserve_ipi Alexey Kardashevskiy
2020-11-24 16:54 ` Cédric Le Goater
2020-11-24 6:17 ` [PATCH kernel v4 2/8] genirq/irqdomain: Clean legacy IRQ allocation Alexey Kardashevskiy
2020-11-24 9:19 ` Andy Shevchenko
2020-11-24 10:56 ` Alexey Kardashevskiy [this message]
2020-11-30 21:41 ` Thomas Gleixner
2020-11-24 6:17 ` [PATCH kernel v4 3/8] genirq/irqdomain: Drop unused realloc parameter from __irq_domain_alloc_irqs Alexey Kardashevskiy
2020-11-24 6:17 ` [PATCH kernel v4 4/8] genirq: Free IRQ descriptor via embedded kobject Alexey Kardashevskiy
2020-11-24 6:17 ` [PATCH kernel v4 5/8] genirq: Add free_irq hook for IRQ descriptor and use for mapping disposal Alexey Kardashevskiy
2020-11-30 22:18 ` Thomas Gleixner
2020-11-30 22:33 ` Thomas Gleixner
2020-11-24 6:17 ` [PATCH kernel v4 6/8] genirq/irqdomain: Move hierarchical IRQ cleanup to kobject_release Alexey Kardashevskiy
2020-11-24 8:12 ` kernel test robot
2020-11-30 23:13 ` Thomas Gleixner
2020-11-24 6:17 ` [PATCH kernel v4 7/8] genirq/irqdomain: Reference irq_desc for already mapped irqs Alexey Kardashevskiy
2020-11-24 6:17 ` [PATCH kernel v4 8/8] powerpc/pci: Remove LSI mappings on device teardown Alexey Kardashevskiy
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=38b803db-2d67-dfa0-7e7b-e4ce816576ad@ozlabs.ru \
--to=aik@ozlabs.ru \
--cc=andy.shevchenko@gmail.com \
--cc=clg@kaod.org \
--cc=fbarrat@linux.ibm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=maz@kernel.org \
--cc=msuchanek@suse.de \
--cc=oohall@gmail.com \
--cc=tglx@linutronix.de \
--cc=x86@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 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).