Upstream fix for console regression, Fix for fallback.efi crash
This commit is contained in:
parent
b6c02ba2ca
commit
6209cab21a
152
IOMUX-Fix-buffer-overflow-in-iomux_replace_device.patch
Normal file
152
IOMUX-Fix-buffer-overflow-in-iomux_replace_device.patch
Normal file
@ -0,0 +1,152 @@
|
||||
From patchwork Sun Apr 25 23:08:03 2021
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 7bit
|
||||
X-Patchwork-Submitter: Yuichiro Goto <goto@k-tech.co.jp>
|
||||
X-Patchwork-Id: 1470141
|
||||
Return-Path: <u-boot-bounces@lists.denx.de>
|
||||
X-Original-To: incoming@patchwork.ozlabs.org
|
||||
Delivered-To: patchwork-incoming@bilbo.ozlabs.org
|
||||
Authentication-Results: ozlabs.org;
|
||||
spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de
|
||||
(client-ip=85.214.62.61; helo=phobos.denx.de;
|
||||
envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>)
|
||||
Authentication-Results: ozlabs.org;
|
||||
dkim=pass (2048-bit key;
|
||||
unprotected) header.d=k-tech-co-jp.20150623.gappssmtp.com
|
||||
header.i=@k-tech-co-jp.20150623.gappssmtp.com header.a=rsa-sha256
|
||||
header.s=20150623 header.b=aG2evrkI;
|
||||
dkim-atps=neutral
|
||||
Received: from phobos.denx.de (phobos.denx.de [85.214.62.61])
|
||||
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
|
||||
key-exchange X25519 server-signature RSA-PSS (4096 bits))
|
||||
(No client certificate requested)
|
||||
by ozlabs.org (Postfix) with ESMTPS id 4FT3cr5pLLz9sV5
|
||||
for <incoming@patchwork.ozlabs.org>; Mon, 26 Apr 2021 09:09:16 +1000 (AEST)
|
||||
Received: from h2850616.stratoserver.net (localhost [IPv6:::1])
|
||||
by phobos.denx.de (Postfix) with ESMTP id DAAE481FCD;
|
||||
Mon, 26 Apr 2021 01:09:09 +0200 (CEST)
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dmarc=none (p=none dis=none) header.from=k-tech.co.jp
|
||||
Authentication-Results: phobos.denx.de;
|
||||
spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dkim=pass (2048-bit key;
|
||||
unprotected) header.d=k-tech-co-jp.20150623.gappssmtp.com
|
||||
header.i=@k-tech-co-jp.20150623.gappssmtp.com header.b="aG2evrkI";
|
||||
dkim-atps=neutral
|
||||
Received: by phobos.denx.de (Postfix, from userid 109)
|
||||
id 1971382057; Mon, 26 Apr 2021 01:09:06 +0200 (CEST)
|
||||
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de
|
||||
X-Spam-Level:
|
||||
X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,
|
||||
DKIM_VALID,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2
|
||||
Received: from mail-pf1-x42a.google.com (mail-pf1-x42a.google.com
|
||||
[IPv6:2607:f8b0:4864:20::42a])
|
||||
(using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits))
|
||||
(No client certificate requested)
|
||||
by phobos.denx.de (Postfix) with ESMTPS id E883680EC1
|
||||
for <u-boot@lists.denx.de>; Mon, 26 Apr 2021 01:09:00 +0200 (CEST)
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dmarc=none (p=none dis=none) header.from=k-tech.co.jp
|
||||
Authentication-Results: phobos.denx.de;
|
||||
spf=none smtp.mailfrom=goto@k-tech.co.jp
|
||||
Received: by mail-pf1-x42a.google.com with SMTP id h11so6707950pfn.0
|
||||
for <u-boot@lists.denx.de>; Sun, 25 Apr 2021 16:09:00 -0700 (PDT)
|
||||
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
|
||||
d=k-tech-co-jp.20150623.gappssmtp.com; s=20150623;
|
||||
h=from:to:cc:subject:date:message-id;
|
||||
bh=ToYmsqKBzr3zTVvJdRjIX1oCqkuII+g2LxuLKTcyCm4=;
|
||||
b=aG2evrkIlEWR+2+O4uf7Z5Z5dADCoHUqUfa4wv2uGZq16LXSZXAfr96QVEaI+Ysrq9
|
||||
S1Wd+94g29kp+qnFc4wLcMUomaZnm0eH+oliBgyqOH/LAB8n7c8avUhcTMJA60McRjeb
|
||||
lMsHOX4LwDCbN9Nem+kDEPLIGsYIlg4bQczceWdlw5oHTMNRrj3uqSx1S52Y2xVo9Tl2
|
||||
fGiB75T4OGHlO+4ZfXl6Ky1Q6j8eRAp0ysfO9ZY/SjDd8dFowmDn8nCU3Bmy4boJaiK9
|
||||
uBxgI8S7h0uSltG+o8KcszPN/fpi2H8oBFuia8kJ1X/mrQ9AK4+n9jA4m5XlsXuyJYon
|
||||
NSNA==
|
||||
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;
|
||||
bh=ToYmsqKBzr3zTVvJdRjIX1oCqkuII+g2LxuLKTcyCm4=;
|
||||
b=idcco1cmfR9jg46QoNPi2i5Xp7KywMSugg82Gr+a6q2d+z8Y0bAWm69vVvCv27OuBe
|
||||
EqSikfaPx616hVlE2JSRYhiQjTAkRivx+HbZTOo88Ud3nFuZSye7IzWVgTJQfYeMwk2t
|
||||
ur3IC3wNHP8ZJZd7/ncR5bQtEH1dnQnntzZ/ObcQ2qYD7tE8i3XirP+t6bEXgfve6l3z
|
||||
h8uhRhUdonx3My77SfoguPZ7agogNuJwKDxEOv2AiQC+sgi6hMSoCM5I/CTY5XBXWBcG
|
||||
DsVq6CFis7XI0q4vT+fJnobTZcY+apdx6CQgbTHscvNNANNVQTcW4AmZtdMU00Py7rwl
|
||||
+dlw==
|
||||
X-Gm-Message-State: AOAM530gSI6IYWTUQZeEHkOvsFu+rBGyB3fBUHY4LPk43shM1KC4uXnK
|
||||
KlhhaOqM5unov+ya4+knemWrDiRXPLvgHgVJ
|
||||
X-Google-Smtp-Source:
|
||||
ABdhPJz3Z6j4z6TV4bjvrr75pCyOMhSLC37qICUXTZOgOyojVAW7AH0TT24BTcUVdx8V5n2RwnQzBA==
|
||||
X-Received: by 2002:a62:8c8c:0:b029:253:31e:55cb with SMTP id
|
||||
m134-20020a628c8c0000b0290253031e55cbmr14541132pfd.27.1619392138942;
|
||||
Sun, 25 Apr 2021 16:08:58 -0700 (PDT)
|
||||
Received: from lubuntu1804.flets-east.jp (p1086-maru1shinjuku.tokyo.ocn.ne.jp.
|
||||
[61.208.220.86])
|
||||
by smtp.gmail.com with ESMTPSA id i63sm9669769pfg.112.2021.04.25.16.08.57
|
||||
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
|
||||
Sun, 25 Apr 2021 16:08:58 -0700 (PDT)
|
||||
From: Yuichiro Goto <goto@k-tech.co.jp>
|
||||
To: u-boot@lists.denx.de
|
||||
Cc: Yuichiro Goto <goto@k-tech.co.jp>, Peter Robinson <pbrobinson@gmail.com>,
|
||||
Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
|
||||
Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
|
||||
Subject: [PATCH v3] IOMUX: Fix buffer overflow in iomux_replace_device()
|
||||
Date: Mon, 26 Apr 2021 08:08:03 +0900
|
||||
Message-Id: <20210425230803.3055-1-goto@k-tech.co.jp>
|
||||
X-Mailer: git-send-email 2.17.1
|
||||
X-BeenThere: u-boot@lists.denx.de
|
||||
X-Mailman-Version: 2.1.34
|
||||
Precedence: list
|
||||
List-Id: U-Boot discussion <u-boot.lists.denx.de>
|
||||
List-Unsubscribe: <https://lists.denx.de/options/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>
|
||||
List-Archive: <https://lists.denx.de/pipermail/u-boot/>
|
||||
List-Post: <mailto:u-boot@lists.denx.de>
|
||||
List-Help: <mailto:u-boot-request@lists.denx.de?subject=help>
|
||||
List-Subscribe: <https://lists.denx.de/listinfo/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=subscribe>
|
||||
Errors-To: u-boot-bounces@lists.denx.de
|
||||
Sender: "U-Boot" <u-boot-bounces@lists.denx.de>
|
||||
X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de
|
||||
X-Virus-Status: Clean
|
||||
|
||||
Use of strcat() against an uninitialized buffer would lead
|
||||
to buffer overflow. This patch fixes it.
|
||||
|
||||
Fixes: 694cd5618c ("IOMUX: Introduce iomux_replace_device()")
|
||||
Signed-off-by: Yuichiro Goto <goto@k-tech.co.jp>
|
||||
Cc: Peter Robinson <pbrobinson@gmail.com>
|
||||
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
|
||||
Cc: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
|
||||
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
|
||||
---
|
||||
|
||||
Changes for v3:
|
||||
- Add a Fixes tag in commit message
|
||||
- Refactor the patch per suggestion from Andy Shevchenko
|
||||
|
||||
Changes for v2:
|
||||
- Add "IOMUX" in title
|
||||
|
||||
common/iomux.c | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/common/iomux.c b/common/iomux.c
|
||||
index b9088aa3b5..c428f7110a 100644
|
||||
--- a/common/iomux.c
|
||||
+++ b/common/iomux.c
|
||||
@@ -158,8 +158,12 @@ int iomux_replace_device(const int console, const char *old, const char *new)
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
- strcat(tmp, ",");
|
||||
- strcat(tmp, name);
|
||||
+ if (arg) {
|
||||
+ strcat(tmp, ",");
|
||||
+ strcat(tmp, name);
|
||||
+ }
|
||||
+ else
|
||||
+ strcpy(tmp, name);
|
||||
|
||||
arg = tmp;
|
||||
size = strlen(tmp) + 1;
|
@ -1,55 +0,0 @@
|
||||
From 5cb853e7f78391595a0e3b01ef5dd877e169463b Mon Sep 17 00:00:00 2001
|
||||
From: Peter Robinson <pbrobinson@gmail.com>
|
||||
Date: Wed, 21 Apr 2021 16:03:07 +0100
|
||||
Subject: [PATCH] Revert "usb: kbd: destroy device after console is stopped"
|
||||
|
||||
This reverts commit eb5fd9e46c11ea41430d9c5bcc81d4583424216e.
|
||||
---
|
||||
common/usb_kbd.c | 16 ++++++++--------
|
||||
1 file changed, 8 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/common/usb_kbd.c b/common/usb_kbd.c
|
||||
index afad260d3d..515f37136f 100644
|
||||
--- a/common/usb_kbd.c
|
||||
+++ b/common/usb_kbd.c
|
||||
@@ -622,12 +622,12 @@ int usb_kbd_deregister(int force)
|
||||
if (dev) {
|
||||
usb_kbd_dev = (struct usb_device *)dev->priv;
|
||||
data = usb_kbd_dev->privptr;
|
||||
+ if (stdio_deregister_dev(dev, force) != 0)
|
||||
+ return 1;
|
||||
#if CONFIG_IS_ENABLED(CONSOLE_MUX)
|
||||
- if (iomux_replace_device(stdin, DEVNAME, force ? "nulldev" : ""))
|
||||
+ if (iomux_doenv(stdin, env_get("stdin")) != 0)
|
||||
return 1;
|
||||
#endif
|
||||
- if (stdio_deregister_dev(dev, force) != 0)
|
||||
- return 1;
|
||||
#ifdef CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE
|
||||
destroy_int_queue(usb_kbd_dev, data->intq);
|
||||
#endif
|
||||
@@ -665,16 +665,16 @@ static int usb_kbd_remove(struct udevice *dev)
|
||||
goto err;
|
||||
}
|
||||
data = udev->privptr;
|
||||
+ if (stdio_deregister_dev(sdev, true)) {
|
||||
+ ret = -EPERM;
|
||||
+ goto err;
|
||||
+ }
|
||||
#if CONFIG_IS_ENABLED(CONSOLE_MUX)
|
||||
- if (iomux_replace_device(stdin, DEVNAME, "nulldev")) {
|
||||
+ if (iomux_doenv(stdin, env_get("stdin"))) {
|
||||
ret = -ENOLINK;
|
||||
goto err;
|
||||
}
|
||||
#endif
|
||||
- if (stdio_deregister_dev(sdev, true)) {
|
||||
- ret = -EPERM;
|
||||
- goto err;
|
||||
- }
|
||||
#ifdef CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE
|
||||
destroy_int_queue(udev, data->intq);
|
||||
#endif
|
||||
--
|
||||
2.31.1
|
||||
|
@ -0,0 +1,211 @@
|
||||
From patchwork Wed Apr 28 13:54:01 2021
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 8bit
|
||||
X-Patchwork-Submitter: "Peng Fan (OSS)" <peng.fan@oss.nxp.com>
|
||||
X-Patchwork-Id: 1471143
|
||||
Return-Path: <u-boot-bounces@lists.denx.de>
|
||||
X-Original-To: incoming@patchwork.ozlabs.org
|
||||
Delivered-To: patchwork-incoming@bilbo.ozlabs.org
|
||||
Authentication-Results: ozlabs.org;
|
||||
spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de
|
||||
(client-ip=85.214.62.61; helo=phobos.denx.de;
|
||||
envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>)
|
||||
Authentication-Results: ozlabs.org;
|
||||
dkim=pass (1024-bit key;
|
||||
unprotected) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com
|
||||
header.a=rsa-sha256 header.s=selector2-NXP1-onmicrosoft-com
|
||||
header.b=Y9LhgRit;
|
||||
dkim-atps=neutral
|
||||
Received: from phobos.denx.de (phobos.denx.de [85.214.62.61])
|
||||
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
|
||||
key-exchange X25519 server-signature RSA-PSS (4096 bits))
|
||||
(No client certificate requested)
|
||||
by ozlabs.org (Postfix) with ESMTPS id 4FVfRz6xNvz9sW6
|
||||
for <incoming@patchwork.ozlabs.org>; Wed, 28 Apr 2021 23:22:07 +1000 (AEST)
|
||||
Received: from h2850616.stratoserver.net (localhost [IPv6:::1])
|
||||
by phobos.denx.de (Postfix) with ESMTP id 0143180EC0;
|
||||
Wed, 28 Apr 2021 15:22:01 +0200 (CEST)
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dmarc=none (p=none dis=none) header.from=oss.nxp.com
|
||||
Authentication-Results: phobos.denx.de;
|
||||
spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dkim=pass (1024-bit key;
|
||||
unprotected) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com
|
||||
header.b="Y9LhgRit";
|
||||
dkim-atps=neutral
|
||||
Received: by phobos.denx.de (Postfix, from userid 109)
|
||||
id 11DCC80EC0; Wed, 28 Apr 2021 15:22:00 +0200 (CEST)
|
||||
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de
|
||||
X-Spam-Level:
|
||||
X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,
|
||||
DKIM_VALID,FORGED_SPF_HELO,MSGID_FROM_MTA_HEADER,SPF_HELO_PASS
|
||||
autolearn=no autolearn_force=no version=3.4.2
|
||||
Received: from EUR05-VI1-obe.outbound.protection.outlook.com
|
||||
(mail-vi1eur05on20614.outbound.protection.outlook.com
|
||||
[IPv6:2a01:111:f400:7d00::614])
|
||||
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
|
||||
(No client certificate requested)
|
||||
by phobos.denx.de (Postfix) with ESMTPS id BF2AE82BB2
|
||||
for <u-boot@lists.denx.de>; Wed, 28 Apr 2021 15:21:56 +0200 (CEST)
|
||||
Authentication-Results: phobos.denx.de;
|
||||
dmarc=none (p=none dis=none) header.from=oss.nxp.com
|
||||
Authentication-Results: phobos.denx.de;
|
||||
spf=pass smtp.mailfrom=peng.fan@oss.nxp.com
|
||||
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;
|
||||
b=Ykl/b+bOscXPccjkBLrnNZ64DLu+6jcykHxXg6zp1iRDn9PjYn5sAB9UzpDwBH/KBFvrw3JDaJE3H5KE1MYt/qTuXtPsUxfuHlok2cGYHW9QtYf5hVHXeWQ2CEuFUsTXn0wkc/UWBAqubidQx/AHfKQCT2TtJgSzsiaS+s0Q4xEfkByM49AF5KbOQ9dfEBqQgcpjjCPO5870sdVmZGUbHH2Alvo3NxlPP1gWLM0yVNN33b5BUxMiBgkiycAt1eN1V5lqmhkzB2i8LrKv8X+8P9n41oowUuqt0Qaai6eYOhg+bhNaZbrEUdcI47KRm5hpg1pk0sYYw+IeXo4P9EmhGg==
|
||||
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=Jvu1xYFUKJO/uJlsI76lQFrPlpRTiU+rjukLralExi8=;
|
||||
b=fZLxEM4upa8xSPDRUr7ha1FAI2UY44OO4z3vEc15uhQcMMwddhIvqbEAMyJ9CfOjnAN3K8FzmE8uZAb5U7qqT9NqOlK0sVsPLb6rXRAIlj2lDUoPPwQ0LAzKA1A8ADxTEGJZhcy+s60JQ2mmPMgg8wf7ybi3YOHnV972Ai8EJT0dCJeEMbWJ2CjRtWZqpLyDujovr8w82q2vXpFPXMp/krwklqtTdlGxgKP9ZMU+2n0SGvqBTcXts/cE+XxraFrOTth/rdLrqKtKXGjbGGN9bW0cNJWzmYMFBwR8oU27Ygr0FZ7GFqW7pGdPaGkfjsbkqvS+8P9/4qBo208dUryMZg==
|
||||
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass
|
||||
smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com;
|
||||
dkim=pass header.d=oss.nxp.com; arc=none
|
||||
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com;
|
||||
s=selector2-NXP1-onmicrosoft-com;
|
||||
h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;
|
||||
bh=Jvu1xYFUKJO/uJlsI76lQFrPlpRTiU+rjukLralExi8=;
|
||||
b=Y9LhgRit5KPyFtT5AVfHzHnlc9O6Ssk9T3mI7BThr15G7JYL8xyLUH1Yx3UmVl57Rvgz1z8yMTCtLyhHB3Xbw82ysiOO8JpHAM1U20AXO2mAew0td3xOPWJ7aDBS2NBdGmkM4PG9WfYlpl8TzsMDJNfjpNWiID6ykA2/FGS3Krg=
|
||||
Authentication-Results: gmx.de; dkim=none (message not signed)
|
||||
header.d=none;gmx.de; dmarc=none action=none header.from=oss.nxp.com;
|
||||
Received: from AM5PR0402MB2756.eurprd04.prod.outlook.com
|
||||
(2603:10a6:203:99::22) by AM6PR0402MB3525.eurprd04.prod.outlook.com
|
||||
(2603:10a6:209:4::14) with Microsoft SMTP Server (version=TLS1_2,
|
||||
cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4087.25; Wed, 28 Apr
|
||||
2021 13:21:55 +0000
|
||||
Received: from AM5PR0402MB2756.eurprd04.prod.outlook.com
|
||||
([fe80::b158:2ae5:f2d1:7142]) by AM5PR0402MB2756.eurprd04.prod.outlook.com
|
||||
([fe80::b158:2ae5:f2d1:7142%9]) with mapi id 15.20.4065.027; Wed, 28 Apr 2021
|
||||
13:21:55 +0000
|
||||
From: "Peng Fan (OSS)" <peng.fan@oss.nxp.com>
|
||||
To: xypron.glpk@gmx.de,
|
||||
agraf@csgraf.de
|
||||
Cc: u-boot@lists.denx.de, pbrobinson@redhat.com, grant.likely@arm.com,
|
||||
Peng Fan <peng.fan@nxp.com>,
|
||||
=?utf-8?q?Stefan_S=C3=B8rensen?= <stefan.sorensen@spectralink.com>,
|
||||
Peter Robinson <pbrobinson@gmail.com>
|
||||
Subject: [PATCH V2] efi_loader: loosen buffer parameter check in
|
||||
efi_file_read_int
|
||||
Date: Wed, 28 Apr 2021 21:54:01 +0800
|
||||
Message-Id: <20210428135401.22365-1-peng.fan@oss.nxp.com>
|
||||
X-Mailer: git-send-email 2.30.0
|
||||
X-Originating-IP: [119.31.174.71]
|
||||
X-ClientProxiedBy: HK2PR0302CA0020.apcprd03.prod.outlook.com
|
||||
(2603:1096:202::30) To AM5PR0402MB2756.eurprd04.prod.outlook.com
|
||||
(2603:10a6:203:99::22)
|
||||
MIME-Version: 1.0
|
||||
X-MS-Exchange-MessageSentRepresentingType: 1
|
||||
Received: from linux-1xn6.ap.freescale.net (119.31.174.71) by
|
||||
HK2PR0302CA0020.apcprd03.prod.outlook.com (2603:1096:202::30) with Microsoft
|
||||
SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
|
||||
15.20.4087.16 via Frontend Transport; Wed, 28 Apr 2021 13:21:52 +0000
|
||||
X-MS-PublicTrafficType: Email
|
||||
X-MS-Office365-Filtering-Correlation-Id: d16d4712-33ca-4f2f-49cf-08d90a489784
|
||||
X-MS-TrafficTypeDiagnostic: AM6PR0402MB3525:
|
||||
X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True
|
||||
X-MS-Exchange-Transport-Forked: True
|
||||
X-Microsoft-Antispam-PRVS:
|
||||
<AM6PR0402MB35250A339D51FF374D7AE862C9409@AM6PR0402MB3525.eurprd04.prod.outlook.com>
|
||||
X-MS-Oob-TLC-OOBClassifiers: OLM:1091;
|
||||
X-MS-Exchange-SenderADCheck: 1
|
||||
X-Microsoft-Antispam: BCL:0;
|
||||
X-Microsoft-Antispam-Message-Info:
|
||||
R8IIzR87BJ9qITheAW0/6SscIznIBDQntrQKYiITRtr3RZNBHPGuiexfqYuAABypLYa20Kpjk8qwFtkVl5Wv9zswD2NHqy5w+BU9PNQDIw5/spSSuSNZKUBD9L1rsFxNX+pluafaP2yEzJ09OmA1rGVbLC8uc0VtwPFvuyXoPYvMI8nbxEuX8eVVs8oz6i8qTLMzAKJS7PgYVwBQQjkqPEAwfnkSibtgFyy2rBjeD18PGmRSKqwkNWkO7w3bBkj/7Zor9h/8j8w07q+Iq/ZU1Mlbm8USlj2VCmhqkJddRE7/Jj0NMfQLQJ3zZABeONnYzgAUfyXXQb4sxuuM+nqRwyW/oASjsumXU4sApadRppYdLqA2uxrvM7HduDA16u1YIOc7exaHsHSuZm3p0jnKSbUkDWki3YwYZYKuOSAhwVnxIFzdFO331d/JoJnvCPulh43Bf2ndcJ+Fi6UK/BPtUCHjzSvXm5SWO2YlsNW6EAQf/teSOpYzo6jQT3QLS5InHcfHTUBcF7z7679ht2IGrNZZc2gq/Z5eCppzp33pHTx+R+wqWt+vDU8+iho2jR4+UoTTC2VanZ8dprckWpPXxgtPq6ZbkmFKjdql5ZZWwMfKu/0DaKI+T0Qcrgo5BUNETfCuDu48gBkMrs+ewk5JWR4u9Dwgq605ea1ydic2+X7SoTc/ZQ1mnr+P5IBaTsdJxE4rLVKGAo5HZcS7X6t2b9RSQz2CTskNOlg9t+2XE0zvDc19T8CF6rTS8DkG4yQa
|
||||
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;
|
||||
IPV:NLI; SFV:NSPM; H:AM5PR0402MB2756.eurprd04.prod.outlook.com; PTR:;
|
||||
CAT:NONE;
|
||||
SFS:(4636009)(136003)(39860400002)(376002)(366004)(396003)(346002)(38100700002)(38350700002)(478600001)(5660300002)(6506007)(6666004)(66574015)(26005)(6486002)(86362001)(956004)(66476007)(2906002)(16526019)(83380400001)(6512007)(1076003)(8676002)(966005)(54906003)(186003)(52116002)(66556008)(66946007)(4326008)(316002)(2616005)(8936002);
|
||||
DIR:OUT; SFP:1101;
|
||||
X-MS-Exchange-AntiSpam-MessageData: =?utf-8?q?mYfVlOJMJVsoKYMLc92rFnaCTR+XLQ?=
|
||||
=?utf-8?q?NE9Fknv0C/Xkfupn634/z0PDINPn1vwI7UBh2GXDundoV+tDpV3/J9Ao+ZaklGBv/?=
|
||||
=?utf-8?q?35YvbogOLThhUOpbrxM2+PmyMASh2BwZQm4j3DtGuxerW2benG82zAGjtAJ70va+R?=
|
||||
=?utf-8?q?fdHJfMOIDL+Oxkvqa8F1tiAWyVebMmTb9LvZQdnkJtClzsGEsN7JuXzN5zAG9JnDk?=
|
||||
=?utf-8?q?ptt4s0xR8Tngwj+0ktYv/WIYfWbyVRKt2cGY+IbfGzOgHeeR/6msyKEXY6EKxdrGp?=
|
||||
=?utf-8?q?ddqp/uOGuH2BlhbQtqWthQJBCUI+HaR7mZgiEJctgT+rWAgDrZMTtvzQT/2TTs+4L?=
|
||||
=?utf-8?q?Pqu1h8tKSW3diXo+rqN1splk5PQ0rbM9pPZECBGS/9KWkqZOCtKtGQWbDf1N4t/tX?=
|
||||
=?utf-8?q?jJ+JS/eOy0dBvhEmZ6tbCB5HpkLj/GbwlXsIm6aJbCXmd7hGzt+B9avRbm6uYmrHx?=
|
||||
=?utf-8?q?xMBLr/kYUvivhGCUqFEuApHEUlG6yVU6rFPTtzXtE9aYWlsF+IFI0YAUfgmi5X3c4?=
|
||||
=?utf-8?q?fvpdyhxyz0g5S58VT2SXLiBxvhwRX/5stsFvKurZjoTi5m7GkFJlzD3JpY5tikAgx?=
|
||||
=?utf-8?q?S48dfUkcZRBLJKtpJln7kGQ4yCyuxkJfyN+4VDmIEUQgWmSGwo0Z77B/A1lYejj+p?=
|
||||
=?utf-8?q?oC8BhkvFUTynlVzcft9BNfW3rQaTOoNFmU3wiIqRxDzWZfkL3tZroLTZJnDN6KOrK?=
|
||||
=?utf-8?q?2xERgFeiItx0xafXIOmUEnPoWUY1jtqv7qdVGy2HyJ6Us3tI8KNIL/Ezl9Cl9Wm8F?=
|
||||
=?utf-8?q?Rh/qZG13p7g11rt+6Bue1jxVckObYlnLPUzuAa2ZzqB1gZjXKKXDgS9eSsr+1aDjv?=
|
||||
=?utf-8?q?0MZCYmHZIBgmkKI0oNiqOWuzYI3T3ofJ2RT1TKthFErEJu0dZAZH1O2YxGlEpXKzH?=
|
||||
=?utf-8?q?eahQ8Zr/xhS85QykeKLXr+XKvURNH/yiY4KETT/kTq5BXPjIDIHtKaa3UnE8DTaew?=
|
||||
=?utf-8?q?aqy7YoDaolXatDKpuLa9E9CwRbrN2D38XwteMWDd5zCLvLZ+g7+pUjtqyoHs5lXbv?=
|
||||
=?utf-8?q?Tqb2DmK8tr3nMHzx5370ZV+bfbKvyqEECHE+AyXyb94GtEQaYgatdcI61SuVO82ZW?=
|
||||
=?utf-8?q?imQgBtq9BAdYABcHPMBpe4BuiQZRO2VdwtaUrLAZc4xyFTPnrnqM0ajr5/9bMQ4Qd?=
|
||||
=?utf-8?q?Ar+eZL4d88AuBRbax/JmKGSxLCxUVyAjXtrcEnoibNf1yLZlcgAp8kEaK1mMOh2B7?=
|
||||
=?utf-8?q?UflHobGwDKQKgP5I34mBssnm96TCDU6t+rHhProt6OgOKQPoQ5gmKvQx5CBsVuTA0?=
|
||||
=?utf-8?q?3gJ4gCfW4myFky?=
|
||||
X-OriginatorOrg: oss.nxp.com
|
||||
X-MS-Exchange-CrossTenant-Network-Message-Id:
|
||||
d16d4712-33ca-4f2f-49cf-08d90a489784
|
||||
X-MS-Exchange-CrossTenant-AuthSource:
|
||||
AM5PR0402MB2756.eurprd04.prod.outlook.com
|
||||
X-MS-Exchange-CrossTenant-AuthAs: Internal
|
||||
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Apr 2021 13:21:54.9886 (UTC)
|
||||
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
|
||||
X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635
|
||||
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
|
||||
X-MS-Exchange-CrossTenant-UserPrincipalName:
|
||||
kJtC/i3wLmUtXCoTbf/Jg1qhdz4MvWusai7Piwigv6OEGOknbKvDpIUrRwJMUXhNsSApid+ni8lC5sO+x5y30w==
|
||||
X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR0402MB3525
|
||||
X-BeenThere: u-boot@lists.denx.de
|
||||
X-Mailman-Version: 2.1.34
|
||||
Precedence: list
|
||||
List-Id: U-Boot discussion <u-boot.lists.denx.de>
|
||||
List-Unsubscribe: <https://lists.denx.de/options/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>
|
||||
List-Archive: <https://lists.denx.de/pipermail/u-boot/>
|
||||
List-Post: <mailto:u-boot@lists.denx.de>
|
||||
List-Help: <mailto:u-boot-request@lists.denx.de?subject=help>
|
||||
List-Subscribe: <https://lists.denx.de/listinfo/u-boot>,
|
||||
<mailto:u-boot-request@lists.denx.de?subject=subscribe>
|
||||
Errors-To: u-boot-bounces@lists.denx.de
|
||||
Sender: "U-Boot" <u-boot-bounces@lists.denx.de>
|
||||
X-Virus-Scanned: clamav-milter 0.102.4 at phobos.denx.de
|
||||
X-Virus-Status: Clean
|
||||
|
||||
From: Peng Fan <peng.fan@nxp.com>
|
||||
|
||||
This is same issue as https://bugzilla.redhat.com/show_bug.cgi?id=1733817,
|
||||
but that fix was wrongly partial reverted.
|
||||
|
||||
When reading a directory, EFI_BUFFER_TOO_SMALL should be returned when
|
||||
the supplied buffer is too small, so a use-case is to call
|
||||
EFI_FILE_PROTOCOL.Read() with *buffer_size=0 and buffer=NULL to
|
||||
obtain the needed size before doing the actual read.
|
||||
|
||||
So remove the check only for directory reading, file reading already
|
||||
do the check by itself.
|
||||
|
||||
Fixes: db12f518edb0("efi_loader: implement non-blocking file services")
|
||||
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
|
||||
Cc: Stefan Sørensen <stefan.sorensen@spectralink.com>
|
||||
Tested-by: Peter Robinson <pbrobinson@gmail.com>
|
||||
Signed-off-by: Peng Fan <peng.fan@nxp.com>
|
||||
---
|
||||
|
||||
V2:
|
||||
Update commit log Per Heinrich's comments.
|
||||
Add T-b tag
|
||||
|
||||
lib/efi_loader/efi_file.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/lib/efi_loader/efi_file.c b/lib/efi_loader/efi_file.c
|
||||
index 204105e25a..6b3f5962be 100644
|
||||
--- a/lib/efi_loader/efi_file.c
|
||||
+++ b/lib/efi_loader/efi_file.c
|
||||
@@ -554,7 +554,7 @@ static efi_status_t efi_file_read_int(struct efi_file_handle *this,
|
||||
efi_status_t ret = EFI_SUCCESS;
|
||||
u64 bs;
|
||||
|
||||
- if (!this || !buffer_size || !buffer)
|
||||
+ if (!this || !buffer_size)
|
||||
return EFI_INVALID_PARAMETER;
|
||||
|
||||
bs = *buffer_size;
|
@ -2,7 +2,7 @@
|
||||
|
||||
Name: uboot-tools
|
||||
Version: 2021.04
|
||||
Release: 2%{?candidate:.%{candidate}}%{?dist}
|
||||
Release: 3%{?candidate:.%{candidate}}%{?dist}
|
||||
Summary: U-Boot utilities
|
||||
License: GPLv2+ BSD LGPL-2.1+ LGPL-2.0+
|
||||
URL: http://www.denx.de/wiki/U-Boot
|
||||
@ -16,13 +16,13 @@ Source4: aarch64-chromebooks
|
||||
# Fedoraisms patches
|
||||
# Needed to find DT on boot partition that's not the first partition
|
||||
Patch1: uefi-distro-load-FDT-from-any-partition-on-boot-device.patch
|
||||
# Needed due to issues with shim
|
||||
Patch2: uefi-use-Fedora-specific-path-name.patch
|
||||
# https://lists.denx.de/pipermail/u-boot/2021-April/448260.html
|
||||
Patch2: efi_loader-loosen-buffer-parameter-check-in-efi_file_read_int.patch
|
||||
# RPi - uses RPI firmware device tree for HAT support
|
||||
Patch3: rpi-Enable-using-the-DT-provided-by-the-Raspberry-Pi.patch
|
||||
|
||||
# Revert an upstream regression
|
||||
Patch9: Revert-usb-kbd-destroy-device-after-console-is-stopp.patch
|
||||
Patch9: IOMUX-Fix-buffer-overflow-in-iomux_replace_device.patch
|
||||
# Board fixes and enablement
|
||||
# AllWinner improvements
|
||||
Patch10: AllWinner-PineTab.patch
|
||||
@ -261,6 +261,10 @@ cp -p board/warp7/README builds/docs/README.warp7
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Wed Apr 28 2021 Peter Robinson <pbrobinson@fedoraproject.org> - 2021.04-3
|
||||
- Upstream fix for console regression (rhbz 1946278)
|
||||
- Fix for fallback.efi crash (rhbz 1733817)
|
||||
|
||||
* Wed Apr 21 2021 Peter Robinson <pbrobinson@fedoraproject.org> - 2021.04-2
|
||||
- Revert keyboard console regression change (rhbz 1946278)
|
||||
|
||||
|
@ -1,50 +0,0 @@
|
||||
From 308c4ac71c439b483bd69ed9e387cc1a56566af9 Mon Sep 17 00:00:00 2001
|
||||
From: Peter Robinson <pbrobinson@gmail.com>
|
||||
Date: Mon, 8 Feb 2021 10:11:39 +0000
|
||||
Subject: [PATCH] use Fedora specific EFI path/name
|
||||
|
||||
Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
|
||||
---
|
||||
include/config_distro_bootcmd.h | 10 +++++-----
|
||||
1 file changed, 5 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h
|
||||
index 3d186b6d20..eda57e1707 100644
|
||||
--- a/include/config_distro_bootcmd.h
|
||||
+++ b/include/config_distro_bootcmd.h
|
||||
@@ -92,9 +92,9 @@
|
||||
|
||||
#ifdef CONFIG_EFI_LOADER
|
||||
#if defined(CONFIG_ARM64)
|
||||
-#define BOOTEFI_NAME "bootaa64.efi"
|
||||
+#define BOOTEFI_NAME "grubaa64.efi"
|
||||
#elif defined(CONFIG_ARM)
|
||||
-#define BOOTEFI_NAME "bootarm.efi"
|
||||
+#define BOOTEFI_NAME "grubarm.efi"
|
||||
#elif defined(CONFIG_X86_RUN_32BIT)
|
||||
#define BOOTEFI_NAME "bootia32.efi"
|
||||
#elif defined(CONFIG_X86_RUN_64BIT)
|
||||
@@ -140,7 +140,7 @@
|
||||
\
|
||||
"boot_efi_binary=" \
|
||||
"load ${devtype} ${devnum}:${distro_bootpart} " \
|
||||
- "${kernel_addr_r} efi/boot/"BOOTEFI_NAME"; " \
|
||||
+ "${kernel_addr_r} efi/fedora/"BOOTEFI_NAME"; " \
|
||||
"if fdt addr ${fdt_addr_r}; then " \
|
||||
"bootefi ${kernel_addr_r} ${fdt_addr_r};" \
|
||||
"else " \
|
||||
@@ -177,9 +177,9 @@
|
||||
"run boot_efi_binary\0" \
|
||||
"scan_dev_for_efi=" \
|
||||
"if test -e ${devtype} ${devnum}:${distro_bootpart} " \
|
||||
- "efi/boot/"BOOTEFI_NAME"; then " \
|
||||
+ "efi/fedora/"BOOTEFI_NAME"; then " \
|
||||
"echo Found EFI removable media binary " \
|
||||
- "efi/boot/"BOOTEFI_NAME"; " \
|
||||
+ "efi/fedora/"BOOTEFI_NAME"; " \
|
||||
"run scan_dev_for_dtb; " \
|
||||
"echo EFI LOAD FAILED: continuing...; " \
|
||||
"fi; " \
|
||||
--
|
||||
2.29.2
|
||||
|
Loading…
Reference in New Issue
Block a user