From patchwork Mon Mar 6 23:18:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jassi Brar X-Patchwork-Id: 659274 Delivered-To: patch@linaro.org Received: by 2002:adf:a3c6:0:0:0:0:0 with SMTP id m6csp2085495wrb; Mon, 6 Mar 2023 15:19:22 -0800 (PST) X-Google-Smtp-Source: AK7set++055ekpCUP6W7yslci1pAgHEbdRb5Lo12VjlotH5GweOD+Z/qNX+l+66zZTvVsf1kLuyl X-Received: by 2002:a5d:4089:0:b0:2c7:3ee7:a44c with SMTP id o9-20020a5d4089000000b002c73ee7a44cmr6953230wrp.65.1678144762265; Mon, 06 Mar 2023 15:19:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678144762; cv=none; d=google.com; s=arc-20160816; b=kxD6//WJ1l+GeAoyqVUNP0FsoNOB5XB9YphmVfzsoPo9Wq3UVI4NgpNrHqXj2n99aT Pep4c/phYMC/8hBztFaKzdGGCqsKACoS0RdoX+jLgQEJZhde7Day07wWOtwsBUCSipa7 RVITmZnqcGpmkps5niVS+bPy3j7ZH/Mm/KZ+1sSHSV7I2tEn7umc3b2BavVsGsvoRZGD WsfqEgB8DX72t9my1zjeNrUQIc8ojgeAZV6Mvt0SFbtf5sz/eFReWGWtYVmYr3JOJKxl cgOctWD78CKrjWnnfEQCIscAPcLrSzV4lak6FYDAlPUQFJ8ks3b5ic0nXOd5LeGrdDou ST3Q== 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:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=3UyVSZjsxTlcNQ6wZRo6mmBY5NN9dYXPdqX9mNMW2Hs=; b=pEUoxRGh1DkgjgBfa/LeAhmR5IaMuqethpEXhBRovS+U+orm8dV+hnAgpIV+strt8g b/hVJXLbX95x6LnrdMrgIIjIYGt3e1l6Izh8841as5kG4R4bwlVZ/C6w8RAyS2oNLSP1 iygkUIcucuINqCURNndrrywl+/KJTpXb+g5bXzeQbH2+aGakZhHLdeWBg4zrInMBSGzt JopSSa+Qdvo/x5GjB0nSAXmKXjz24m5EjeTlGeIF4j08aJ0rhKWB1gnj3Dngh+M7jA3f yMdeF8cDKsDHejDuXE+micEriDm8X2G4BgpqzQBnK5/bZdpheQsw2DEDOmQuF7lHk1hz ynUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=MPha1nz6; 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=QUARANTINE dis=NONE) header.from=gmail.com 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 w10-20020a5d680a000000b002c552c3c9a7si8238072wru.1000.2023.03.06.15.19.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Mar 2023 15:19:22 -0800 (PST) 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=@gmail.com header.s=20210112 header.b=MPha1nz6; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 84AE085B12; Tue, 7 Mar 2023 00:19:08 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com 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=gmail.com header.i=@gmail.com header.b="MPha1nz6"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1EAA0858B8; Tue, 7 Mar 2023 00:18:58 +0100 (CET) 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,FREEMAIL_FROM,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-qv1-xf2d.google.com (mail-qv1-xf2d.google.com [IPv6:2607:f8b0:4864:20::f2d]) (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 582AE85A11 for ; Tue, 7 Mar 2023 00:18:54 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=jassisinghbrar@gmail.com Received: by mail-qv1-xf2d.google.com with SMTP id g9so6133239qvt.8 for ; Mon, 06 Mar 2023 15:18:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678144732; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3UyVSZjsxTlcNQ6wZRo6mmBY5NN9dYXPdqX9mNMW2Hs=; b=MPha1nz6U7R4FxymqFGBecUaogeIS/P1dz/dq/zm1Wc0Xjgzulba6AWHU/lLAmB4Io 8a4Q2vS3clcrO6ovBpOaLyesZB+3JhrSYjrrqLiYPw6xsFR0DrThT0nBYTJPwCAh1Wzs nFVS/0xT+7ZEg3Yo5zgA1Hn2lKs4+kraZ3Sytahz/PkCX8iXdbE4PC3ifcXEVH6ErSo4 oqU/B9daGFj+W3MA30EvVBp1dWV7nuvAdVGSHs61C7ZoGJiOv4TFTsfcdnh5H+VIDtRs aQxQS9A2TsUpUXO66W98ul+h+j5sSvb8VCP7b2YJhvQyeudlRSgf/72K4SACP1MRmqjK rftQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678144732; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3UyVSZjsxTlcNQ6wZRo6mmBY5NN9dYXPdqX9mNMW2Hs=; b=2B2952s+lI3DTPY1xtXYdS6G+YDHqFj/7CNgpoPdtpPz0ej+LAcX44EHKL7eVZGDYy 4T+PtJYVufYOoZkTMu1fHlA3JwUSm9nfcl/y2DBH773Gxzmln+XhvusUQBk8D0I1NvE6 DjU0qjNkF1jEkecXj5QTzJtGIdSIZG4bf9lzZv4VRtWkkdziG2VtcoaDG7scv28Lu0gy exOw4SAZmmJMxt/Lk5BqfKuZuQQlLlxtrqSwulj9H6VI59mrfjAb4ojjM9ts4p8btqxk l2vVVmzhurJ2oZ/HmOpq6lIdDohx5ESTAdQs3SW3Cx1KNoTsInnBafTaQSjX73ZlYT3x rosw== X-Gm-Message-State: AO0yUKWf5x4ngl+wm1tkAcw0vk+IMsaXuO5ThHWJU2drFFD2l4Eiq/F6 x3QZxijp2ZftUcULqKKBdY8ShZLdvAY= X-Received: by 2002:ad4:5de1:0:b0:56b:f09e:9ab0 with SMTP id jn1-20020ad45de1000000b0056bf09e9ab0mr19195608qvb.5.1678144732725; Mon, 06 Mar 2023 15:18:52 -0800 (PST) Received: from jassi-desktop.. (wnpgmb0311w-ds01-45-177-228.dynamic.bellmts.net. [206.45.177.228]) by smtp.gmail.com with ESMTPSA id t197-20020a3746ce000000b007417e60f621sm8476056qka.126.2023.03.06.15.18.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Mar 2023 15:18:52 -0800 (PST) From: jassisinghbrar@gmail.com To: u-boot@lists.denx.de Cc: ilias.apalodimas@linaro.org, sughosh.ganu@linaro.org, etienne.carriere@linaro.org, trini@konsulko.com, sjg@chromium.org, xypron.glpk@gmx.de, patrick.delaunay@foss.st.com, patrice.chotard@foss.st.com, Jassi Brar Subject: [PATCH v6 6/7] fwu: rename fwu_get_verified_mdata to fwu_get_mdata Date: Mon, 6 Mar 2023 17:18:48 -0600 Message-Id: <20230306231848.1888627-1-jassisinghbrar@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230306231747.1888513-1-jassisinghbrar@gmail.com> References: <20230306231747.1888513-1-jassisinghbrar@gmail.com> 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 From: Jassi Brar fwu_get_mdata() sounds more appropriate than fwu_get_verified_mdata() Signed-off-by: Jassi Brar Reviewed-by: Etienne Carriere Reviewed-by: Ilias Apalodimas --- cmd/fwu_mdata.c | 2 +- include/fwu.h | 4 ++-- lib/fwu_updates/fwu.c | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/cmd/fwu_mdata.c b/cmd/fwu_mdata.c index 9b70340368..5ecda455df 100644 --- a/cmd/fwu_mdata.c +++ b/cmd/fwu_mdata.c @@ -46,7 +46,7 @@ int do_fwu_mdata_read(struct cmd_tbl *cmdtp, int flag, int ret = CMD_RET_SUCCESS, res; struct fwu_mdata mdata; - res = fwu_get_verified_mdata(&mdata); + res = fwu_get_mdata(&mdata); if (res < 0) { log_err("Unable to get valid FWU metadata\n"); ret = CMD_RET_FAILURE; diff --git a/include/fwu.h b/include/fwu.h index 314aadea59..33b4d0b3db 100644 --- a/include/fwu.h +++ b/include/fwu.h @@ -80,7 +80,7 @@ int fwu_read_mdata(struct udevice *dev, struct fwu_mdata *mdata, bool primary); int fwu_write_mdata(struct udevice *dev, struct fwu_mdata *mdata, bool primary); /** - * fwu_get_verified_mdata() - Read, verify and return the FWU metadata + * fwu_get_mdata() - Read, verify and return the FWU metadata * * Read both the metadata copies from the storage media, verify their checksum, * and ascertain that both copies match. If one of the copies has gone bad, @@ -88,7 +88,7 @@ int fwu_write_mdata(struct udevice *dev, struct fwu_mdata *mdata, bool primary); * * Return: 0 if OK, -ve on error */ -int fwu_get_verified_mdata(struct fwu_mdata *mdata); +int fwu_get_mdata(struct fwu_mdata *mdata); /** * fwu_get_active_index() - Get active_index from the FWU metadata diff --git a/lib/fwu_updates/fwu.c b/lib/fwu_updates/fwu.c index 49c9316c70..a24ccf567a 100644 --- a/lib/fwu_updates/fwu.c +++ b/lib/fwu_updates/fwu.c @@ -189,7 +189,7 @@ static inline int mdata_crc_check(struct fwu_mdata *mdata) } /** - * fwu_get_verified_mdata() - Read, verify and return the FWU metadata + * fwu_get_mdata() - Read, verify and return the FWU metadata * @mdata: Output FWU metadata read or NULL * * Read both the metadata copies from the storage media, verify their checksum, @@ -198,7 +198,7 @@ static inline int mdata_crc_check(struct fwu_mdata *mdata) * * Return: 0 if OK, -ve on error */ -int fwu_get_verified_mdata(struct fwu_mdata *mdata) +int fwu_get_mdata(struct fwu_mdata *mdata) { int err; bool parts_ok[2] = { false }; @@ -615,7 +615,7 @@ static int fwu_boottime_checks(void *ctx, struct event *event) return ret; } - ret = fwu_get_verified_mdata(NULL); + ret = fwu_get_mdata(NULL); if (ret) { log_debug("Unable to read meta-data\n"); return ret;