From patchwork Mon Apr 4 10:40:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Roger_Pau_Monn=C3=A9?= X-Patchwork-Id: 12800104 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 lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (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 2FC44C433F5 for ; Mon, 4 Apr 2022 10:41:57 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.298243.508000 (Exim 4.92) (envelope-from ) id 1nbK9a-0006Ap-F4; Mon, 04 Apr 2022 10:41:46 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 298243.508000; Mon, 04 Apr 2022 10:41:46 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nbK9a-0006Ag-Bs; Mon, 04 Apr 2022 10:41:46 +0000 Received: by outflank-mailman (input) for mailman id 298243; Mon, 04 Apr 2022 10:41:45 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1nbK9Z-00069z-4B for xen-devel@lists.xenproject.org; Mon, 04 Apr 2022 10:41:45 +0000 Received: from esa6.hc3370-68.iphmx.com (esa6.hc3370-68.iphmx.com [216.71.155.175]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id cfe990f5-b403-11ec-a405-831a346695d4; Mon, 04 Apr 2022 12:41:42 +0200 (CEST) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: cfe990f5-b403-11ec-a405-831a346695d4 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1649068902; h=from:to:cc:subject:date:message-id:in-reply-to: references:content-transfer-encoding:mime-version; bh=T3IUeHOAUwH5jnaWVMPVxz4AYqEm6BYtGI9yr57oZZE=; b=CxEzMaD2pLnzPUIgOja4HjndXuK4WjiSNaLMRzV7gD3j5xmWW6DUeaxk 2CuOSR4Sw+cwiEeKa4ldxyqC+F3+Iev/eDKxna0WpS3iE+skgLu4uG9jI NXHy2M3H/a2hErVUlrJuItygfKCM3jrrZnwoR4sD2Au1hCXvRBVA6pSeH s=; Authentication-Results: esa6.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com X-SBRS: 5.1 X-MesageID: 67825388 X-Ironport-Server: esa6.hc3370-68.iphmx.com X-Remote-IP: 162.221.156.83 X-Policy: $RELAYED IronPort-Data: A9a23:1qSQLKIYmf8AP2L+FE+Rq5UlxSXFcZb7ZxGr2PjKsXjdYENS1jxSn DROXGuGPPncZ2DxLtl/Odzn8EgAuJbXzd9nSFRlqX01Q3x08seUXt7xwmUcns+xwm8vaGo9s q3yv/GZdJhcokf0/0vrav67xZVF/fngqoDUUYYoAQgsA148IMsdoUg7wbRh3tY02YHR7z6l4 rseneWOYDdJ5BYsWo4kw/rrRMRH5amaVJsw5zTSVNgT1LPsvyB94KE3fMldG0DQUIhMdtNWc s6YpF2PEsE1yD92Yj+tuu6TnkTn2dc+NyDW4pZdc/DKbhSvOkXee0v0XRYRQR4/ttmHozx+4 NJNicCyYBU5BbPJk78HShRcQjolbKITrdcrIVDn2SCS50jPcn+qyPRyFkAme4Yf/46bA0kXq 6ZecmpUKEne2aTmm9pXScE17ignBNPsM44F/Glp0BnSDOo8QICFSKLPjTNd9Glv1poTRqaOD yYfQRlkMyziUjRPBmUOIrcSvNyj11bEbhQN/Tp5ooJ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Tb7dXsMg24F5VKpEdByj3gbpXXN WGNPuspcq+TGnqL0ww5gJUsZ+RtzUIb1q7q3E5y4KoO2M8pgE686MarPZv6kvouqhNDqWs3N 60QZiApIs+PvP+UpgNdtvpOfHHclAlYSi8Rl56cm6XXZ3uBRr22uvKCfMOlaWXRKA= X-IronPort-AV: E=Sophos;i="5.90,234,1643691600"; d="scan'208";a="67825388" ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jFegkCdlijiqo34ncNwKI5oXINDJkEsts2JJyVvW98pqe2NawqCAExqLpPPIdrGVhL/2vIgMeTav9yWYMXTh2g5qLKIV7UV7JqzYn3TOSXAdW8R9x0kWPUfijMIrZ6DZy4VnBoJdtDHJIZxZou2rSDkDPm+3gsZRC2WQyJjZtrwSiXTzeGTER0KbKsH1AN1GA2nmQQ1A6SYsrlX5jmhLqlKCaRZLE3tenfvbLCGAKY8hJyPetnXNBGxrXAmu/BtnsFkdYPac3qRbnmeYehjQPcUzpv0pSHF7fL+5MTcfeV04pxTzcLZ8KLYU+6Wrwp0meb1lTO1BkoUQJmQ7RPGQJQ== 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=OyBbGihEUGhAAN4xDkKaoxTfhhCkzCzAGn/Ff7r7+o4=; b=TPdjwmq2KC/9WWMCwZjdT7KfvXfz/1JzpKuaqv2duImQKy+7Uyn/634bK+rmZ1Ml7EC+sHvYvOmajWBo512S6P/0V43EFrHh2CibYDD1fLXQzvfdb+mAIXQgay4fZ6KL+PjKGLU7e8l447deAv5TIH4FOUBVrTrSOs9zAXpxZvgp6QF5yHw6fuf69a1N16Xeal0hTC9sx8atxmI5pu7S2+hxrR8USFe4MLaAkro5+yqCJ0qtAYdzFCfghZcl4bjDsJzeZBNIP7eHl2FAfQGM9PFFlYG99zZP1n9KhuLijPXi7vrC3TezYU/msfrmjykc1S90btjtpskCiLnqQ4aDtw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=citrix.onmicrosoft.com; s=selector2-citrix-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=OyBbGihEUGhAAN4xDkKaoxTfhhCkzCzAGn/Ff7r7+o4=; b=gdP4XWAj5gKaMoSJRdsZY6Rn7xOkWglVsj+Jy0l+E8uAwGsCP2EjtnrV1AjimEzb1csrnIQ6utW8nvW1g759yMAj7uGk8Q0aNCQaC3UycH0o2j1gJmNwoh5R2SoWClzvF8QRR/6a+1pKC+I9m3D6WB1Ln99n/HMg619c4/J6xGQ= From: Roger Pau Monne To: CC: Roger Pau Monne , Wei Liu , Anthony PERARD Subject: [PATCH v2 1/2] tools/firmware: fix setting of fcf-protection=none Date: Mon, 4 Apr 2022 12:40:43 +0200 Message-ID: <20220404104044.37652-2-roger.pau@citrix.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220404104044.37652-1-roger.pau@citrix.com> References: <20220404104044.37652-1-roger.pau@citrix.com> X-ClientProxiedBy: LO4P123CA0125.GBRP123.PROD.OUTLOOK.COM (2603:10a6:600:192::22) To DS7PR03MB5608.namprd03.prod.outlook.com (2603:10b6:5:2c9::18) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: af3af710-203d-4ec2-ffbc-08da1627af39 X-MS-TrafficTypeDiagnostic: MN2PR03MB4669:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gcB+Dd4si7tr1z1e3wMAhJ70hzi3vDMxwOtZaHeHGIkA4lrWLnseRfGWHh1EidvcNq7343KLUQgujj1/BOSFgSFbYJf/lgi4DfABFyIR0DvIDt2hN1TahkSeIWQd9fxV/hxa/bL1qAr+fSNd0Pq4z1pWyM9WlJ/VNxIMeIzuFiPCHc7GXTmJy8XN/gACoaBuZ5Ah9OtjtkiRVeW/PLctgZJNTKcz20iqTT0UgnIRnGtZRkdGEyJg1l8aRDQ7Uy4vNeHNvCZqpnFrlKXubVVbZ2LL4UBmkRyFg6ayIno/zHKHGGvhRIM4UW383jwASkTJRPZmWxUPgUNX78b4/tiHdP9wqp65BbJFPuUmPzUOY1dOx08VtkBvzRifIlmXjOSvIQoXw/5OOoNA4fvbr/Ik/6AzSUlZvV+zco7rnkcJYjBpBdXXIaebdfgRoy6pRrXoayZGuBmbCIxHi1m5bzn+vuxNDqr79G09nzUqDQKxx1YKrkTx7kzfxbNfgCV073vpP5tdmCVsnadIWB8P1j2zY5IC/LMpVF+Pi5tZrZSjCwDT8FJGkG87Fwtb4viVGM7bmXyAaqaPakPRd6lVNa4NBgC50Rctqigzi7gPx1oHPk9BaLFZnyqxgjjfFkYu4bV/N20Xd0fqZb09d8GAXgIjbQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DS7PR03MB5608.namprd03.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230001)(4636009)(366004)(6486002)(36756003)(2906002)(6512007)(66556008)(8676002)(4326008)(38100700002)(54906003)(508600001)(5660300002)(66946007)(66476007)(316002)(6916009)(6506007)(107886003)(6666004)(8936002)(1076003)(86362001)(2616005)(83380400001)(186003)(26005)(82960400001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?Ov/X+EgVqz5Q7PqwAyLaUFWGcE3A?= =?utf-8?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fc63QdMDYw50QkWGYEFqmS4z1bqDd5dsJlH2w5uQpuBcCb2j3STv?= =?utf-8?q?85k42WMhXSrdQ3b5KyCogKe28diQ/VlQkSd4tBpcggToBA/3kbE7ivT1I3QQsUIUE?= =?utf-8?q?KySU64mqAt06YmFO5R5gQuhDM1C6fk11jpDa9nddFbk+s0atK7tpBien7Bz3RAitV?= =?utf-8?q?yRuqjmI32yEBvuY8Ev8ZOQUbw7nh6pGlgoAWkBJ7s5YvRtsSuwdSNos9rvXkFKnsk?= =?utf-8?q?sKml1UouDaj4sc6tcIh7B4h1n9j0wf4YbLZap8JL2XNllRZft8IjuwdVg5D7mZxCf?= =?utf-8?q?8KqEyJqwHqjUBiGdFjM1yfWx/sEGXaE+vcHIIcAsdNtq0LYgWKS7wXo2hlQEuyVOy?= =?utf-8?q?Oy4NhtjEjCY5e11ibGQ9zqhXm0dgmujTCFMJbGyISZby54aJ59+Vnpp4iDm+dHoVA?= =?utf-8?q?PKU6nuGs6zpRtwPLYQ6RvXCS6a8/ASxPLZUXbLVzniYIjUJtHA22HpP5MsFjINHql?= =?utf-8?q?YrJ5A+SnqtftTLeb43ukpfxYnG3is1JfGmzKG3ainNWknAvxbKV4fcGcUB2wZGg6N?= =?utf-8?q?NGdGk1Ney280ON5IpJzqs3xb6/q5oKEHRud+cjQfKf2CQr4JAuIwgttHk14508dUl?= =?utf-8?q?wFB1akszNlXmsOcQ2YkgSLGs5AcDkGzUt/E1FnqRiPMXaMtDKdM/mKUcNrbJsc9zb?= =?utf-8?q?9kcPgVV6jvOyXnkh5rKRMLcQJjtuRWdhQO7VPmoZe1jcSw33XlwykuDrTRsZZ8zm4?= =?utf-8?q?zMMP2azsWQutdnWfDISio9ilTVol11qK/QzSv47sDNqNf7RkcTi14=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: af3af710-203d-4ec2-ffbc-08da1627af39 X-MS-Exchange-CrossTenant-AuthSource: DS7PR03MB5608.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Apr 2022 10:41:32.7257 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 335836de-42ef-43a2-b145-348c2ee9ca5b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: QJc3ASUxZoHqCTH1k+lHgtxityfP0FsoAUKpaGprDT+HRHNjqCGHWNF96zfcdWgvm5Oy0c0N6stY7N7Znuz1LQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR03MB4669 X-OriginatorOrg: citrix.com Setting the fcf-protection=none option in EMBEDDED_EXTRA_CFLAGS in the Makefile doesn't get it propagated to the subdirectories, so instead set the flag in firmware/Rules.mk, like it's done for other compiler flags. Fixes: 3667f7f8f7 ('x86: Introduce support for CET-IBT') Signed-off-by: Roger Pau Monné Reviewed-by: Anthony PERARD --- Changes since v1: - Add the option directly to CFLAGS using cc-option-add. --- tools/firmware/Makefile | 2 -- tools/firmware/Rules.mk | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/firmware/Makefile b/tools/firmware/Makefile index 53ed4f161e..345037b93b 100644 --- a/tools/firmware/Makefile +++ b/tools/firmware/Makefile @@ -6,8 +6,6 @@ TARGET := hvmloader/hvmloader INST_DIR := $(DESTDIR)$(XENFIRMWAREDIR) DEBG_DIR := $(DESTDIR)$(DEBUG_DIR)$(XENFIRMWAREDIR) -EMBEDDED_EXTRA_CFLAGS += -fcf-protection=none - SUBDIRS-y := SUBDIRS-$(CONFIG_OVMF) += ovmf-dir SUBDIRS-$(CONFIG_SEABIOS) += seabios-dir diff --git a/tools/firmware/Rules.mk b/tools/firmware/Rules.mk index 9f78a7dec9..c227fe2524 100644 --- a/tools/firmware/Rules.mk +++ b/tools/firmware/Rules.mk @@ -15,6 +15,8 @@ CFLAGS += -Werror $(call cc-options-add,CFLAGS,CC,$(EMBEDDED_EXTRA_CFLAGS)) +$(call cc-option-add,CFLAGS,CC,-fcf-protection=none) + # Extra CFLAGS suitable for an embedded type of environment. CFLAGS += -ffreestanding -msoft-float