Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp240442pxf; Wed, 10 Mar 2021 05:26:33 -0800 (PST) X-Google-Smtp-Source: ABdhPJwhAsQR1jsGhGuDF9rCAA2zR7no5zkFXDhiTkGzMk3nPkK0S+Sj4yphCa3DmK00741K7GzG X-Received: by 2002:a17:906:753:: with SMTP id z19mr3668645ejb.447.1615382793533; Wed, 10 Mar 2021 05:26:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615382793; cv=none; d=google.com; s=arc-20160816; b=sZf9rnuPNXF2qx0SpA7FafN0BkZgkJdR436BAtDggZngTrW2xhW5NBadSiumt3FCLb BqbqKHTXBylDhDf5E/uEEZ0/HsXDkrpMOE8M8MV3jfIZmdJiFNUceFbjlsZeO+kXIa3C adL1RylwuYoo8hhSKJhs2RetkuhPaA+NhBOGWuODZ+eba31ApFaNoc62564PyHc5uoCX kE4DJrd8y075TxfghDikLk607v0iHglRMLN/p0jcIDd8+lEIXUtXhO3yLadv8eWZfC/w WjA3F25IrFmi9axcSw2nGsxoq0TtFckSqvjM2qcg/tSoolvlXNXfQmSA01kQ4OH5n0+3 EUxg== 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=N850AeULBJVJZjJtcEP+jFkDQcrAdCZJb5e1c29Bhpk=; b=YRq2iRQDYBWWYV2rWijbawgUqQpGlI3XxpFTCEC81MxiyB+MVPErWrWXPjE2frRaqm n9Iwbr1THw9roF6w8l07gtIS05P3dx3u+8O9HlO+Tq8ZjBToqeEfkLc5URu/c38qzqvO GFQX7u8a3ZFhYi94RzuVmrW6vhcDXZHeDItsr0OFW/NswnLzwPeJbRJr+2xSKqqa3wQp xP6jIiW7UdQqfERMS8irHY35jQvErirDEL3VvcWhKbwI7Nj3hGR1J6RCE4QNZxXQwTZg NfmRRIr8TED+Fqe4wtTRB/4QbcbrSgN4dNEcAO2mt4upVk0+e3B54jiPJIQEh8j4qjPf G1ag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=FlZk1W0M; 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 o2si11336037ejx.336.2021.03.10.05.26.09; Wed, 10 Mar 2021 05:26:33 -0800 (PST) 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=FlZk1W0M; 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 S233149AbhCJNY7 (ORCPT + 99 others); Wed, 10 Mar 2021 08:24:59 -0500 Received: from mail.kernel.org ([198.145.29.99]:45502 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232797AbhCJNYS (ORCPT ); Wed, 10 Mar 2021 08:24:18 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8227D64FDA; Wed, 10 Mar 2021 13:24:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1615382657; bh=cfD1P8CGtyw8lKVkpK4hcIzouL4RqZsCpWZlx6d2iTM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FlZk1W0MlmRpp2cDcIncdQaMJ62ZKa7QTeW2KXUN+oJ9uqKc7BfOr8iuE7KPejzBp tFYkX+j6hYNFpcnBccmpGnb7XV5cDKadXvaUJCL9cn+86pLp++bKwdQP8DRjK1bcZZ fCkwU6ZzExEuWKSWvhrVANTEQcN4pLcmFzRSE+zo= From: gregkh@linuxfoundation.org To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Helge Deller , kernel test robot , Sudip Mukherjee Subject: [PATCH 5.11 13/36] parisc: Enable -mlong-calls gcc option with CONFIG_COMPILE_TEST Date: Wed, 10 Mar 2021 14:23:26 +0100 Message-Id: <20210310132320.937139154@linuxfoundation.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210310132320.510840709@linuxfoundation.org> References: <20210310132320.510840709@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: Greg Kroah-Hartman From: Helge Deller commit 778e45d7720d663811352943dd515b41f6849637 upstream The kernel test robot reported multiple linkage problems like this: hppa64-linux-ld: init/main.o(.init.text+0x56c): cannot reach printk init/main.o: in function `unknown_bootoption': (.init.text+0x56c): relocation truncated to fit: R_PARISC_PCREL22F against symbol `printk' defined in .text.unlikely section in kernel/printk/printk.o There are two ways to solve it: a) Enable the -mlong-call compiler option (CONFIG_MLONGCALLS), b) Add long branch stub support in 64-bit linker. While b) is the long-term solution, this patch works around the issue by automatically enabling the CONFIG_MLONGCALLS option when CONFIG_COMPILE_TEST is set, which indicates that a non-production kernel (e.g. 0-day kernel) is built. Signed-off-by: Helge Deller Reported-by: kernel test robot Fixes: 00e35f2b0e8a ("parisc: Enable -mlong-calls gcc option by default when !CONFIG_MODULES") Cc: stable@vger.kernel.org # v5.6+ Signed-off-by: Sudip Mukherjee Signed-off-by: Greg Kroah-Hartman --- arch/parisc/Kconfig | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig @@ -201,9 +201,12 @@ config PREFETCH def_bool y depends on PA8X00 || PA7200 +config PARISC_HUGE_KERNEL + def_bool y if !MODULES || UBSAN || FTRACE || COMPILE_TEST + config MLONGCALLS - def_bool y if !MODULES || UBSAN || FTRACE - bool "Enable the -mlong-calls compiler option for big kernels" if MODULES && !UBSAN && !FTRACE + def_bool y if PARISC_HUGE_KERNEL + bool "Enable the -mlong-calls compiler option for big kernels" if !PARISC_HUGE_KERNEL depends on PA8X00 help If you configure the kernel to include many drivers built-in instead