From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a00:1450:400c:c0c::232; helo=mail-wr0-x232.google.com; envelope-from=leif.lindholm@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wr0-x232.google.com (mail-wr0-x232.google.com [IPv6:2a00:1450:400c:c0c::232]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 9D6982215BD93 for ; Mon, 29 Jan 2018 03:10:52 -0800 (PST) Received: by mail-wr0-x232.google.com with SMTP id g21so6726085wrb.13 for ; Mon, 29 Jan 2018 03:16:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=oG2uMU+/Q5JQW8VgQRZk7/WIcmVmX/RvHNEr897lABU=; b=bnqmS+TrbXkd2RAv3Y3D27CSVnjFyqstF+ZslKE9ZH8i1DmMe2uIngq59L1YryQodT SQbtKaO35rQSiLgPUpyal033OHKeLhOo/RwoNZ1ktEIav7P39FaVyY2vL4DvvoiqgV9i Cop7K67O/8SbIAULWW+bEQfxSa5Qztzt8nMjA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=oG2uMU+/Q5JQW8VgQRZk7/WIcmVmX/RvHNEr897lABU=; b=OtmJOYCsKBVY8skrBUtUikI5gUii9QeGhIRo3E4ht4F/V1Jt+jmNkj7oexg9wYQoY6 YAvZo9PHavFN2jJXcS1QyEvgSqKL1xeohSNe6BDMAtOkFAlLKCLS1cFlrjYtc/V9QaPC wZLSsNnEtSqVMT7QgRW4+GyP7tla+Kl6IBd5JP9zJCfm/0xu2bL76xsce4fsz49DE52I D9beaN5L0mGZMxAUoXDv6X6sp9my7lNkwUJmyfrqVV1g2ip/QX8TFZ7DaWU1Tej3QFRj o7PyZc92DBRdMaVM/caDM+wRyif5NGgZwD1eHY5pnEXsodVghkCfPTnnMV+ssFuJiSOq AynA== X-Gm-Message-State: AKwxytdmynv5EHKSdt9cfffLWOeBnxamGt3zvBHgdZujZfVpkRHA2fwS X7BhSp8WuRLowX6TdMhvSogyBQ== X-Google-Smtp-Source: AH8x226TaDHljX71yKmhBkTvuIHru+ujgN7D/01SJ83iOclmNGhAX8OUFYAX7aRHN5JqMPYb0LQvwA== X-Received: by 10.223.154.208 with SMTP id a74mr11740704wrc.157.1517224584728; Mon, 29 Jan 2018 03:16:24 -0800 (PST) Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id 14sm514947wrb.47.2018.01.29.03.16.23 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 29 Jan 2018 03:16:23 -0800 (PST) Date: Mon, 29 Jan 2018 11:16:21 +0000 From: Leif Lindholm To: "Huangming (Mark)" Cc: Ming Huang , linaro-uefi@lists.linaro.org, edk2-devel@lists.01.org, graeme.gregory@linaro.org, ard.biesheuvel@linaro.org, guoheyi@huawei.com, wanghuiqiang@huawei.com, zhangjinsong2@huawei.com, mengfanrong@huawei.com, waip23@126.com Message-ID: <20180129111621.qbtejpasxw6ttdnl@bivouac.eciton.net> References: <1516287703-35516-1-git-send-email-huangming23@huawei.com> <1516287703-35516-14-git-send-email-huangming23@huawei.com> <20180123102320.7rloxdthhq2njbvu@bivouac.eciton.net> <2ced3021-fd0e-7551-c476-4468c915f82e@huawei.com> MIME-Version: 1.0 In-Reply-To: <2ced3021-fd0e-7551-c476-4468c915f82e@huawei.com> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [PATCH edk2-platforms v1 13/14] Hisilicon/Library: Add OsBootLib X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jan 2018 11:10:53 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sat, Jan 27, 2018 at 09:47:31AM +0800, Huangming (Mark) wrote: > The problem is that OS boot option is lost after upgrade firmware. > It is inconvenient for using. OsBootLib can help this. > > OsBootLib retain the options installed by OS, and create OS boot option > after upgrade firmware if grub file is existed in EFI partition and in mUefiOsBootFiles, > and delete redundant options in the same GPT. "Redundant" such as if the user installs a new Linux distribution on the same system without manually cleaning the ESP? This type of system behaviour has been seen multiple times to break installations in the real world. Note: my main objections here are really with regards to: 1) the expectation that variable store is erased on fw update 2) automatically rewriting boot variables If (1) was resolved, then I could potentially see a use for a last-ditch fallback option (but even then, I don't think it should be enabled by default). Regards, Leif