lkml.org 
[lkml]   [2018]   [Feb]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v3 2/2] x86/apic: Replace common tools with new ones
From
Date
Hi Andy,

At 02/23/2018 08:40 PM, Andy Shevchenko wrote:
> On Fri, Feb 23, 2018 at 9:54 AM, Dou Liyang <douly.fnst@cn.fujitsu.com> wrote:
>> The pending interrupt check code is old, update the following code.
>>
>> -Replace for() with for_each_set_bit()
>
>> - for (j = 31; j >= 0; j--) {
>> - if (value & (1<<j)) {
>> + for_each_set_bit(j, &value, 32) {
>
> for_each_set_bit(), mind 'set' part, is equivalent to for-if pair...
>
>> + if (j) {
>
> ...here you just exclude bit 0 from consideration by unknown reason.
>

Oops! my fault, will modify it.

Thanks,
dou

>> ack_APIC_irq();
>> acked++;
>> }
>> }
>


\
 
 \ /
  Last update: 2018-02-26 01:52    [W:0.060 / U:0.300 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site