From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C808913B592; Mon, 6 Jan 2025 15:48:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736178516; cv=none; b=IJ2lwOV1V9p45+j3vE7ivRQxKQQHNoF86BX2O/pF/60gqo1tH/JXjtMO8r1RIJ0gSSET0gP5yl33lgwnJZCj++TyYA1mFRBm3TwmrCsTKdsEOtU4LtkbC0Q5Gr7a5mFC8EGy1Lk0Q+NDcibwV55BkNStxcmGzJhE6ED5PBf9jl0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1736178516; c=relaxed/simple; bh=5Rlac0DBbJwqJO69oGUcpTjKe1C/xDwOWomFZBzSKzQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=Ib1qXmQfrMC6IHYTewkqIT+AwnRA8Zuf89FEzzfVM7zZdF5xWGOn9JPhM7WnZFxvcNxAjalqolqBtpTWipHxOiICAipFFAscBQprYCLfvvQs9bKWqyNHWsD4aPK0M+oLhcUPpRTdulgwv47Hkynn3tAZkjwjP/MbVtYf1qe7VKU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=QzXV6zt5; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="QzXV6zt5" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 44F99C4CED2; Mon, 6 Jan 2025 15:48:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1736178516; bh=5Rlac0DBbJwqJO69oGUcpTjKe1C/xDwOWomFZBzSKzQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QzXV6zt54DGJrDMVwX3kRZYT2efYCEl0eVFmEx1GBXnoJcG+82nK68ehgmkjPhDBT d/iNEiY8mI8uHnCyRHru/0UAdAoDedVVu/j92ULE85rBbzOuf2tJl3QXqTYS6WbSLt wR7Ry9mXc/L4imqSl72HzMXzrUvUpHSEHiQqQWbM= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Leon Romanovsky , Vineet Gupta , Sasha Levin Subject: [PATCH 5.10 128/138] ARC: build: Try to guess GCC variant of cross compiler Date: Mon, 6 Jan 2025 16:17:32 +0100 Message-ID: <20250106151138.079984914@linuxfoundation.org> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20250106151133.209718681@linuxfoundation.org> References: <20250106151133.209718681@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 5.10-stable review patch. If anyone has any objections, please let me know. ------------------ From: Leon Romanovsky [ Upstream commit 824927e88456331c7a999fdf5d9d27923b619590 ] ARC GCC compiler is packaged starting from Fedora 39i and the GCC variant of cross compile tools has arc-linux-gnu- prefix and not arc-linux-. This is causing that CROSS_COMPILE variable is left unset. This change allows builds without need to supply CROSS_COMPILE argument if distro package is used. Before this change: $ make -j 128 ARCH=arc W=1 drivers/infiniband/hw/mlx4/ gcc: warning: ‘-mcpu=’ is deprecated; use ‘-mtune=’ or ‘-march=’ instead gcc: error: unrecognized command-line option ‘-mmedium-calls’ gcc: error: unrecognized command-line option ‘-mlock’ gcc: error: unrecognized command-line option ‘-munaligned-access’ [1] https://packages.fedoraproject.org/pkgs/cross-gcc/gcc-arc-linux-gnu/index.html Signed-off-by: Leon Romanovsky Signed-off-by: Vineet Gupta Signed-off-by: Sasha Levin --- arch/arc/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arc/Makefile b/arch/arc/Makefile index 578bdbbb0fa7..18f4b2452074 100644 --- a/arch/arc/Makefile +++ b/arch/arc/Makefile @@ -6,7 +6,7 @@ KBUILD_DEFCONFIG := haps_hs_smp_defconfig ifeq ($(CROSS_COMPILE),) -CROSS_COMPILE := $(call cc-cross-prefix, arc-linux- arceb-linux-) +CROSS_COMPILE := $(call cc-cross-prefix, arc-linux- arceb-linux- arc-linux-gnu-) endif cflags-y += -fno-common -pipe -fno-builtin -mmedium-calls -D__linux__ -- 2.39.5