Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp1594004pxb; Sun, 10 Jan 2021 03:59:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJw2OYdZex1l9Aqgf7lTFs+beZcAK5p+g38dcsItdgcaoN680W72FOkQXzT30ixoUPg77Qql X-Received: by 2002:a17:906:9605:: with SMTP id s5mr8122449ejx.179.1610279948617; Sun, 10 Jan 2021 03:59:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610279948; cv=none; d=google.com; s=arc-20160816; b=pmLq+niZh3OAB6lZHqH+Ry6zkPalg/xTH0hbLVqP3Q0NXa0eIobakN64EzGKJlcZ/u gQN0p6cYBfn3SH/CEdimmMlm6iLt9xEQcwe7wUD733b/tYjVh3NeKgPxz6Pdf5CfNFwY EDxI9QKp1GuoCMgay6p4rch8+KJqpIFCzFh1IkTlZUYj7+Y6xtNb0KYEGni9Zo9ITX2a pYClDOFBj33O3z4FWmIl9QhT2lPViG/TAk/v/NIMTTHKLwXaJ4MTSBN5ULsSbqmNQf7V GFXld2k2Vgab4H5Vc5qyjoNeorNwCkOOA+NQFhnqY4/iQAuxJShMdKycTwcM9mV73DfI 8eMw== 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 :references:in-reply-to:message-id:subject:reply-to:cc:from:to :dkim-signature:date; bh=+ae0nqbyeS3RjrUU35uQTOED4nYRvyGMZstGTOsR/XI=; b=DO4TghIDo9rKeMCjEz/bOjLqxP+3QhhUxLZ52rnJYC+vJuQ0+4jeiOL17ZTjE5/ygh 9bIwPl1PUCYIMe41AIlrUQ+UNz+HgoGegbRCT+gB1B/n91FCbFNUxloqZn6rXRBFX3+g GkXnB7tudrxNqFulv/QGd2yzXu0EudiXi8qxlGECAqfzmm+z8V3ZBWgcawjTMMSGTEvR pFs2Nnkpx2SLAzlO+2DXWDwFB2xQzhByYzIDDg8SVizCf8P8JgDOxKzovdhDh82issYO XdVWtUIMLfsL2liH/H8ZxcYUb3Y4RQaprzJLzAasgNRh56pGKcs7roLEwI8DY6obb7Ah t+lg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@pm.me header.s=protonmail header.b=C2tPyl58; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=pm.me Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lf25si5311933ejb.303.2021.01.10.03.58.45; Sun, 10 Jan 2021 03:59:08 -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=@pm.me header.s=protonmail header.b=C2tPyl58; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=pm.me Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726761AbhAJL5j (ORCPT + 99 others); Sun, 10 Jan 2021 06:57:39 -0500 Received: from mail-40131.protonmail.ch ([185.70.40.131]:12094 "EHLO mail-40131.protonmail.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726724AbhAJL5i (ORCPT ); Sun, 10 Jan 2021 06:57:38 -0500 Date: Sun, 10 Jan 2021 11:56:34 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pm.me; s=protonmail; t=1610279798; bh=+ae0nqbyeS3RjrUU35uQTOED4nYRvyGMZstGTOsR/XI=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=C2tPyl58XE2zQ0KPOSMylWBWbk0UKeDtNEOseTTtSJLWstFv8cTRa0XqoNaYmusB3 maeMzBWCdVdVsiUork2JsMn2ZMcsA7efIbmqnhb03RW69cIZyYgmkZCpQsnbzPJaVm PRXCMI6pg8ODZalPOq0c4P7qcga3n2/DQ1r9W4fy3wckCj2eZEqjUtprOFDrwl2/Z9 G/OyXLkoD5mKAEhPeyHVmgyH3xLpKX4dlzYmj/yOPD76YEwRLjJsHIIwbBd4daD9Vn YBXACF6CdymNRuD3/ZHPHb/e5GlHQpZEse6i5L0stZyrse8JeqUfGIPP/1bnpbidnH nY+860napd82A== To: Thomas Bogendoerfer From: Alexander Lobakin Cc: Arnd Bergmann , Nathan Chancellor , Nick Desaulniers , Huacai Chen , Pei Huang , Kees Cook , Alexander Lobakin , Fangrui Song , Jiaxun Yang , Ralf Baechle , Corey Minyard , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, stable@vger.kernel.org, clang-built-linux@googlegroups.com Reply-To: Alexander Lobakin Subject: [PATCH v5 mips-next 5/9] MIPS: vmlinux.lds.S: explicitly catch .rel.dyn symbols Message-ID: <20210110115546.30970-5-alobakin@pm.me> In-Reply-To: <20210110115546.30970-1-alobakin@pm.me> References: <20210110115245.30762-1-alobakin@pm.me> <20210110115546.30970-1-alobakin@pm.me> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=10.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF shortcircuit=no autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on mailout.protonmail.ch Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org According to linker warnings, both GCC and LLVM generate '.rel.dyn' symbols: mips-alpine-linux-musl-ld: warning: orphan section `.rel.dyn' from `init/main.o' being placed in section `.rel.dyn' Link-time assertion shows that this section is sometimes empty, sometimes not, depending on machine bitness and the compiler [0]: LD .tmp_vmlinux.kallsyms1 mips64-linux-gnu-ld: Unexpected run-time relocations (.rel) detected! Just use the ARM64 approach and declare it in vmlinux.lds.S closer to __init_end. [0] https://lore.kernel.org/linux-mips/20210109111259.GA4213@alpha.franken.= de Reported-by: Thomas Bogendoerfer Signed-off-by: Alexander Lobakin --- arch/mips/kernel/vmlinux.lds.S | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/mips/kernel/vmlinux.lds.S b/arch/mips/kernel/vmlinux.lds.= S index 10d8f0dcb76b..70bba1ff08da 100644 --- a/arch/mips/kernel/vmlinux.lds.S +++ b/arch/mips/kernel/vmlinux.lds.S @@ -137,6 +137,11 @@ SECTIONS =09PERCPU_SECTION(1 << CONFIG_MIPS_L1_CACHE_SHIFT) #endif =20 +=09.rel.dyn : ALIGN(8) { +=09=09*(.rel) +=09=09*(.rel*) +=09} + #ifdef CONFIG_MIPS_ELF_APPENDED_DTB =09.appended_dtb : AT(ADDR(.appended_dtb) - LOAD_OFFSET) { =09=09*(.appended_dtb) --=20 2.30.0