Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2649287imj; Mon, 11 Feb 2019 06:27:38 -0800 (PST) X-Google-Smtp-Source: AHgI3IbAYjCCKwI95vT9VKl8JEnIPdSyi9URhpWB2ZBa+miWTyQbmtMwVUeRljqi3YQO9G8Q9rLu X-Received: by 2002:a17:902:b701:: with SMTP id d1mr35929136pls.124.1549895258835; Mon, 11 Feb 2019 06:27:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549895258; cv=none; d=google.com; s=arc-20160816; b=HS8Fqo8ckaTQ0Gp/nTDyXLBZEFLur9Gt/tho7rbJahwxAMWbIrmkrRM+HOwC5dz7i3 SF0MaxQlFlTtvLpZLfAqslZFS5ku1OhZQxeSy2NSzwbjIajQg0RbVTLDSyOFSq4ZgB6R nFOHOz0i5QnrcL0x35DgwarcwZxtYZpMJX51jeqoWufeRL03r58zeVohcXstBw8KcN3Z lyo9p8qeWcF3QHgeV+JlMVxS/NoJljiLZZxDA1NJ6A6d+FQhpImRkVH/oIGnzrQmhtVR vcImZh61RpYK2eCdutBEbmRK6U5XXlt3SOJn9jAUotbwgSbU63JOVxFzK1cTZ+iqXzrJ z8lw== 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=yCwfnVXSvQvmyuQTbWSrS5J3Au0jfB2LlD7YudzumRc=; b=yTSoic3OcIJ63HIMvhFoLOn/KJP0a3KAnCNLLG9W0XbZmrmt8H2gNwNnWqO69BV7zE t7gBrgNTi74m0XPzQXtPNAf24j0RXL1ZLUU5nHJb7mONY8Z/FIpdiAkoZX/8NMPjn1uw IpHQ7+hdWh9Jwar69IWf10TE75DG/jJjmz52g4MlhmR5pcFPntQDV2J6eObxDnukzPgo nrf7/G57Cr0hOLYtlT2T1oxQf4KQreljl0Y9cNFimOgdyTriV7sK0tTbpZDKHv3s1vEl +KbYeKKqk2qy98KcvJZsJzFz8KXFg7LQiHxmf4CplzczFSoj9U6TbwjlDH4/5re3diqF bCLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=N5qeXzgw; 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 m5si10883670pfm.149.2019.02.11.06.27.22; Mon, 11 Feb 2019 06:27:38 -0800 (PST) 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=N5qeXzgw; 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 S1729116AbfBKOYI (ORCPT + 99 others); Mon, 11 Feb 2019 09:24:08 -0500 Received: from mail.kernel.org ([198.145.29.99]:57218 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726041AbfBKOYF (ORCPT ); Mon, 11 Feb 2019 09:24:05 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.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 DAF3620838; Mon, 11 Feb 2019 14:24:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549895044; bh=V4cF9xRQvtxI5sMUGfiiKcoBjZZqtpF8AsfX55LWtFM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=N5qeXzgwxK74xbvR1Bg5yL6T7HfRlvNpciSXvmJE5jVc/STu42bx3tN+uZDHMQegy AKQQTauPEBe+pFg6j0sVB4iSofcKCHgLx5qhlvR3YZQvcF72GscPdmKXy4cdAW3hIR RkVKn8PAy3Waz/eHpQzR8Z/cOOLrfVbYXJwTgjoQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nicholas Piggin , Mathieu Malaterre , Michael Ellerman , Sasha Levin Subject: [PATCH 4.20 072/352] powerpc/32: Add .data..Lubsan_data*/.data..Lubsan_type* sections explicitly Date: Mon, 11 Feb 2019 15:14:59 +0100 Message-Id: <20190211141850.662693552@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141846.543045703@linuxfoundation.org> References: <20190211141846.543045703@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore 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 4.20-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit beba24ac59133cb36ecd03f9af9ccb11971ee20e ] When both `CONFIG_LD_DEAD_CODE_DATA_ELIMINATION=y` and `CONFIG_UBSAN=y` are set, link step typically produce numberous warnings about orphan section: + powerpc-linux-gnu-ld -EB -m elf32ppc -Bstatic --orphan-handling=warn --build-id --gc-sections -X -o .tmp_vmlinux1 -T ./arch/powerpc/kernel/vmlinux.lds --who le-archive built-in.a --no-whole-archive --start-group lib/lib.a --end-group powerpc-linux-gnu-ld: warning: orphan section `.data..Lubsan_data393' from `init/main.o' being placed in section `.data..Lubsan_data393'. powerpc-linux-gnu-ld: warning: orphan section `.data..Lubsan_data394' from `init/main.o' being placed in section `.data..Lubsan_data394'. ... powerpc-linux-gnu-ld: warning: orphan section `.data..Lubsan_type11' from `init/main.o' being placed in section `.data..Lubsan_type11'. powerpc-linux-gnu-ld: warning: orphan section `.data..Lubsan_type12' from `init/main.o' being placed in section `.data..Lubsan_type12'. ... This commit remove those warnings produced at W=1. Link: https://www.mail-archive.com/linuxppc-dev@lists.ozlabs.org/msg135407.html Suggested-by: Nicholas Piggin Signed-off-by: Mathieu Malaterre Signed-off-by: Michael Ellerman Signed-off-by: Sasha Levin --- arch/powerpc/kernel/vmlinux.lds.S | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/powerpc/kernel/vmlinux.lds.S b/arch/powerpc/kernel/vmlinux.lds.S index 434581bcd5b4..1148c3c60c3b 100644 --- a/arch/powerpc/kernel/vmlinux.lds.S +++ b/arch/powerpc/kernel/vmlinux.lds.S @@ -308,6 +308,10 @@ SECTIONS #ifdef CONFIG_PPC32 .data : AT(ADDR(.data) - LOAD_OFFSET) { DATA_DATA +#ifdef CONFIG_UBSAN + *(.data..Lubsan_data*) + *(.data..Lubsan_type*) +#endif *(.data.rel*) *(SDATA_MAIN) *(.sdata2) -- 2.19.1