Received: by 10.192.165.148 with SMTP id m20csp5481913imm; Wed, 9 May 2018 05:52:56 -0700 (PDT) X-Google-Smtp-Source: AB8JxZr49e+BlX1vfZ7+ndsBIz9ZJUsMA+ALQl7dE19OkFlAO21fHPuD4yiTvI6v3GJRIkN23cXa X-Received: by 2002:a17:902:9890:: with SMTP id s16-v6mr45590939plp.132.1525870375965; Wed, 09 May 2018 05:52:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525870375; cv=none; d=google.com; s=arc-20160816; b=YGzyUAw+0VQK6Kmb/LENS2lCzgKaRy5Plnc/PhY2p0tT0tcZTaBKUbMHzzwwWDcXeq ObWmzZIeqX+L687h0m40BCF0o+tlEvCC3VpfHpbs5oLiexxcMplVOAKpNTEVsBDbx0ib eLEZfQ9IaIVlFcHYHjRpayS2lspKe19ndi9OCvCnA3Wk66X3zlKiBlrRdwHPcmZ7t4Vw 5CaKH96Mzgf1TN4jt+8SEsBGvj4N5TdIFWvQckv/qf7/X8mD6K4eSsSJxG30nJnppAvS FcwDgpKrB0vUTQ/IeafqU2Mc5gMqpWPR47DuRp18UsvsTCSUgx68e81Wf0lLqv493sHA AtHg== 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:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :arc-authentication-results; bh=m0TOV6HNllC2lBVjk1uh5TFfJY46coX5y1Aomeo360M=; b=hwUh2SBigzQscsBuSTnZsznQPo21eNWzgnzY48RirQHx1+XCr3GQSLH9oNC+81RJB/ gjjjt5wE0ulTEJfSujmA7j3SetB6EW5fH1uZr261y29TVNGdf+4fNQ4X2Y0+DuadIFE3 ZhyMWch0Af1D79khPoisH1xm6J7Db3D5Al6KdOsm5dFvALSNVjSRVgJR+z2vBQO+/RWQ qB/nHOLO45+l+4gr/zfpIxdmzUd/Mz6JAW1yooiNCPKG04zWqGRsaOEkr9uBdI84i7ny YaYIeYjrocMXuzj+NPJ9kaUoX74VsDsfCgFVEHoBo2V1UPJGL3slteerpVa5sOh4yxVS V7Ag== 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 30-v6si26585907plf.104.2018.05.09.05.52.40; Wed, 09 May 2018 05:52:55 -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; 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 S934764AbeEIMw3 (ORCPT + 99 others); Wed, 9 May 2018 08:52:29 -0400 Received: from mail.kernel.org ([198.145.29.99]:40008 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934328AbeEIMw2 (ORCPT ); Wed, 9 May 2018 08:52:28 -0400 Received: from gandalf.local.home (cpe-66-24-56-78.stny.res.rr.com [66.24.56.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 67C4421783; Wed, 9 May 2018 12:52:26 +0000 (UTC) Date: Wed, 9 May 2018 08:52:24 -0400 From: Steven Rostedt To: changbin.du@intel.com Cc: yamada.masahiro@socionext.com, michal.lkml@markovi.net, tglx@linutronix.de, mingo@redhat.com, akpm@linux-foundation.org, rdunlap@infradead.org, x86@kernel.org, lgirdwood@gmail.com, broonie@kernel.org, arnd@arndb.de, linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org Subject: Re: [PATCH v4 4/4] asm-generic: fix build error in fix_to_virt with CONFIG_CC_OPTIMIZE_FOR_DEBUGGING Message-ID: <20180509085224.34116e36@gandalf.local.home> In-Reply-To: <1525855396-7908-5-git-send-email-changbin.du@intel.com> References: <1525855396-7908-1-git-send-email-changbin.du@intel.com> <1525855396-7908-5-git-send-email-changbin.du@intel.com> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 9 May 2018 16:43:16 +0800 changbin.du@intel.com wrote: > From: Changbin Du > > With '-Og' optimization level, GCC would not optimize a count for a loop > as a constant value. But BUILD_BUG_ON() only accept compile-time constant > values. Let's use __fix_to_virt() to avoid the error. > > arch/arm/mm/mmu.o: In function `fix_to_virt': > /home/changbin/work/linux/./include/asm-generic/fixmap.h:31: undefined reference to `__compiletime_assert_31' > Makefile:1051: recipe for target 'vmlinux' failed > make: *** [vmlinux] Error 1 Perhaps we should put this patch ahead of patch 3. Why allow it to break? Anyway, besides that, I think the series looks good. For the series: Acked-by: Steven Rostedt (VMware) -- Steve > > Signed-off-by: Changbin Du > > --- > v2: use __fix_to_virt() to fix the issue. > --- > arch/arm/mm/mmu.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c > index e46a6a4..c08d74e 100644 > --- a/arch/arm/mm/mmu.c > +++ b/arch/arm/mm/mmu.c > @@ -1599,7 +1599,7 @@ static void __init early_fixmap_shutdown(void) > pte_t *pte; > struct map_desc map; > > - map.virtual = fix_to_virt(i); > + map.virtual = __fix_to_virt(i); > pte = pte_offset_early_fixmap(pmd_off_k(map.virtual), map.virtual); > > /* Only i/o device mappings are supported ATM */