Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp5848810ybn; Sun, 29 Sep 2019 07:02:46 -0700 (PDT) X-Google-Smtp-Source: APXvYqxmjDv+zlegpi7z2PIcA/+iMUpFcF7febpdNNTYq2EN7vm33MglGz2gSKIPW6qM0l/T0HdK X-Received: by 2002:a17:906:e297:: with SMTP id gg23mr15124759ejb.47.1569765766295; Sun, 29 Sep 2019 07:02:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569765766; cv=none; d=google.com; s=arc-20160816; b=ct2G4SK9qzhAeaRMkMx34RmONswM27wlJEbqXblnIzt3X4rP3Hz/HH8bOuVGwlhUlg rMnS3QLmelU8mWVV7xpcpSwdP39z7glYHLUHSs9I8i5sr5h2H4CoTAo0ilN580+DrG5E IeclbeuepWPzD4MBVDAkRVCZ0wHvoWzuhXqkc2jiw2TB3AzErNfLeoH3gPaNVXJQo/Zw AulFWKIByltwVviEd+t5U7xiZXjAAKHWO4G1l6Cm528uNFRHdu9q3nRmNXQlm4ujH46T yMJIq3pRUNly4Kc1N18JZrWt4o6eZGrTWW/VJ84q1J43O24FEg6oiW+NlHtYgg55BKFE z7NQ== 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=O2ioxZDQWNgrmO/zEVakI5HWY7qUFh79QdFwoPT8vb8=; b=mU20/F8BAgZJppYEr4gG2HFBMV1f7nGEEcnGApaU8IJ3ya9bU0bcMTGCEuKj5K5bNG yMY+EeKTCqmXx1XGXE4nTZdqMrsKv6KtNzpMMxXhdjZdhSj2P16E60THh5P9riG/qLI8 zfK9yUx1XGcSxepQ0LiiXTrwG5Z/oZfgxCJF3ihjvLe6lx94dhMuGHOFgE5u+RAIpzAd 7B38NnJficXq4Wlv5O1SDJAbJ8CLehnePtPsoXFSgqHlMLddKvW5pGJBVVk379LS8GyS 4cXjjDAgvAw7AW2LggKSYqUSD62aTKKpQiWxK8KDr/tftoPIu5NDcOJF2hTYjxtrMy8A IV/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kx0y92vV; 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 l18si5550694ejg.248.2019.09.29.07.02.21; Sun, 29 Sep 2019 07:02:46 -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=kx0y92vV; 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 S1730035AbfI2OB1 (ORCPT + 99 others); Sun, 29 Sep 2019 10:01:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:43618 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729427AbfI2OBY (ORCPT ); Sun, 29 Sep 2019 10:01:24 -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 43C6A2086A; Sun, 29 Sep 2019 14:01:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1569765684; bh=fJRIE1yXHyuEXQ+irInj0w2AxnLqI9dVf+67QWo0nfc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kx0y92vVV8tmDkBRI08V987u8SHuCz7dKInE7F9Q1SE1u60NM0evFjSGKImrYsSS6 d3OWqTtcN3FQJEkx57Q6CKSWFYc6nJkWgK7SgIAJs5i1p8Fvn8rN99h4gzc+bfOben 7S05lbIPwB1roK4Oy5yH61jyt9cRN1OZS+Bae9RQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Valdis Kletnieks , Josh Poimboeuf , Linus Torvalds , Peter Zijlstra , Thomas Gleixner , Ingo Molnar , Nathan Chancellor Subject: [PATCH 5.2 29/45] objtool: Clobber user CFLAGS variable Date: Sun, 29 Sep 2019 15:55:57 +0200 Message-Id: <20190929135031.833990464@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190929135024.387033930@linuxfoundation.org> References: <20190929135024.387033930@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 From: Josh Poimboeuf commit f73b3cc39c84220e6dccd463b5c8279b03514646 upstream. If the build user has the CFLAGS variable set in their environment, objtool blindly appends to it, which can cause unexpected behavior. Clobber CFLAGS to ensure consistent objtool compilation behavior. Reported-by: Valdis Kletnieks Tested-by: Valdis Kletnieks Signed-off-by: Josh Poimboeuf Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Link: https://lkml.kernel.org/r/83a276df209962e6058fcb6c615eef9d401c21bc.1567121311.git.jpoimboe@redhat.com Signed-off-by: Ingo Molnar CC: Nathan Chancellor Signed-off-by: Greg Kroah-Hartman --- tools/objtool/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/tools/objtool/Makefile +++ b/tools/objtool/Makefile @@ -35,7 +35,7 @@ INCLUDES := -I$(srctree)/tools/include \ -I$(srctree)/tools/arch/$(HOSTARCH)/include/uapi \ -I$(srctree)/tools/objtool/arch/$(ARCH)/include WARNINGS := $(EXTRA_WARNINGS) -Wno-switch-default -Wno-switch-enum -Wno-packed -CFLAGS += -Werror $(WARNINGS) $(KBUILD_HOSTCFLAGS) -g $(INCLUDES) $(LIBELF_FLAGS) +CFLAGS := -Werror $(WARNINGS) $(KBUILD_HOSTCFLAGS) -g $(INCLUDES) $(LIBELF_FLAGS) LDFLAGS += $(LIBELF_LIBS) $(LIBSUBCMD) $(KBUILD_HOSTLDFLAGS) # Allow old libelf to be used: