Received: by 2002:a25:b794:0:0:0:0:0 with SMTP id n20csp2751249ybh; Mon, 5 Aug 2019 06:17:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqz1gdZHxQn+WZar2cnPz1eLc39EJw9idKrGgPJPAc5uRKaxo2Kd3E+XLfVsHMNC3M4/DBT+ X-Received: by 2002:a62:1444:: with SMTP id 65mr71969504pfu.145.1565011022824; Mon, 05 Aug 2019 06:17:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565011022; cv=none; d=google.com; s=arc-20160816; b=BK6ELFzpFajWtD1Uuf9jsRm9dsGINsar0QsolEXUgdiZVIVJSGqp+Oi9T/T1FgtoN0 Mtyh4K0o+DYxPMJZUKO/qkf32TDO6vyVGqIgFG6RPuLmldDOh7RuOEOMrVwnm6KMv1A2 y/IWsbWXUkTE8ThGGXETry4lzRNSnOo4loXoEjtnLrCeM77nI/KAHos9w3Mu3Bk/TL00 1sRIMqiQixMb1IKo9j5NrmlZEXCZk3Rf+Kgy+43fQ9dlgWT49n5pG4ZAbtBZLdsLyvwn j0eC7OYafvvLHY/3uxowQ7XxxvRCWYD1PDZwmQbNyBodO0X0fmtbNt35IjycDQPMkhMZ Q3gg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=vPGgoeC6iUvkTwhpOFEJlLVxvfhZaqwG1SHyR3iP980=; b=I8emYFDetILIQDJNOQSu+YKtDSIAo9nlUqP2EEjysJtUAwptwIl3mfNP2jP+x++OaW cc8zm/TIAFy/fbaOZyV7JLiggoYPfWm/2moSz6C18lzhWiLND5Oe0LB7PdnKxEqqFXHh CwSq0qz8VgnwdP/vBp0sDGWl62Fluur1i8gxnyKzYkPcJt9aQ8SfkqFnxZAdU3VsQc5r UWtQdJut0zGz+BpQpFz98vx4QCSP43tzRXMBb9HOFmYAYy8OoewCrMvS21x3HTvmgKMn BXPOgLaoM1QxQ1cLzhCFFG60ZPDbSMEB29q7apH/1GLeFikcBkyNy+Mz0p/EAytnnQwF l/7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ZyQPSFyy; 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 n1si42882900pgn.77.2019.08.05.06.16.47; Mon, 05 Aug 2019 06:17:02 -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=@kernel.org header.s=default header.b=ZyQPSFyy; 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 S1729557AbfHENGX (ORCPT + 99 others); Mon, 5 Aug 2019 09:06:23 -0400 Received: from mail.kernel.org ([198.145.29.99]:42978 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729073AbfHENGT (ORCPT ); Mon, 5 Aug 2019 09:06:19 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 BF840206C1; Mon, 5 Aug 2019 13:06:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1565010379; bh=qATYd373WHoQvx1nv4OGTJ3AU14oMmdMwgqxo4er9L0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ZyQPSFyyVwP27zdSRYHiaciyTUzwBac1gkjGXzLx9sa6iKAxcJzF0Q9qXfjz4BuGQ 0yS1BTPzUrGbTMVkjdDLvs0YKxDqAtpOi8fWJXpCYTsRdJVlpJZ/NP5TYNVIRXp5sU VBlX3UoN6dnQVqZHdPc+bS6fQ9svd0EP1MhJvl/4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Qian Cai , Thomas Gleixner , Sasha Levin Subject: [PATCH 4.9 16/42] x86/apic: Silence -Wtype-limits compiler warnings Date: Mon, 5 Aug 2019 15:02:42 +0200 Message-Id: <20190805124926.694565998@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190805124924.788666484@linuxfoundation.org> References: <20190805124924.788666484@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [ Upstream commit ec6335586953b0df32f83ef696002063090c7aef ] There are many compiler warnings like this, In file included from ./arch/x86/include/asm/smp.h:13, from ./arch/x86/include/asm/mmzone_64.h:11, from ./arch/x86/include/asm/mmzone.h:5, from ./include/linux/mmzone.h:969, from ./include/linux/gfp.h:6, from ./include/linux/mm.h:10, from arch/x86/kernel/apic/io_apic.c:34: arch/x86/kernel/apic/io_apic.c: In function 'check_timer': ./arch/x86/include/asm/apic.h:37:11: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits] if ((v) <= apic_verbosity) \ ^~ arch/x86/kernel/apic/io_apic.c:2160:2: note: in expansion of macro 'apic_printk' apic_printk(APIC_QUIET, KERN_INFO "..TIMER: vector=0x%02X " ^~~~~~~~~~~ ./arch/x86/include/asm/apic.h:37:11: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits] if ((v) <= apic_verbosity) \ ^~ arch/x86/kernel/apic/io_apic.c:2207:4: note: in expansion of macro 'apic_printk' apic_printk(APIC_QUIET, KERN_ERR "..MP-BIOS bug: " ^~~~~~~~~~~ APIC_QUIET is 0, so silence them by making apic_verbosity type int. Signed-off-by: Qian Cai Signed-off-by: Thomas Gleixner Link: https://lkml.kernel.org/r/1562621805-24789-1-git-send-email-cai@lca.pw Signed-off-by: Sasha Levin --- arch/x86/include/asm/apic.h | 2 +- arch/x86/kernel/apic/apic.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/include/asm/apic.h b/arch/x86/include/asm/apic.h index 2188b5af81676..f39fd349cef65 100644 --- a/arch/x86/include/asm/apic.h +++ b/arch/x86/include/asm/apic.h @@ -50,7 +50,7 @@ static inline void generic_apic_probe(void) #ifdef CONFIG_X86_LOCAL_APIC -extern unsigned int apic_verbosity; +extern int apic_verbosity; extern int local_apic_timer_c2_ok; extern int disable_apic; diff --git a/arch/x86/kernel/apic/apic.c b/arch/x86/kernel/apic/apic.c index 4f2af1ee09cbe..cc9a6f680225e 100644 --- a/arch/x86/kernel/apic/apic.c +++ b/arch/x86/kernel/apic/apic.c @@ -183,7 +183,7 @@ int first_system_vector = FIRST_SYSTEM_VECTOR; /* * Debug level, exported for io_apic.c */ -unsigned int apic_verbosity; +int apic_verbosity; int pic_mode; -- 2.20.1