From patchwork Sun Dec 22 04:05:49 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 182365 Delivered-To: patch@linaro.org Received: by 2002:a92:1f98:0:0:0:0:0 with SMTP id f24csp2504217ilf; Sat, 21 Dec 2019 20:07:21 -0800 (PST) X-Google-Smtp-Source: APXvYqztO1LbYTzaEGMMIwqUzIqRAhCYaXt2uY+/axlLka3ytHwiUcDFzgFK5vjen01dWaCZsid4 X-Received: by 2002:a17:902:322:: with SMTP id 31mr24305576pld.244.1576987641187; Sat, 21 Dec 2019 20:07:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576987641; cv=none; d=google.com; s=arc-20160816; b=SPtynfOZgVTV3o9HRiTZPl2qMuW83/zwxU2yMSqyKyLX3CIFSIcc9by+hop6JFbnl2 3hLlONN2i3G7mmtgw/0HJa/p7I6NMzLOUD/8uFK/ZTyJ8FpnV6UA5k5O64oqfMSFnqlR XQjY5MnaaPYEqV0CIvVG3mJheD3hNMF2DAHjPdZYAz9FJIDV6Tia/3ZJT/vX2NRJZVwc C2P8Dm697us/iJCislyqRIpbDlIJ+TxhUsXzPl5AdT1ZWIBfz8jUMXXh8+u29kP3OocW Si6uMefbh1Cg6e7qDcMNRwzQstC6c+WekEpwSi6dsyaaMnIQDHhkB7sLFhYrgoUPlBk3 9nYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to; bh=y/bJE/Mp75YuSOZLfeP9Ix9qnrsQhdV854o2Os+IYyY=; b=GwskEk31Hhi4PCITPwmKF9sTCFC6PRrA9JgE9YGHwClGIy3OXEEOUaux6nTtudiMct GZhwP6Qij+lS04Jc9t5bxMGtRj35qlHCVnq9kxQhWPdcPRD9HfU+hkpLgQrOHciJy6oG 4U9oMfQh2QvuPFNPtF2iiDt8Y+K+3cET1/byO/Sugn+YMrP+Hqz7C3U/BAY0uSmee33K p3Btm/ADM7rXqFwOxasGBrzoc96WW4tKYW4GTdxq30wa6t/5tSa6ah3yfBBM55mwmVEm xOzW9DeK0vjhV8i8/YqEIZBo6LFEpaqQ7x2gcfzPFNmmGEEEkbbi8Tg3kJ2MxmqGkimL /oXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=Jb8LpbQR; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id 94si13746897ple.162.2019.12.21.20.07.20; Sat, 21 Dec 2019 20:07:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=Jb8LpbQR; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id 91B217FD00; Sun, 22 Dec 2019 04:07:14 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pj1-f65.google.com (mail-pj1-f65.google.com [209.85.216.65]) by mail.openembedded.org (Postfix) with ESMTP id 6CC8B7FCCD for ; Sun, 22 Dec 2019 04:05:59 +0000 (UTC) Received: by mail-pj1-f65.google.com with SMTP id j11so5919306pjs.1 for ; Sat, 21 Dec 2019 20:06:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=cVaMU03YXlA2ISyTCpdUFInwpj6K9UmhqFroGVnZdbA=; b=Jb8LpbQR0m/dBmXgsHDE4DhoEw3fEETXma2RpsLeby34g5z5/Om8Cj8RiOYYhTmTTa Pe3gOzLA3wLeWlKzxEwh3zNM6WzZmnpwOu3ZZ+2H6FvbdzwA9GPVMTvhd4TWh0wj6nuQ cOG2mZrP/BI/qziYDVyz0SU+cK3YzGYepaH+bbxsOzIoztLvwU0eLUxLvefpThcusbyy CrsnReA2ikzY54by2JNu1ULaPZB0WOugY/6E+8AZ7/kBczC3+PLn2n7EM/L7KnBlwxv1 0oqF6gyz/0OVBAHMTJGE252INPmRXM2kquu2KHicBLS4mgjsqNOqcKfcOMdVlnV5N5rj d5oQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=cVaMU03YXlA2ISyTCpdUFInwpj6K9UmhqFroGVnZdbA=; b=iGBaJsd69BJmyr43ePU0N6C8CCQhDDtuxjyK74ER/rl+RAfIBhAL05IV6LNgmJ9f6J CpAU2rFkP2zIPt4NKhzwAOBFALlshyjCSknlHy0UW4Xwi1cAZbn/YXX1Xt0P+oAznoFq RTQnhkyP+LiUBHaBpx2/Q3pUt2LeG22yNqvh5Gt7qeHo8OgyyleTDX4EY8hzBrqG9qOG OvBzBB8qc+61s/pOijnHtodEd83EBR3yajNnCOzyuzC7kshDcbz3I1QWqjdwxUInkBk/ gIeVdTn1hUBnPSNMosLW/QlaxQZ4S3ROpI50uBF778kk06iVraGDCdKna0UO9umTOsLK 2JQA== X-Gm-Message-State: APjAAAX3CUvmfkU5/zV+E0tNJK9gHT1HoBe1FSKC6R6QY8gjvcqt626I MrB+a2xbo5uzSakOplv1QrFYIOtI7DU= X-Received: by 2002:a17:90a:234f:: with SMTP id f73mr25908681pje.109.1576987560046; Sat, 21 Dec 2019 20:06:00 -0800 (PST) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9200:4e0::36e9]) by smtp.gmail.com with ESMTPSA id h16sm18988306pfn.85.2019.12.21.20.05.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Dec 2019 20:05:59 -0800 (PST) From: Khem Raj To: openembedded-core@lists.openembedded.org Date: Sat, 21 Dec 2019 20:05:49 -0800 Message-Id: <20191222040549.286151-4-raj.khem@gmail.com> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191222040549.286151-1-raj.khem@gmail.com> References: <20191222040549.286151-1-raj.khem@gmail.com> MIME-Version: 1.0 Subject: [OE-core] [PATCH 4/4] linux-yocto: Fix build with gcc10 X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org Signed-off-by: Khem Raj Cc: Bruce Ashfield --- ...sed-64-Define-__force_order-only-whe.patch | 42 +++++++++++++++++++ meta/recipes-kernel/linux/linux-yocto_5.2.bb | 2 + 2 files changed, 44 insertions(+) create mode 100644 meta/recipes-kernel/linux/files/0001-x86-boot-compressed-64-Define-__force_order-only-whe.patch -- 2.24.1 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-kernel/linux/files/0001-x86-boot-compressed-64-Define-__force_order-only-whe.patch b/meta/recipes-kernel/linux/files/0001-x86-boot-compressed-64-Define-__force_order-only-whe.patch new file mode 100644 index 0000000000..bd48de6dd9 --- /dev/null +++ b/meta/recipes-kernel/linux/files/0001-x86-boot-compressed-64-Define-__force_order-only-whe.patch @@ -0,0 +1,42 @@ +From 199caf12cdbe24796dc31fbd4fe5729ba2acf659 Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 20 Dec 2019 17:42:02 -0800 +Subject: [PATCH] x86/boot/compressed/64: Define __force_order only when + CONFIG_RANDOMIZE_BASE is unset + +kaslr_64.c also defines the same variable, however when both files are +included into final link, linker complains about multiple definition of +`__force_order' which is coming from kaslr_64.o and pgtable_64.o, its +possible that kaslr_64.o is disabled via CONFIG_RANDOMIZE_BASE config +option, therefore define it conditionally only when +CONFIG_RANDOMIZE_BASE is not set + +Signed-off-by: Khem Raj +Cc: Kirill A. Shutemov +Cc: Kees Cook +Cc: "H. Peter Anvin" +Cc: Ingo Molnar +Cc: Thomas Gleixner +Cc: x86-ml +Cc: Arnd Bergmann +--- + arch/x86/boot/compressed/pgtable_64.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/arch/x86/boot/compressed/pgtable_64.c b/arch/x86/boot/compressed/pgtable_64.c +index c8862696a47b..077d19268b0b 100644 +--- a/arch/x86/boot/compressed/pgtable_64.c ++++ b/arch/x86/boot/compressed/pgtable_64.c +@@ -12,7 +12,9 @@ + * It is not referenced from the code, but GCC < 5 with -fPIE would fail + * due to an undefined symbol. Define it to make these ancient GCCs work. + */ ++#ifndef CONFIG_RANDOMIZE_BASE + unsigned long __force_order; ++#endif + + #define BIOS_START_MIN 0x20000U /* 128K, less than this is insane */ + #define BIOS_START_MAX 0x9f000U /* 640K, absolute maximum */ +-- +2.24.1 + diff --git a/meta/recipes-kernel/linux/linux-yocto_5.2.bb b/meta/recipes-kernel/linux/linux-yocto_5.2.bb index ff0f547399..5af0924808 100644 --- a/meta/recipes-kernel/linux/linux-yocto_5.2.bb +++ b/meta/recipes-kernel/linux/linux-yocto_5.2.bb @@ -29,6 +29,8 @@ SRCREV_meta ?= "bd0762cd138f1624b5a5f8669cfa3ac2b71cb87b" SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.2;destsuffix=${KMETA}" +SRC_URI += "file://0001-x86-boot-compressed-64-Define-__force_order-only-whe.patch" + LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814" LINUX_VERSION ?= "5.2.20"