From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.3 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B42ABC433DF for ; Fri, 22 May 2020 02:32:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8DCA62078B for ; Fri, 22 May 2020 02:32:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727020AbgEVCcp (ORCPT ); Thu, 21 May 2020 22:32:45 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:44046 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726925AbgEVCcp (ORCPT ); Thu, 21 May 2020 22:32:45 -0400 Received: from DGGEMS408-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 52FBB1F03C6E47C4B648; Fri, 22 May 2020 10:32:43 +0800 (CST) Received: from [127.0.0.1] (10.173.222.58) by DGGEMS408-HUB.china.huawei.com (10.3.19.208) with Microsoft SMTP Server id 14.3.487.0; Fri, 22 May 2020 10:32:37 +0800 Subject: Re: [kvm-unit-tests PATCH 1/6] arm64: microbench: get correct ipi recieved num To: Zenghui Yu , , , CC: , , References: <20200517100900.30792-1-wangjingyi11@huawei.com> <20200517100900.30792-2-wangjingyi11@huawei.com> <8e011659-4e4d-7312-4466-5ed3ea54cc9b@huawei.com> From: Jingyi Wang Message-ID: <8b9d51f2-3906-9e0a-38ae-564424c38ff5@huawei.com> Date: Fri, 22 May 2020 10:32:25 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: <8e011659-4e4d-7312-4466-5ed3ea54cc9b@huawei.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Originating-IP: [10.173.222.58] X-CFilter-Loop: Reflected Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On 5/21/2020 10:00 PM, Zenghui Yu wrote: > On 2020/5/17 18:08, Jingyi Wang wrote: >> If ipi_exec() fails because of timeout, we shouldn't increase >> the number of ipi received. >> >> Signed-off-by: Jingyi Wang >> --- >>   arm/micro-bench.c | 4 +++- >>   1 file changed, 3 insertions(+), 1 deletion(-) >> >> diff --git a/arm/micro-bench.c b/arm/micro-bench.c >> index 4612f41..ca022d9 100644 >> --- a/arm/micro-bench.c >> +++ b/arm/micro-bench.c >> @@ -103,7 +103,9 @@ static void ipi_exec(void) >>       while (!ipi_received && tries--) >>           cpu_relax(); >> -    ++received; >> +    if (ipi_recieved) > > I think you may want *ipi_received* ;-) Otherwise it can not even > compile! > >> +        ++received; >> + >>       assert_msg(ipi_received, "failed to receive IPI in time, but >> received %d successfully\n", received); >>   } > > With this fixed, this looks good to me, > > Reviewed-by: Zenghui Yu > > > Thanks. > > . This variable name is modified in the next patch, so I ignored that mistake, thanks. Thanks, Jingyi