From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 04F72C433E0 for ; Wed, 27 Jan 2021 11:11:52 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9981020729 for ; Wed, 27 Jan 2021 11:11:51 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9981020729 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nokia.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=LK2vnPOSm5LfEE4nktsx1BS+xwiwS4tfgy0rE2M9gbA=; b=JKyD6vSmbKZ2XuBUs8LI8Lxru 4TL96nym7w/phz5LAoDXyIY55TFULTu3zfvNILXlZkGiA02ykXHNoLzEKamOiMJ8/KzDjKTznj8o+ 4Yie0Vj0vGiXocPReB+iG8QPbbD19/OmedBftY1mzx3olKdpeonA9WRGRK6Fs38W/fPWECI/kM32g ZiCoNW8wBj9INAkHOEsAXv2RwxJRS/wCbGnJKtWZweb1Tdobgrs5lmxdK2eTORKkE3jXh+/pgjiNx eDVtiDqd5JC7SvTF0bUurdMks1rBjTFAZYzX2dTpS+Etnve+BTs9dwmx0z9NP0536WFAJIX290J8+ 8u2SJPpfw==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l4ii5-00057c-WF; Wed, 27 Jan 2021 11:10:06 +0000 Received: from mail-am6eur05on2113.outbound.protection.outlook.com ([40.107.22.113] helo=EUR05-AM6-obe.outbound.protection.outlook.com) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l4ihz-00056G-D1 for linux-arm-kernel@lists.infradead.org; Wed, 27 Jan 2021 11:10:00 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YKH5GBwImMNqMI1lsqtLE8fTad2ZrCP0Qjo+T+BVNG1aazYv6Qei9/B4NAloOjdbXy+n3vlRuwejBPDLc1om2nduKnQODzVmPpk7lLPzg7tr0qq7/tvYrEK8B6DXmUzbQ98fwA6M7XKkxLnNHCPIJ6EUd/KvqP21pE0S5V1KabwTbiuJ4v43ra1qWk59JIhqpM7ifLYKdFdfxun5Yy2qxKVUe7rRg1URmVSRQ0D9nhdbwfqaGTVr1aU/odXXOVzUtjl2ThBdtiD+V5+YaMm1pwsiS4sWSuWI7win0o0u6tPxNOIhVmIaIfOEi3Q14Q0rWg2cwoD2eSaEO+LSsBOafg== 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-SenderADCheck; bh=zlJmTMqpfOCiSImjexyakopdCkg7me37avy/EP7HCBI=; b=cn/8p8wEIh8c8MQ2XH5fv4zm8/054IuZqrcKl0Y0VgkMespa8mVUlSGJdjkBPnxonvj2+fYioa+joyfuXvFOKtp2/6EHeSnhEtBn/N18TPQrldeAJTW0ox/n/8bHS0lyq/FqL9X3eyk99KiJ3lYqGkTZTj2Mo8VTFZrdWUfGdIbeP2DcZAhI2OyGp83VkaolMO2zQtx3OSG5ijwMLsgXNIaaDedujlx4XpWZbPnQnwGawnaL/h8NV9j48IMvnZY875o14GzzjhdPicckz4PUMqscqm515gG//EtLFrxOnEsk+OmXvXYq5mxbgv3gexEiS8vYkzOjt9ApRQojCk9wCg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 131.228.2.8) smtp.rcpttodomain=linaro.org smtp.mailfrom=nokia.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=nokia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nokia.onmicrosoft.com; s=selector1-nokia-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zlJmTMqpfOCiSImjexyakopdCkg7me37avy/EP7HCBI=; b=okN/Rtao2SmJZ6C4rw7aDc8g4x81gOpCO8f2HpppT15qa4iiJ/njwhJ4wS6DU1tKXkZE9YJYt/0Pj6d2y1TvaE+YmNmoq4ygERsk2L6+e0wEq+Nqnj1JvzZVemj9MW1ma4Zj2RErkSpPnRPlkzmRevHGNSTdU4iGT5/Tyi1tpME= Received: from DB6PR0301CA0011.eurprd03.prod.outlook.com (2603:10a6:4:3e::21) by DB6PR0701MB2885.eurprd07.prod.outlook.com (2603:10a6:4:70::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3805.6; Wed, 27 Jan 2021 11:09:53 +0000 Received: from DB5EUR03FT046.eop-EUR03.prod.protection.outlook.com (2603:10a6:4:3e:cafe::c9) by DB6PR0301CA0011.outlook.office365.com (2603:10a6:4:3e::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3805.16 via Frontend Transport; Wed, 27 Jan 2021 11:09:53 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 131.228.2.8) smtp.mailfrom=nokia.com; linaro.org; dkim=none (message not signed) header.d=none;linaro.org; dmarc=pass action=none header.from=nokia.com; Received-SPF: Pass (protection.outlook.com: domain of nokia.com designates 131.228.2.8 as permitted sender) receiver=protection.outlook.com; client-ip=131.228.2.8; helo=fihe3nok0734.emea.nsn-net.net; Received: from fihe3nok0734.emea.nsn-net.net (131.228.2.8) by DB5EUR03FT046.mail.protection.outlook.com (10.152.21.230) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3784.11 via Frontend Transport; Wed, 27 Jan 2021 11:09:53 +0000 Received: from ulegcparamis.emea.nsn-net.net (ulegcparamis.emea.nsn-net.net [10.151.74.146]) by fihe3nok0734.emea.nsn-net.net (GMO) with ESMTP id 10RB9nLq008895; Wed, 27 Jan 2021 11:09:51 GMT From: Alexander A Sverdlin To: Steven Rostedt , Ingo Molnar , Russell King , linux-arm-kernel@lists.infradead.org, Florian Fainelli Subject: [PATCH v7 1/2] ARM: PLT: Move struct plt_entries definition to header Date: Wed, 27 Jan 2021 12:09:43 +0100 Message-Id: <20210127110944.41813-2-alexander.sverdlin@nokia.com> X-Mailer: git-send-email 2.10.2 In-Reply-To: <20210127110944.41813-1-alexander.sverdlin@nokia.com> References: <20210127110944.41813-1-alexander.sverdlin@nokia.com> X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-MS-PublicTrafficType: Email MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: 5708b87d-14d9-4cb5-de79-08d8c2b41292 X-MS-TrafficTypeDiagnostic: DB6PR0701MB2885: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2887; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oLi2lMqGeg0z7Bgz2XWwsWE9zk1hSw+oBUGlxVhUPyO3GBWgj3cG4zVNuWCLuIbJxSm5zdpt1YlrXBpKbJ/i/myXwILOpxpZlHbKUiBNt1oEE3bzBh1S+xXGnUMFGl8ZnpvW2aqduYUVKfDKdfAHIK5FXVRiNF1DFC+ULDFFS/9024keNvz2CCmbWFYe/bYH8Xx6C2Pus/4ywPSrnk0FvQf8SOkeccl+s8FjMjvag0E8sM4Wj+U8GU1IF66Ue0n3diH37XBO5nA2AqC02vkvag9fzW/dZjhWBKJYityec39UBpP1Ytq1EWZl6Nsy1Y4a44TF1kcoTuWqVasINVDdB1tIpH9Zb8AlXwpcsntjjK46loA2D49Fntj+xZ3bmGRlUhOmPhqU2LLPJrkWd92bl56WFo9hSZRq91rj5WJHguHaWhFMKBXS1k3lyXOIDwyUkVel/PjxT3DvZZ13RKKBi02gv15YQOsnJqSZv3jG2JrIPvIhdRjrI35ud1JyZaRK X-Forefront-Antispam-Report: CIP:131.228.2.8; CTRY:FI; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:fihe3nok0734.emea.nsn-net.net; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(4636009)(376002)(136003)(39860400002)(346002)(396003)(46966006)(70206006)(82740400003)(5660300002)(8936002)(36756003)(26005)(81166007)(70586007)(356005)(4326008)(54906003)(2906002)(2616005)(86362001)(186003)(336012)(8676002)(1076003)(82310400003)(6666004)(110136005)(316002)(47076005)(83380400001)(478600001)(36610700001); DIR:OUT; SFP:1102; X-OriginatorOrg: nokia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Jan 2021 11:09:53.3252 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5708b87d-14d9-4cb5-de79-08d8c2b41292 X-MS-Exchange-CrossTenant-Id: 5d471751-9675-428d-917b-70f44f9630b0 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5d471751-9675-428d-917b-70f44f9630b0; Ip=[131.228.2.8]; Helo=[fihe3nok0734.emea.nsn-net.net] X-MS-Exchange-CrossTenant-AuthSource: DB5EUR03FT046.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB6PR0701MB2885 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210127_060959_479662_E1913BAE X-CRM114-Status: GOOD ( 12.97 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Alexander Sverdlin , linux-kernel@vger.kernel.org, Ard Biesheuvel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Alexander Sverdlin No functional change, later it will be re-used in several files. Signed-off-by: Alexander Sverdlin --- arch/arm/include/asm/module.h | 9 +++++++++ arch/arm/kernel/module-plts.c | 9 --------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/arch/arm/include/asm/module.h b/arch/arm/include/asm/module.h index 4b0df09..09b9ad5 100644 --- a/arch/arm/include/asm/module.h +++ b/arch/arm/include/asm/module.h @@ -19,6 +19,15 @@ enum { }; #endif +#define PLT_ENT_STRIDE L1_CACHE_BYTES +#define PLT_ENT_COUNT (PLT_ENT_STRIDE / sizeof(u32)) +#define PLT_ENT_SIZE (sizeof(struct plt_entries) / PLT_ENT_COUNT) + +struct plt_entries { + u32 ldr[PLT_ENT_COUNT]; + u32 lit[PLT_ENT_COUNT]; +}; + struct mod_plt_sec { struct elf32_shdr *plt; int plt_count; diff --git a/arch/arm/kernel/module-plts.c b/arch/arm/kernel/module-plts.c index 6e626ab..d330e9e 100644 --- a/arch/arm/kernel/module-plts.c +++ b/arch/arm/kernel/module-plts.c @@ -12,10 +12,6 @@ #include #include -#define PLT_ENT_STRIDE L1_CACHE_BYTES -#define PLT_ENT_COUNT (PLT_ENT_STRIDE / sizeof(u32)) -#define PLT_ENT_SIZE (sizeof(struct plt_entries) / PLT_ENT_COUNT) - #ifdef CONFIG_THUMB2_KERNEL #define PLT_ENT_LDR __opcode_to_mem_thumb32(0xf8dff000 | \ (PLT_ENT_STRIDE - 4)) @@ -24,11 +20,6 @@ (PLT_ENT_STRIDE - 8)) #endif -struct plt_entries { - u32 ldr[PLT_ENT_COUNT]; - u32 lit[PLT_ENT_COUNT]; -}; - static bool in_init(const struct module *mod, unsigned long loc) { return loc - (u32)mod->init_layout.base < mod->init_layout.size; -- 2.10.2 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel