Received: by 10.223.185.116 with SMTP id b49csp3205827wrg; Sun, 25 Feb 2018 16:53:10 -0800 (PST) X-Google-Smtp-Source: AH8x2270BGzqmd/YhatZMITFdWghXkjLmXyJcj5TwLf//2rn5HwuAVuk7BZs9lcOEpSPJINiNlj6 X-Received: by 2002:a17:902:b904:: with SMTP id bf4-v6mr8711731plb.195.1519606390618; Sun, 25 Feb 2018 16:53:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519606390; cv=none; d=google.com; s=arc-20160816; b=fiZm1J5wWoW+a8ALr2ApyaizO8gytDFVbLAUxXEDvr/WZbkg9s+dFL79eLhpmthoxz 3BvgV/uWnFJordIwOVpNwYUTeTxY/JCXQKt7YDC9NlU416cn3uqyNfslRpyzBOJZvj19 sDPmAIaI7RzK9nUDBRn52uZmP0ttwg/uC8G6mXwf5K6ahbGL65Gzp6pqpQye/szOVGK8 VaMY1GAE3PhRiItdAbd8XLuGNwQCJ2IOsa9OKUPBbbJx7tjo3LUC/uTC/r7prb12MPuU D0up74QWaSykXJCueOEP6EzC/61A486nhLyPQXHkEvyuYeF9KcuIw8i61ivT4RlVNWJE C0gQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=dwrQUvsqm6iDiVRIoSj0KU258Egtsxwi5hfXOitah8M=; b=tgLK8sQrfAu7IEIL2VNQFvykw2mOoHT1w/fzsXBi9XnDjkp8I/WUgoeix8NL1AxrbW LkY/1b6SyCH2btIBc2PAEPMTaaYV1kiYNncULHR1fLizKENV9JyPFYDcxpEFyJIaj49o 53Ay/ACicAPFuJUcn1qzpKFO+Ja385JOj9zQco9d++uzmMb993sahEtHdGi3r20W/Ja0 PREx7eUJ/e7wkDQU9GEfTzwGOL2WZHbVBEySqanak3s82BGjtITGVj8A4g+inNrvCA3z 1Ect0NSytulG3MH+zH/l7YyJAVOPlvDPe3jYFnOEuB1y3lLOsJxnIc/P9kAGFLeNeU0V aHlA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w16-v6si5766755plp.87.2018.02.25.16.52.56; Sun, 25 Feb 2018 16:53:10 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751937AbeBZAvv (ORCPT + 99 others); Sun, 25 Feb 2018 19:51:51 -0500 Received: from mail.cn.fujitsu.com ([183.91.158.132]:52068 "EHLO heian.cn.fujitsu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751904AbeBZAvs (ORCPT ); Sun, 25 Feb 2018 19:51:48 -0500 X-IronPort-AV: E=Sophos;i="5.43,368,1503331200"; d="scan'208";a="37242722" Received: from bogon (HELO cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 26 Feb 2018 08:51:46 +0800 Received: from G08CNEXCHPEKD02.g08.fujitsu.local (unknown [10.167.33.83]) by cn.fujitsu.com (Postfix) with ESMTP id 1CC1148AE761; Mon, 26 Feb 2018 08:51:47 +0800 (CST) Received: from localhost.localdomain (10.167.226.106) by G08CNEXCHPEKD02.g08.fujitsu.local (10.167.33.89) with Microsoft SMTP Server (TLS) id 14.3.361.1; Mon, 26 Feb 2018 08:51:47 +0800 Subject: Re: [PATCH v3 2/2] x86/apic: Replace common tools with new ones To: Andy Shevchenko CC: Linux Kernel Mailing List , , Thomas Gleixner , Ingo Molnar , , Baoquan He References: <20180223075430.12395-1-douly.fnst@cn.fujitsu.com> <20180223075430.12395-2-douly.fnst@cn.fujitsu.com> From: Dou Liyang Message-ID: <6bd94039-966d-6212-2afe-92f601d87421@cn.fujitsu.com> Date: Mon, 26 Feb 2018 08:51:45 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.167.226.106] X-yoursite-MailScanner-ID: 1CC1148AE761.AA15C X-yoursite-MailScanner: Found to be clean X-yoursite-MailScanner-From: douly.fnst@cn.fujitsu.com X-Spam-Status: No Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Andy, At 02/23/2018 08:40 PM, Andy Shevchenko wrote: > On Fri, Feb 23, 2018 at 9:54 AM, Dou Liyang 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<> + 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++; >> } >> } >