From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 77287AC0F6D for ; Tue, 16 Jan 2024 10:21:44 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=xbqyqsSF9+mBJFIpbMunEEK1gdTkoagNHn/d7N74QTQ=; c=relaxed/simple; d=groups.io; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject:To:Cc:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Type; s=20140610; t=1705400503; v=1; b=gpRF1Rnx9eZuEb2gfumtBFHaYXrY8erwEjlrezbUbq2K1cxbnwc0LEzgG6TbmHvWlk7kZmqE Y+oiNTFaqSJBvvaLWMjDxVFS9Q5WY2wcDcKMoIETn6FECz8G2EdPPxZNfoJ0uzVjvXi0L+cmmfS qDNhbgQdmpOtQE7+OkeY/xMk= X-Received: by 127.0.0.2 with SMTP id RAoXYY7687511xXnUtXBztss; Tue, 16 Jan 2024 02:21:43 -0800 X-Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by mx.groups.io with SMTP id smtpd.web10.10162.1705400502208742719 for ; Tue, 16 Jan 2024 02:21:42 -0800 X-Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by ams.source.kernel.org (Postfix) with ESMTP id 0A108B80D31 for ; Tue, 16 Jan 2024 10:21:40 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 62641C43390 for ; Tue, 16 Jan 2024 10:21:39 +0000 (UTC) X-Received: by mail-lf1-f52.google.com with SMTP id 2adb3069b0e04-50e7ddd999bso10611505e87.1 for ; Tue, 16 Jan 2024 02:21:39 -0800 (PST) X-Gm-Message-State: izqjOdMBtSkubVono2bbwI9kx7686176AA= X-Google-Smtp-Source: AGHT+IHqbSrqyDNzjRMiZPLPtdIi7Z+dcBKpSshKcBaMQmbkVtIxCP3iD/t2EU66+fJFkJu6tOQ8c/uKlmwnmD40+K8= X-Received: by 2002:a05:6512:2348:b0:50e:95cf:e7b1 with SMTP id p8-20020a056512234800b0050e95cfe7b1mr4257195lfu.9.1705400497594; Tue, 16 Jan 2024 02:21:37 -0800 (PST) MIME-Version: 1.0 References: <20240112113754.14710-1-kraxel@redhat.com> <01ac5fab-2710-4231-a7cd-1c550fa6319f@redhat.com> In-Reply-To: From: "Ard Biesheuvel" Date: Tue, 16 Jan 2024 11:21:26 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [edk2-devel] [PATCH 0/4] OvmfPkg/VirtNorFlashDxe: fix corruption + misc small improvements To: Laszlo Ersek Cc: devel@edk2.groups.io, kraxel@redhat.com, Jiewen Yao , oliver@redhat.com Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,ardb@kernel.org List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Type: text/plain; charset="UTF-8" X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=gpRF1Rnx; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=kernel.org (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io On Tue, 16 Jan 2024 at 10:37, Laszlo Ersek wrote: > > On 1/15/24 18:56, Ard Biesheuvel wrote: > > On Mon, 15 Jan 2024 at 11:21, Laszlo Ersek wrote: > >> > >> On 1/12/24 12:37, Gerd Hoffmann wrote: > >>> This is a little series containing the flash corruption fix sent > >>> yesterday with an slightly improved commit message and some small > >>> improvements on top of this. > >>> > >>> Gerd Hoffmann (4): > >>> OvmfPkg/VirtNorFlashDxe: fix shadowbuffer reads > >>> OvmfPkg/VirtNorFlashDxe: clarify block write logic > >>> OvmfPkg/VirtNorFlashDxe: allow larger writes without block erase > >>> OvmfPkg/VirtNorFlashDxe: ValidateFvHeader: unwritten state is EOL too > >>> > >>> OvmfPkg/VirtNorFlashDxe/VirtNorFlash.c | 33 +++++++++++------------ > >>> OvmfPkg/VirtNorFlashDxe/VirtNorFlashFvb.c | 5 ++++ > >>> 2 files changed, 21 insertions(+), 17 deletions(-) > >>> > >> > >> Looking at the original code makes me throw a fit (no offense -- I don't > >> know who wrote it, and I don't want to check). > >> > > > > Hi Laszlo, > > > > I am not the author of the original code, but I suppose I should take > > at least some of the blame here, having added some of the logic to > > reduce the number of MMIO accesses (which are disproportionately > > expensive under virtualization), and this is where the bug got > > introduced afaict. > > ... sorry about being needlessly harsh. If it's any excuse: in all such > cases I make a fully committed, honest effort to dig down to the "roots" > of the code, and the more I struggle to form a mental image, the more > annoyed/stressed I get. Comments and diagrams would definitely help with > my efforts, but just because I get annoyed during first analysis, that > is not sufficient reason to let that *leak* to the list. It's a > personality defect on my end. I'll keep working on it. > Don't worry about it, really. I don't mind unfiltered criticism from long-time collaborators as long as it is constructive - email is such a lossy medium in terms of subtext that I'd rather suffer a minor ego bruise than having to unwrap layers of politeness to get at the real meaning. -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#113885): https://edk2.groups.io/g/devel/message/113885 Mute This Topic: https://groups.io/mt/103680930/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-