lkml.org 
[lkml]   [2014]   [Nov]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch 09/16] genirq: Add generic msi irq domain support
On 2014/11/18 22:24, Thomas Gleixner wrote:
> On Tue, 18 Nov 2014, Yun Wu (Abel) wrote:
>> On 2014/11/18 20:49, Jiang Liu wrote:
>>>>> + ret = irq_domain_alloc_irqs_parent(domain, virq, nr_irqs, arg);
>>>>> + if (ret < 0)
>>>>> + return ret;
>>>>> +
>>>>> + for (i = 0; i < nr_irqs; i++) {
>>>>> + ret = ops->msi_init(domain, info, virq + i, hwirq + i, arg);
>>>>> + if (ret < 0) {
>>>>> + if (ops->msi_free) {
>>>>> + for (i--; i > 0; i--)
>>>>
>>>> while (i--) ?
>
> The allocation for 'i' failed. So we don't free i. You missed the real
> bug here:
>
>>>>> + for (i--; i > 0; i--)
>
> Must be i >= 0.
Hi Thomas,
You will take care of this bug, right? Or should I send a patch
for it?
Regards!
Gerry


\
 
 \ /
  Last update: 2014-11-20 04:01    [W:0.139 / U:0.456 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site