From patchwork Thu Oct 13 17:52:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 2215 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp410995wrs; Thu, 13 Oct 2022 11:07:47 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4nOMhxckX66uc67BSOzAm+eYkM/W+SuExBnS0fRLnCkvg1sMASraNF4vmELQFL9XBnqtla X-Received: by 2002:a65:45c1:0:b0:461:5855:8d86 with SMTP id m1-20020a6545c1000000b0046158558d86mr976161pgr.436.1665684466807; Thu, 13 Oct 2022 11:07:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665684466; cv=none; d=google.com; s=arc-20160816; b=OPbSwnwXVfLDEU2ZSgMPNlhti1HrurHn1Trs9wtIWlLqP2vA00kZF2TXALHiRkTfga HbJmwg+i5Vy+EzTAQG9b452DFK4u/IEns98hCu/2nfnzZVn1YWY89nG1uL/hlOYgjPlp uH7JcpOKrfdntHAEQhQIA2LwLVvCke5Fb+rVQ/tRVbjUYtPFGbLk+yBNbke0dv+VDEoS lq0+GvidVn+8ErYdXpfVnXFKUE/GAxtii4AIz9jBT1aBTQknPm6PURe50V2/PrUoVr1e 27uUs4ZqBlgLIede9tNMK2JpiuM7v5m3lB89QzUUpIrtxwvjHvG0yJA/ZFfHLifHwrlV Ed7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=z/hiobo4Tfv9x8gfSNE0FJT2rhT1ElDpRkjn0AubFJw=; b=nfa71zABIfdb4oydC+0Ub570np6YeAt28GrcNMnTQGTl0viruA8F/uzzpsANyRujT7 oW5KudSEwWkEnfXUkJUM0/59LRIp9PGNhrdNqmuDazalZZrvp4JuJva7SlUKY4Gu8mxw 3smOPPwlbIWWs/2iz4nxfcN5iSjK+RB5ia4ntpLtxK30trUU9TyxyXWuCu0GAUKxJxAP OEgGFb46p15/WIkeBocAaPqOovKflplNblhIqtXKoEeZx+y6glSfP0a5x8hL6WAr854w 0//dCEdunYlzC9hR1sKYUtD+XcBz6286bY8/NIca90WeO4Mb93mWXMBFOdEp/TxEAeiz ADcQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Pqqjf8If; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d5-20020a170902b70500b0017f7e1387easi437486pls.217.2022.10.13.11.07.33; Thu, 13 Oct 2022 11:07:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Pqqjf8If; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231564AbiJMSHT (ORCPT + 99 others); Thu, 13 Oct 2022 14:07:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38462 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231207AbiJMSFJ (ORCPT ); Thu, 13 Oct 2022 14:05:09 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C64B4157F45; Thu, 13 Oct 2022 11:04:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id BA9AA61941; Thu, 13 Oct 2022 17:59:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B1787C433C1; Thu, 13 Oct 2022 17:59:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1665683941; bh=R56tc7ab5Ae7BCl75vsYTgnxuRRQc6ZCGNdTc3leahg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Pqqjf8IfVdSiADsbvp0iwQ4PPMN6AXHEj/xv5dQalbAfsiB5fODVocU6PDuzmfrE3 TsMpLNvETAu4ghBHBXWbgesOj0XbSaYSCOUvI/nlp8HEz9qUh+n9gORewijKrO6zsL 5zAxyyqCQQ4FYQ7svXIHraWs7ien7IhzLpK6SkpM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Aditya Garg , Samuel Jiang , Orlando Chamberlain , Mimi Zohar Subject: [PATCH 5.19 11/33] efi: Correct Macmini DMI match in uefi cert quirk Date: Thu, 13 Oct 2022 19:52:43 +0200 Message-Id: <20221013175145.629145950@linuxfoundation.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221013175145.236739253@linuxfoundation.org> References: <20221013175145.236739253@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1746596755780045143?= X-GMAIL-MSGID: =?utf-8?q?1746596755780045143?= From: Orlando Chamberlain commit bab715bdaa9ebf28d99a6d1efb2704a30125e96d upstream. It turns out Apple doesn't capitalise the "mini" in "Macmini" in DMI, which is inconsistent with other model line names. Correct the capitalisation of Macmini in the quirk for skipping loading platform certs on T2 Macs. Currently users get: ------------[ cut here ]------------ [Firmware Bug]: Page fault caused by firmware at PA: 0xffffa30640054000 WARNING: CPU: 1 PID: 8 at arch/x86/platform/efi/quirks.c:735 efi_crash_gracefully_on_page_fault+0x55/0xe0 Modules linked in: CPU: 1 PID: 8 Comm: kworker/u12:0 Not tainted 5.18.14-arch1-2-t2 #1 4535eb3fc40fd08edab32a509fbf4c9bc52d111e Hardware name: Apple Inc. Macmini8,1/Mac-7BA5B2DFE22DDD8C, BIOS 1731.120.10.0.0 (iBridge: 19.16.15071.0.0,0) 04/24/2022 Workqueue: efi_rts_wq efi_call_rts ... ---[ end trace 0000000000000000 ]--- efi: Froze efi_rts_wq and disabled EFI Runtime Services integrity: Couldn't get size: 0x8000000000000015 integrity: MODSIGN: Couldn't get UEFI db list efi: EFI Runtime Services are disabled! integrity: Couldn't get size: 0x8000000000000015 integrity: Couldn't get UEFI dbx list Fixes: 155ca952c7ca ("efi: Do not import certificates from UEFI Secure Boot for T2 Macs") Cc: stable@vger.kernel.org Cc: Aditya Garg Tested-by: Samuel Jiang Signed-off-by: Orlando Chamberlain Signed-off-by: Mimi Zohar Signed-off-by: Greg Kroah-Hartman --- security/integrity/platform_certs/load_uefi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/security/integrity/platform_certs/load_uefi.c +++ b/security/integrity/platform_certs/load_uefi.c @@ -31,7 +31,7 @@ static const struct dmi_system_id uefi_s { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "MacBookAir8,1") }, { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "MacBookAir8,2") }, { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "MacBookAir9,1") }, - { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "MacMini8,1") }, + { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "Macmini8,1") }, { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "MacPro7,1") }, { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "iMac20,1") }, { UEFI_QUIRK_SKIP_CERT("Apple Inc.", "iMac20,2") },