From patchwork Thu Apr 14 10:46:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joey Gouly X-Patchwork-Id: 12813335 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E57DCC433EF for ; Thu, 14 Apr 2022 10:48:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=2QS5N6VQfCGQrE/+01sAc0zTIIR2FWyqUjOXLuwMaWE=; b=e5CqnC0YRMrEBy lYsCMv6qbBtnku/o8sImg0MtXMHrMFH9z5ent4pUxhtrWKWUYVWlTRBiOkCrz94eRT6N8K3pVti08 YeozTfNnht/Xu6PIU9OUKPRfshkMKd6dweYe5HVP24yeb+Pdzz2/bOk6GFnCkSkhMADXcL8C98Us5 k0TLQl8XdpchVk6UK3QM5ypbxKhZCq220wus5rhksDKLL254IRNHgIBlHmrKfeXEAUOrYrJ+XxJQq +M1sFXwLfPt8fPg0EpAJR1G3LTDfCfXIz7OPO+WKtQxMzf1S0WxA3W8JKyXHkhksRiMSUkYExB9DZ o5mCZsvfbCscHLNSUccQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nex09-005BUB-4S; Thu, 14 Apr 2022 10:47:01 +0000 Received: from mail-vi1eur05on2062d.outbound.protection.outlook.com ([2a01:111:f400:7d00::62d] helo=EUR05-VI1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1newzq-005BP7-FV for linux-arm-kernel@lists.infradead.org; Thu, 14 Apr 2022 10:46:43 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EAx+lHHdo0szE9sx7jZAyJYEbwJtsBirD/h+tA5IYq8=; b=6F7oV7Cs2J5vtqCV4Z3uutv3DSPH9nU6bu2Up2xPI6imSQOUROzFDH4pGfLM90QJpIfiJzoAntMcsI/3Dy+Bih40Dqb+miZXJVS3a4Gyqepv38l5yJV4RCvpN1DXesFcDoAXpFSD9RbfVzl/6RU8Qe38uVkJA3LltzxFAsL08f8= Received: from DB6PR07CA0167.eurprd07.prod.outlook.com (2603:10a6:6:43::21) by AM6PR08MB4120.eurprd08.prod.outlook.com (2603:10a6:20b:a2::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.20; Thu, 14 Apr 2022 10:46:37 +0000 Received: from DB5EUR03FT014.eop-EUR03.prod.protection.outlook.com (2603:10a6:6:43:cafe::3a) by DB6PR07CA0167.outlook.office365.com (2603:10a6:6:43::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5186.8 via Frontend Transport; Thu, 14 Apr 2022 10:46:37 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by DB5EUR03FT014.mail.protection.outlook.com (10.152.20.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.19 via Frontend Transport; Thu, 14 Apr 2022 10:46:37 +0000 Received: ("Tessian outbound ac9bb5dd84f6:v118"); Thu, 14 Apr 2022 10:46:37 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 5c452dbb44645cad X-CR-MTA-TID: 64aa7808 Received: from 3300a7aea5b2.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id CCB4AA32-40D7-4E51-A7F5-4888707E18B1.1; Thu, 14 Apr 2022 10:46:30 +0000 Received: from EUR05-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 3300a7aea5b2.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Thu, 14 Apr 2022 10:46:30 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ykuow3s2dJS/+8ZvMsM576ixzXfvesoufWL7JIjcTaQX/UEN7zcyAV/DSi/iMAhkSdUUR0rz4D8z8s8Bm7mt4a9xceL62rSHNHAaQj74T1+KlJ07L8NJ8leD18re77AIu37j0wiXVDI58JIRvlX5y3OkP0Z7oWYkhHPB5HY/NBjO8JFljSjvDewUmhSruz/zBTAeO4o9ovS/OWhoxd7P4VmxnNn9wPUZgfjb7TvKisq95jwSYQ8adVOSGpaketI18S5bi54PaP1+IZyvThUJ2zbLFWy2RgejLnzkHAK2unShChSIECztnYMy2xQTuA7+GNKZyN2HsgjxqJJqyhxUrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=EAx+lHHdo0szE9sx7jZAyJYEbwJtsBirD/h+tA5IYq8=; b=YT90k7APJCD/gSP3Krxm/GvOCTp63CHpI/syJCKddxhQXqybr7BVX1ZJt8MLwKXABsg3XH38e57R7wwd6WbwJ+HvmlDQIwPt3SM1bzXF6LEwTLJ3XBUc2dVFDZasui389BblW9napmD2iHwwbfy2I81ACVSVSYtCV7d+mX9oaeR1QDaEBoYTqYsgcKIIqhBAdnOEVV12J2xmXasdspWQVMgL0JqnMHtZiqJxpEVffjIE5trIsZSIsQ+MgXRJlkxDxI3lcyhqgZ6I8ew+rdh3W7VgTVY96omwCA/+cf2kzuOZFtrfzREp7rFmrNVhqXyYiBLyrUtjgNAi+37qnHUKjw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=lists.infradead.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EAx+lHHdo0szE9sx7jZAyJYEbwJtsBirD/h+tA5IYq8=; b=6F7oV7Cs2J5vtqCV4Z3uutv3DSPH9nU6bu2Up2xPI6imSQOUROzFDH4pGfLM90QJpIfiJzoAntMcsI/3Dy+Bih40Dqb+miZXJVS3a4Gyqepv38l5yJV4RCvpN1DXesFcDoAXpFSD9RbfVzl/6RU8Qe38uVkJA3LltzxFAsL08f8= Received: from AS9PR06CA0402.eurprd06.prod.outlook.com (2603:10a6:20b:461::20) by AM8PR08MB6626.eurprd08.prod.outlook.com (2603:10a6:20b:367::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5144.29; Thu, 14 Apr 2022 10:46:28 +0000 Received: from AM5EUR03FT046.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:461:cafe::1f) by AS9PR06CA0402.outlook.office365.com (2603:10a6:20b:461::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.20 via Frontend Transport; Thu, 14 Apr 2022 10:46:28 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; Received: from nebula.arm.com (40.67.248.234) by AM5EUR03FT046.mail.protection.outlook.com (10.152.16.164) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5164.19 via Frontend Transport; Thu, 14 Apr 2022 10:46:28 +0000 Received: from AZ-NEU-EX03.Arm.com (10.251.24.31) by AZ-NEU-EX04.Arm.com (10.251.24.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Thu, 14 Apr 2022 10:46:30 +0000 Received: from e124191.cambridge.arm.com (10.1.197.45) by mail.arm.com (10.251.24.31) with Microsoft SMTP Server id 15.1.2308.27 via Frontend Transport; Thu, 14 Apr 2022 10:46:30 +0000 From: Joey Gouly To: CC: , , , , , , Subject: [PATCH v4 3/4] arm64: vdso32: put ELF related sections in the linker script Date: Thu, 14 Apr 2022 11:46:10 +0100 Message-ID: <20220414104611.17748-4-joey.gouly@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20220414104611.17748-1-joey.gouly@arm.com> References: <20220414104611.17748-1-joey.gouly@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-Office365-Filtering-Correlation-Id: 676e96e6-af31-4ec6-bd78-08da1e040d01 X-MS-TrafficTypeDiagnostic: AM8PR08MB6626:EE_|DB5EUR03FT014:EE_|AM6PR08MB4120:EE_ X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: hkn03HpJuLfmiTaLLqxpAfYallxs5zF40n1RgEIMU9V8bITIyAnLz3/+r4QBm4f8ZXOQV81Wu/S2MLRJBRPrUmRTvBNDw/3LAz2a77qfrcnH/BifjHbUPVJWuQYFX0rw/37xHBg7qjvIdS/BA7ueN/dBtVTf1R8Tw316LCewApp/j9A8+OXc7/UzXlMVRLpNk0yx4Qm0yvpj+jr8+CyI8YSS3b68ZHJc7GD8jEE6KNDZ2OnBcrDgfoHIyCWhazqI5gimiYc4zUQiCWnNUw2oJve9FtYLVUD/Hrw9DrPhrQzwRWkXSlcsvweAR1NcEyuNdf9K5sHgNNdf/ukUWHinbUiaWe6yX7nc6IDdKQExNcqC+MUH7DPouaGzo0q5IgHcDRrd9+KuB3dcVE3FAQAl2z+2YhbHUyPjVhbqUP4mJveM5MOdtM7z0KnG7QJ00/ZCjx4bKmVsayepHQMsPQh+n3+WClYHuNzdePmnlEvBwqY4KKQIPWVYImdlecdYID10guRseFXWdE3s42UuBsOhG5UuMaLluBNES1kASrUP5nUphcOURn9qS36+zMq1w2X97IGl0D03Sm4C9crIjDbwk1d4TuVXbhx+XPUkV4tmF16uBWKnApNnVr6cSAP3MSysDsAUiMfOT01FB7Wlqyzt4nyw53C4PdrbKUNvgDL0y/pC9QFUQf612pEpaktUZSQRwKdAK8kisA69VKxgtB9kgg== X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230001)(4636009)(46966006)(40470700004)(36840700001)(2616005)(82310400005)(8936002)(7696005)(6916009)(81166007)(6666004)(4326008)(8676002)(5660300002)(86362001)(36860700001)(70206006)(70586007)(2906002)(40460700003)(54906003)(36756003)(1076003)(316002)(356005)(426003)(47076005)(336012)(508600001)(186003)(26005)(44832011)(36900700001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM8PR08MB6626 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB5EUR03FT014.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: c78870cd-e4a7-47f3-7286-08da1e040785 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 8Dcs6okkWqHAsDm3qgPuUvMOt3/JqlUsQPPUDxhearw2GqwB/up55f5kuhK4i5FmhxYZEGp1cjIxxtcesHNqNGykyr0rxHTJV8Y6KDRRofQbOB7+Bl16qtu2Ck2XCk1LaWZ89zXAl+0DC8qGeuTxx9bY7kJDcQI1I0wLHgGimt+AL0l/5ynilfrRu6lqph+vRWuAdziF5M+wRY892DxtPGLtkNZLA0/GGiUB3Ch3kxScKGMk9WM8ucnwBNnBZZmFuEYbGfcqqKmd7mh5Uf4EgUwRRTXeg3xReUmx1FmyXQKKooHkvsPEpYoKy4JzOpX4kLiU+7+iPM2b+9v8gAztyo3h2za0q/zhG7xs0iZuBDZbud+qsV+yTc12t91624tRs+hcKJvL76LSYA1znLZyACCeFb5HQY4wR3Ozv2flL5Ua/aoFrJccxFuP+pQb2fVuIkQRbs2C65mpxPMrnahHYKSTyGlPuHj5iyIqCG7WhAQG3baUVDGvcoyMlucYF8LkMpOfii2FkV+vsk0J8VhBhJ0fJBgefv1R23gA4RDxN9NoGdjfo8FcpszAQfqlzDMtS//hy0M3V5hwYxW0h/W+GETIf9tDsity2Uhg6atqxe7c4T3aOVTUHRx4fskAukwMeOSbHNRhsX045p6KTj1iIfA4vUfX5/b/L8mzh/5t54r5lC8z/mc6akqGj3EadZjw X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(13230001)(4636009)(40470700004)(36840700001)(46966006)(2616005)(7696005)(1076003)(186003)(26005)(47076005)(426003)(81166007)(86362001)(40460700003)(336012)(107886003)(36860700001)(44832011)(82310400005)(316002)(36756003)(70586007)(70206006)(5660300002)(4326008)(2906002)(508600001)(8676002)(6666004)(8936002)(6916009)(54906003); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Apr 2022 10:46:37.3110 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 676e96e6-af31-4ec6-bd78-08da1e040d01 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: DB5EUR03FT014.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB4120 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220414_034642_560413_1E66DC0B X-CRM114-Status: UNSURE ( 9.45 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Use macros from vmlinux.lds.h to explicitly name sections that are included in the compat VDSO32 output. Signed-off-by: Joey Gouly Cc: Catalin Marinas Cc: Will Deacon Cc: Masahiro Yamada Cc: Vincenzo Frascino Cc: Kees Cook Reviewed-by: Kees Cook Reviewed-by: Vincenzo Frascino --- arch/arm64/kernel/vdso32/vdso.lds.S | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/kernel/vdso32/vdso.lds.S b/arch/arm64/kernel/vdso32/vdso.lds.S index 3348ce5ea306..3bb955f08240 100644 --- a/arch/arm64/kernel/vdso32/vdso.lds.S +++ b/arch/arm64/kernel/vdso32/vdso.lds.S @@ -11,6 +11,7 @@ #include #include #include +#include OUTPUT_FORMAT("elf32-littlearm", "elf32-bigarm", "elf32-littlearm") OUTPUT_ARCH(arm) @@ -42,6 +43,9 @@ SECTIONS .got : { *(.got) } .rel.plt : { *(.rel.plt) } + ELF_DETAILS + .ARM.attributes 0 : { *(.ARM.attributes) } + /DISCARD/ : { *(.note.GNU-stack) *(.data .data.* .gnu.linkonce.d.* .sdata*)