From patchwork Fri Apr 19 07:42:00 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 790188 Delivered-To: patch@linaro.org Received: by 2002:adf:e6ca:0:b0:346:15ad:a2a with SMTP id y10csp936249wrm; Fri, 19 Apr 2024 00:42:15 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWHkD6lV8HJMyG88XvqONd+J5VljBrpmDd1qDQZni0Z27TszUWEbA8PnNRMJEZpM/bkx4uyoAaTM5Sfg9DhtWy5 X-Google-Smtp-Source: AGHT+IE4OiM8Sjo+rJR0/BhheYhbkyLG1Ud6I/rx/XJXTVJLuOiYRZqsEskl12sdWUyJQMLH2NN1 X-Received: by 2002:a17:906:2693:b0:a52:4edb:6db7 with SMTP id t19-20020a170906269300b00a524edb6db7mr809704ejc.54.1713512535055; Fri, 19 Apr 2024 00:42:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1713512535; cv=none; d=google.com; s=arc-20160816; b=sVRS2zRJxB32bajlu6aEPvXfZzdAKCMxQAeW7maknFJlb5mfJcHpWHCkLdBXX+IHgE KX47VSEInXeHj52vot9hDbg36vE6zYkIy4G0M5BN4YkC08ZhOtYF7PvdgUqF/2RjkBwW jIZES5gEiguOp6AeytZoiofSndFqdp46ICTaySIbxu9wh4EOV1ruZNMtYtNk/NorMtZ9 ctBBATaIEqiIKFlW3jxnZZsWfOvVvxrgvtGSOHvrOgiRd2DB84YYbJqYyyrvWE5m0oum LZeNhE7UxrLCpxncMVm/wA6USDyutE8B9JHbp6MFCvcn3Di5i+2fyIC03QU3yVuHLnDI xUuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=jSfcrLSxRJx5o7rnqPpbPn7q41A6wOhVSMrQXuaOitE=; fh=r2htHk5tVM7i6MD1+gc703v8Gk/tMgh8rFuz92349vs=; b=gdKQHK++IikMplTJFnSExdoOGNMF5vswoFcxjzveiw07wlOqADGxt6H2OMWRIoX9zE g4eGWMQYNYnZPkVaXZb3wO8SCrL1eYKpBQcklp5fj0LjIYHugjvhGN5LBajbP/LkOWro KHIHYVaZwyuxT59LBD0IVBtDt8KKjW9KFF0wH6SpLHmXnfd/mQ2G6qU9i1XA5aSllL84 Jo77lPMcBe2ojAhVaqgv1ZxjGAvie5VdPAPtKQkdAHpk1DrwEDHNT7tiPysxBJAmVhbk xogtvVKQxOGinIsaQ3Y7a4+vAg2ao35iF9zRbF1wC431hYpvH+cs87bI8TYdpb8rx14i 5Dog==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZBvmzrkE; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id ho30-20020a1709070e9e00b00a51e45106fcsi1912017ejc.1037.2024.04.19.00.42.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Apr 2024 00:42:15 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZBvmzrkE; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A434F885B9; Fri, 19 Apr 2024 09:42:13 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org 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=linaro.org header.i=@linaro.org header.b="ZBvmzrkE"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 54A1B886B9; Fri, 19 Apr 2024 09:42:12 +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=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ed1-x532.google.com (mail-ed1-x532.google.com [IPv6:2a00:1450:4864:20::532]) (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 1308688553 for ; Fri, 19 Apr 2024 09:42:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ilias.apalodimas@linaro.org Received: by mail-ed1-x532.google.com with SMTP id 4fb4d7f45d1cf-56e1baf0380so2166831a12.3 for ; Fri, 19 Apr 2024 00:42:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1713512529; x=1714117329; darn=lists.denx.de; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=jSfcrLSxRJx5o7rnqPpbPn7q41A6wOhVSMrQXuaOitE=; b=ZBvmzrkEwvlLZeeUGOMIPhB5rsDhzX0CtT5llFZoojRRwuholTqDbAwAxqB/DE23Va mJ1k/9sAbFT8fdtOY0e8jAOX3cCEsipZztgw6yCW7P2BmurqaylhJJiLodPKJGEs+f6y +K/dRVvy5Ih+o/yw7Q09HXqM0Hqbg2bcOaIO9AhXvLAoGQolD5d1jp0d+QA6pnCAFaoA KFho72N5nQ84zIjzhzu1LdJEm8FX11sDGAbcf4+G09wH+8V+eK2pGwSZW+MeT69bqiZf mEmrHvMWWWjbhNBPFNe11qS5r3KUbVBkLbU7tG9+BIuvrZ1ZzGGz5LNF5gdbDY2wn38g yVxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713512529; x=1714117329; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=jSfcrLSxRJx5o7rnqPpbPn7q41A6wOhVSMrQXuaOitE=; b=ObrQUFoDyzgQc/ezADMWpzHdKEx//cq3R/KYbzfxqoJHkxBZxFgKkAKSWyvDXQ4nFE T1vN6UeFzw3RHBw1jCjO3FmR1s2dN9KSPNVSnRbmaCMW7QpUNvKsaVERcSOKm6iaFp59 EzoqR0VKVuLSyzn51DeB6f0Y1anpZMjVY2WRO3RIG6JBHoLN5GY/dAzA/utQgPTWq9gc vCn/18SHot1ElSbiYP1FeHvMg57C0CbisxFcwETm0VatTzD+in6BqCkJ+7hYTkUtu6R7 4V3sQ5AyoRZ+Y7nZH8Wh/emyVulCUZuq2fgQw7SMKpSyHxd58LNYtUWFuwABcmyE33Cx BbYQ== X-Forwarded-Encrypted: i=1; AJvYcCWVfVFTrT/X6UfUny+Vi8A0WzOKqwEeSHE8WY0/DtrZm6rJdm2Og0WQIWE22a0YQ/SqsEZxY9GFREuzhWwXuR0nIFqN7A== X-Gm-Message-State: AOJu0Ywoa7ZJq2MCHfH9GrhhVf6JtfzD9uqjRoAwYxyBNsJ9YChoSE0j ZPct4esk2xQneltAWWbfd5AheanAf17T1e3bCCsPYtF8N5x12xaI909yHslzHQf1kQXra97Y3rK dlzk= X-Received: by 2002:a50:8ac9:0:b0:56d:c91c:dfc2 with SMTP id k9-20020a508ac9000000b0056dc91cdfc2mr942668edk.31.1713512529493; Fri, 19 Apr 2024 00:42:09 -0700 (PDT) Received: from localhost.localdomain (ppp176092141112.access.hol.gr. [176.92.141.112]) by smtp.gmail.com with ESMTPSA id q10-20020a056402248a00b0056fe7c5475bsm1797858eda.10.2024.04.19.00.42.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 Apr 2024 00:42:09 -0700 (PDT) From: Ilias Apalodimas To: heinrich.schuchardt@canonical.com Cc: Ilias Apalodimas , Heinrich Schuchardt , Tom Rini , Simon Glass , Weizhao Ouyang , u-boot@lists.denx.de Subject: [PATCH] efi_loader: change the error message when storing EFI variables Date: Fri, 19 Apr 2024 10:42:00 +0300 Message-ID: <20240419074201.9053-1-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean When we try to store EFI variables on a file, we need to use an ESP. if an ESP is not found, variables will change in memory, but U-Boot won't be able to restore them across reboots. Adjust the error message so users can understand what's going on Signed-off-by: Ilias Apalodimas --- lib/efi_loader/efi_var_file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/efi_loader/efi_var_file.c b/lib/efi_loader/efi_var_file.c index 413e1794e88c..5276740ffe7a 100644 --- a/lib/efi_loader/efi_var_file.c +++ b/lib/efi_loader/efi_var_file.c @@ -82,7 +82,7 @@ efi_status_t efi_var_to_file(void) error: if (ret != EFI_SUCCESS) - log_err("Failed to persist EFI variables\n"); + log_err("ESP not found. UEFI variables won't persist reboots\n"); free(buf); return ret; #else