Received: by 10.213.65.68 with SMTP id h4csp3573273imn; Tue, 10 Apr 2018 00:49:00 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+oI7+PkcE1ypwIQ1tixht+8c1hj2DgdkR9xFCkOcmVXFmHf2p25Aj57H4oJhTJzFnakpXk X-Received: by 2002:a17:902:8d98:: with SMTP id v24-v6mr42110146plo.21.1523346540167; Tue, 10 Apr 2018 00:49:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523346540; cv=none; d=google.com; s=arc-20160816; b=KdWFqFFASMFYjQfqEeuozDwNWfv8025RBjKTafBajiInElIGxEi4aw+gVdhpyXZUCm yeDVfXx6WJXkup3Leyqvx8ccQinTUKqIGxPQECMIGqoRH+S3emG7CcAqsmQzZSQzGRDh HDvfs4yPgHT/fhlJjh56uyehza4ch4Fe3AyviI/AA8os6lhd8vwy4Nwcu0j68sogtb+g 4zj4zOE0+/9qv7DolNJCzeQ4a1uQ34NRTwjMgRhMNNyuXfjDaCFGnDg9lcOec5V+fkVF lZLCq4WBqc+YpEWqo9fKqsYQ8z3M9vfKvHXf7m65/wXvK7GP33TSEfecA+Amb3gS65Me NmpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature:dkim-signature :arc-authentication-results; bh=b9yhLSbqNuG6p2EJCtAGB/5k3HIno6lMNjimcKyR7Xg=; b=b1MoM+yjjCEW5/CKmy6Sq6f4ki7jlrQjK01imWtCcXi05vUweYC9Qs/NWpcDk72pt2 SMr3BAYQVOlQAdc602/wyRQvnjxzG2DBsGa6FlJ549/lXaR3HCyDp/6fW4P9E21q32wm beW79UUz6BLN0UBULP4hrnAAGJmVqI7xHYubsCd62cygmNmORZ7uXnfyGVRd+FbHUekn q7rCEgdgas2JDB1OJP3Zms/3lFdhfEf1N9+dhBPonwz9zMEHHd/jQGeIjFMOatSkM0n3 m2gjPumIwrHTsmi3VC4zT0PTO2xncWAR5uXmYbqnjKKezW0wZe38AbXsf7AGdFkkNhrs 4deg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=DdYpKOKM; dkim=pass header.i=@codeaurora.org header.s=default header.b=ma4Mk/A0; 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 65si1389743pgj.618.2018.04.10.00.48.23; Tue, 10 Apr 2018 00:49:00 -0700 (PDT) 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; dkim=pass header.i=@codeaurora.org header.s=default header.b=DdYpKOKM; dkim=pass header.i=@codeaurora.org header.s=default header.b=ma4Mk/A0; 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 S1752242AbeDJHpt (ORCPT + 99 others); Tue, 10 Apr 2018 03:45:49 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:56978 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751874AbeDJHpr (ORCPT ); Tue, 10 Apr 2018 03:45:47 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 49E3E60F6C; Tue, 10 Apr 2018 07:45:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1523346347; bh=UH0YMoFf+o0i3vxfTRCN2KNzy2cZx8PSyI2fTvHwdmQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=DdYpKOKMGEWLLQdpBQUl8YB8BRPhi5oSbXlB/WpgG8Tq2QHk0NYchS1U/784jlQJ7 5wXWdeH55LHnNgJPEcLO0MHX9WY5Fi53yaE9b8KErMGU8sOW4NuVfZOIdsd5Y06L64 0uOaO4KWDQ7rkr4gZkLUiWWtNSybNdhYu0xUH8sg= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from mail.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id 76F2F601E8; Tue, 10 Apr 2018 07:45:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1523346346; bh=UH0YMoFf+o0i3vxfTRCN2KNzy2cZx8PSyI2fTvHwdmQ=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=ma4Mk/A0Yb7yCzZ+aJ90WUvtKZ6R3an4KYod4mkMR0pnxAdJ6nvUrE6aa6jI+5MH0 CEDPxUG7G2kl42Bx0RMF11EOsUKmQ8Ry3bR4sWogcLaZhr+XMN/v5hbesfyur3dwjh zyTKIKegRaHYfoHG9IW/58lZv6q9TzjsEm75a5/s= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 10 Apr 2018 15:45:46 +0800 From: yuankuiz@codeaurora.org To: linux-pm@vger.kernel.org Cc: rjw@rjwysocki.net, fweisbec@gmail.com, peterz@infradead.org, tglx@linutronix.de, mingo@kernel.org, len.brown@intel.com, linux-kernel@vger.kernel.org Subject: [PATCH] [PATCH] time: tick-sched: use bool for tick_stopped In-Reply-To: <891d4f632fbff5052e11f2d0b6fac35d@codeaurora.org> References: <891d4f632fbff5052e11f2d0b6fac35d@codeaurora.org> Message-ID: <9ee70560651fefffcc61949d8a37315d@codeaurora.org> X-Sender: yuankuiz@codeaurora.org User-Agent: Roundcube Webmail/1.2.5 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: John Zhao Variable tick_stopped returned by tick_nohz_tick_stopped can only be true / false values. Since the return type of the tick_nohz_tick_stopped is also bool, variable tick_stopped nice to have data type as bool in place of int. Moreover, the executed instructions cost could be minimal without potiential data type conversion. Signed-off-by: John Zhao --- kernel/time/tick-sched.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/time/tick-sched.h b/kernel/time/tick-sched.h index 6de959a..4d34309 100644 --- a/kernel/time/tick-sched.h +++ b/kernel/time/tick-sched.h @@ -48,8 +48,8 @@ struct tick_sched { unsigned long check_clocks; enum tick_nohz_mode nohz_mode; + bool tick_stopped : 1; unsigned int inidle : 1; - unsigned int tick_stopped : 1; unsigned int idle_active : 1; unsigned int do_timer_last : 1; unsigned int got_idle_tick : 1;