Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3004237pxj; Mon, 17 May 2021 15:21:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwAo9PO2VYSeJqaNU+eO5q49nVUjcc5LKjB5PE+zgbXTFRhybWqN6Qgjdz24h37YAFMx5dv X-Received: by 2002:a50:fb0f:: with SMTP id d15mr2692215edq.343.1621290095496; Mon, 17 May 2021 15:21:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621290095; cv=none; d=google.com; s=arc-20160816; b=HhQQGLUDkuZuQzvIdD+RnHsqQrk0b5EPNZObq/TZB0+ftSrCoYyPHnryB+1Njn3xsy O3fLDb6qRuQ3AcODnP+HMe1wdIQxJPPJqhN9Rrf+gka251CKVCGgaw7M+XLVOb+Yx33y cmalfL4GVHyYQyjeKjg/bMTMoXE9xeQtij1PoaIpfxdyZsS8mptVSebyklcfVHnGz4P4 bUMaaJQv6Bqai/VbOWK0m7Le2CKCKau7jUFEOlCFkrSJuh/FtyAz+TroGIspd1dKuunO rXfUawxVNQN9SPJpQZCc/KVfERRL6Q3NVos0dVjlqQk3l4+FMKCb2Mb8WenN0yFb2xKu ZxAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=B+VsfG3eGrXUN+sJ2j/1fQg50OTna/88orkuT/jNdg0=; b=zJZwGMab1gOY/XFIjccNkLY/7xFgQ4iC1IT05o1GwNyUxzIyjCp12qXH+zmeLPkFKt M4ZNTjxh56e4MQheS8Y70bebidjH8qJrk4ZWmwxnsoUAMTdgHdfqBkSjdCZKvttGAi8p iQq8vrpAFD77cdV9cTKzNHLPJ6cjgRGUVbn+wXG0/OYTueUSwPvShUlDvZyhyE858Bxk awG1QgbggHSarZQ2tqOe/IzZNwWQtUOQLmm3N+9/ZNWoMSmVybACRIEFC6XXJnxbWhZa xYMPWTP455L4KxuXSaXaeKQXsc+R1OFnxtBngNQNmlZOJMeIRT+nuWl6cT/nKMKoxNBw RDXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=RcXKOxGO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a12si774832ejt.503.2021.05.17.15.21.12; Mon, 17 May 2021 15:21:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=RcXKOxGO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238468AbhEQOM4 (ORCPT + 99 others); Mon, 17 May 2021 10:12:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:58176 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238209AbhEQOLN (ORCPT ); Mon, 17 May 2021 10:11:13 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 3A2B8613AA; Mon, 17 May 2021 14:07:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1621260446; bh=9wFV1yLqUD2lVj7naTAbKoTxesfC7PP0RjjNEj9qpS4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RcXKOxGO5o0Y5KCEYNJJXID/cS0DNlLwhrfLPBIEm18D0p7hO+SdYOPFeoJecnHc+ i+6T/r4RxttP1pi0U1b0/s9JW5BS7kq1uukZ+cxJbQDMNf9X6HfdSjMjTrsUfqZb7U ID+UCdcnbKNmbjQyz6IUagde4Hc88uoNojgHpbA4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Yonghong Song , Alexei Starovoitov , Andrii Nakryiko , Sasha Levin Subject: [PATCH 5.12 085/363] selftests: Set CC to clang in lib.mk if LLVM is set Date: Mon, 17 May 2021 15:59:11 +0200 Message-Id: <20210517140305.475694098@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210517140302.508966430@linuxfoundation.org> References: <20210517140302.508966430@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Yonghong Song [ Upstream commit 26e6dd1072763cd5696b75994c03982dde952ad9 ] selftests/bpf/Makefile includes lib.mk. With the following command make -j60 LLVM=1 LLVM_IAS=1 <=== compile kernel make -j60 -C tools/testing/selftests/bpf LLVM=1 LLVM_IAS=1 V=1 some files are still compiled with gcc. This patch fixed lib.mk issue which sets CC to gcc in all cases. Signed-off-by: Yonghong Song Signed-off-by: Alexei Starovoitov Acked-by: Andrii Nakryiko Link: https://lore.kernel.org/bpf/20210413153413.3027426-1-yhs@fb.com Signed-off-by: Sasha Levin --- tools/testing/selftests/lib.mk | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk index be17462fe146..0af84ad48aa7 100644 --- a/tools/testing/selftests/lib.mk +++ b/tools/testing/selftests/lib.mk @@ -1,6 +1,10 @@ # This mimics the top-level Makefile. We do it explicitly here so that this # Makefile can operate with or without the kbuild infrastructure. +ifneq ($(LLVM),) +CC := clang +else CC := $(CROSS_COMPILE)gcc +endif ifeq (0,$(MAKELEVEL)) ifeq ($(OUTPUT),) -- 2.30.2