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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2F3CEC433EF for ; Fri, 24 Jun 2022 12:57:17 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C264A8E021E; Fri, 24 Jun 2022 08:57:16 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id BADF78E020E; Fri, 24 Jun 2022 08:57:16 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A2AE28E021E; Fri, 24 Jun 2022 08:57:16 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 8C2088E020E for ; Fri, 24 Jun 2022 08:57:16 -0400 (EDT) Received: from smtpin07.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 5E2E92152D for ; Fri, 24 Jun 2022 12:57:16 +0000 (UTC) X-FDA: 79613130072.07.1F87A48 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf20.hostedemail.com (Postfix) with ESMTP id C1DF71C0030 for ; Fri, 24 Jun 2022 12:57:15 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 4F0BFB8269B; Fri, 24 Jun 2022 12:57:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id F1F25C34114; Fri, 24 Jun 2022 12:57:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1656075433; bh=CkbPmKY9WJZ0/Gc9GipoMphpgpeeU3MibSTPPDN8btk=; h=Date:From:To:Cc:Subject:Reply-To:References:In-Reply-To:From; b=oNpCPDIURzyi3XlL7/x6Q35cpQfA4M6fmTU4+1+o5tkQV+RJ0yUHgaOs3oaT/idor LUBeRRl0zuKRoK8P2yQhRlYJKHE4LFNwo5CC6Hg6e7zBmKQKM0IQ/KdtpvDWi1SAgo +tfb1bXfEcv7/I6ZBp9i2Lam43htpuMexzIVycDRbwp2GT6yxxhpYDIgYvDeYtFeRn d06gpyIiU7qQesPaMhTnHE+udgFRvJ0ZcWeBiOtAsyu164V+FjbYATElrDKgYT3nI0 uBgyIxw4F+N1m07/S0QMOy+udUrHdz+WTnO2YjZmXtlWjBYubrG+cDt/+t73CQk4wh ZsHJ9/11QkEJw== Received: by paulmck-ThinkPad-P17-Gen-1.home (Postfix, from userid 1000) id 9841A5C04B3; Fri, 24 Jun 2022 05:57:12 -0700 (PDT) Date: Fri, 24 Jun 2022 05:57:12 -0700 From: "Paul E. McKenney" To: Christophe Leroy Cc: kernel test robot , Frederic Weisbecker , "kbuild-all@lists.01.org" , Linux Memory Management List , Nicolas Saenz Julienne Subject: Re: [linux-next:master 4204/5575] arch/powerpc/kernel/interrupt.c:542:55: error: suggest braces around empty body in an 'if' statement Message-ID: <20220624125712.GS1790663@paulmck-ThinkPad-P17-Gen-1> Reply-To: paulmck@kernel.org References: <202206231654.cuANhsQq-lkp@intel.com> <20220624025240.GM1790663@paulmck-ThinkPad-P17-Gen-1> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656075436; h=from:from:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=CF1L1unKv0k/58xjsHezwXKJgBlYvkFiAFqhhwvAtM8=; b=0c+dns7veC+rkGLovjsMLil+btyEK80W/tqixtPnUgsYYemYgFmOcrD3+Rn4kskDp3B+I8 taAxJdUVIkvHDnL+ZbBSw9NHxaNAmz59rbz7zS2tlv9EcF83kYsbQpAGp8z3CWhqKPyNEf wUPppW+CqdlqAXOmGUdSiIINMPLWvlE= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656075436; a=rsa-sha256; cv=none; b=NRmRI++LKn7/WGk6VR7HZ87gPMkY8RJc+V8Iu8mXQXtRSQ+/AeETqoVMWpAR9UiIoRlG+t knWYBPKwj5x3EYk/sz+Grmeg62MPrdNhrtiYZdEQwYbwc8KOiP5SrsGMxNpBrFBo/pvWUF 4PFcIDD8AQ/TyyZlrL1axrQOAZTVBD8= ARC-Authentication-Results: i=1; imf20.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=oNpCPDIU; spf=pass (imf20.hostedemail.com: domain of "SRS0=JZTa=W7=paulmck-ThinkPad-P17-Gen-1.home=paulmck@kernel.org" designates 145.40.68.75 as permitted sender) smtp.mailfrom="SRS0=JZTa=W7=paulmck-ThinkPad-P17-Gen-1.home=paulmck@kernel.org"; dmarc=pass (policy=none) header.from=kernel.org X-Rspam-User: Authentication-Results: imf20.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=oNpCPDIU; spf=pass (imf20.hostedemail.com: domain of "SRS0=JZTa=W7=paulmck-ThinkPad-P17-Gen-1.home=paulmck@kernel.org" designates 145.40.68.75 as permitted sender) smtp.mailfrom="SRS0=JZTa=W7=paulmck-ThinkPad-P17-Gen-1.home=paulmck@kernel.org"; dmarc=pass (policy=none) header.from=kernel.org X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: C1DF71C0030 X-Stat-Signature: 6die8jac4bn5b63q7rnyeuca5b4zzpp5 X-HE-Tag: 1656075435-514657 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Fri, Jun 24, 2022 at 05:47:54AM +0000, Christophe Leroy wrote: > > > Le 24/06/2022 à 04:52, Paul E. McKenney a écrit : > > On Thu, Jun 23, 2022 at 04:50:49PM +0800, kernel test robot wrote: > >> tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master > >> head: 08897940f458ee55416cf80ab13d2d8b9f20038e > >> commit: 620ac34fef9e21aa2fd4aed6e01eed2e4fc605d4 [4204/5575] context_tracking: Convert state to atomic_t > >> config: powerpc-mgcoge_defconfig (https://download.01.org/0day-ci/archive/20220623/202206231654.cuANhsQq-lkp@intel.com/config) > >> compiler: powerpc-linux-gcc (GCC) 11.3.0 > >> reproduce (this is a W=1 build): > >> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross > >> chmod +x ~/bin/make.cross > >> # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=620ac34fef9e21aa2fd4aed6e01eed2e4fc605d4 > >> git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git > >> git fetch --no-tags linux-next master > >> git checkout 620ac34fef9e21aa2fd4aed6e01eed2e4fc605d4 > >> # save the config file > >> mkdir build_dir && cp config build_dir/.config > >> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=powerpc SHELL=/bin/bash arch/powerpc/kernel/ > >> > >> If you fix the issue, kindly add following tag where applicable > >> Reported-by: kernel test robot > >> > >> All errors (new ones prefixed by >>): > >> > >> arch/powerpc/kernel/interrupt.c: In function 'interrupt_exit_kernel_prepare': > >>>> arch/powerpc/kernel/interrupt.c:542:55: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body] > >> 542 | CT_WARN_ON(ct_state() == CONTEXT_USER); > >> | ^ > >> cc1: all warnings being treated as errors > > > > This is a bit odd, and perhaps should instead be written as follows: > > > > WARN_ON_ONCE(TRAP(regs) != INTERRUPT_PROGRAM && CT_WARN_ON(ct_state() == CONTEXT_USER)); > > > > But this code has been around for awhile, and was not changed by the > > commit called out above. I will let the PowerPC guys choose what they > > want to do with it. > > > The commit called out above did a change. It added: > > #define CT_WARN_ON(cond) > > When CONFIG_CONTEXT_TRACKING_USER is not defined > > > That change is wrong, it should be: > > #define CT_WARN_ON(cond) do { } while (0) Ah, thank you. Will fix. Thanx, Paul