Received: by 2002:ab2:6991:0:b0:1f7:f6c3:9cb1 with SMTP id v17csp171911lqo; Tue, 7 May 2024 16:33:58 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX+gQobcJzMp+NBSHfRaVy+Q8z0c9NDPRBBLIWmSYwiltSZl4dpiypbIRRfyZrg0O4VOBbzAlQPD69CObYnNh+AqMf1zCKIApUo7jBXLA== X-Google-Smtp-Source: AGHT+IEeY4TfqA1RRmpGwCNDPFWZOZg4rrqqWf7ZguBWTQO7JnhfZE104sRCG78X/S92CsV02rHR X-Received: by 2002:a17:90a:6303:b0:2b6:228a:3d83 with SMTP id 98e67ed59e1d1-2b6228a3df1mr427402a91.39.1715124837769; Tue, 07 May 2024 16:33:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715124837; cv=pass; d=google.com; s=arc-20160816; b=PN6qlVchxtTnQuVC/BZ6KH8gm5FgbdvOWO98QzBKk+s2p7V3HETU1gkmfHJq8C3Uqt mFSM3Mp5QrxMLR/MU20gET0fkzzl7e7wcVruRXdq5UBGx0WYyWXBYK1G7GMDrLdu3Avr ZCcI2Ma0gY0udkneQJVWRWfY32pL5WfR7zh48rCjXhOLIaW6u+iFKYI57OE0OrdClah5 Kg1gjyCZCFYWAYVG8UqM3gjY409SIkFlfXVHLI0FfKW4z+RNDo8jyTH6K+xsUVQUKYB5 8J6+AEQGUF1uXpIqlgshiertfhQ8lt08X09aQS5CzGEzTu3Uf39QfUatOMo0ljJFqhOg e9Ng== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=2LMWMgTaW2iOG7S1sSjtZp8tn6NcKTnxiKAcPmv0zPw=; fh=QDKdxdf6dq7wm639gFdELozh9oA/utMr7hnNrYiek0Y=; b=ANKwUSJI2lkbvXMwJcbqLM2tEsayjJkBrwkuCYR2s+OstwMPZOxGOYjbck5fdgU3Tv UCdO1ZDZAj1n4hC8Am5c2FtDe0uHJegtQSTeqM3ZF2cfVPN7E/FuEWDOeRfzdeU2nG74 eCXcEbiG96OGFDoAnkKDRf4MBvOc71wr97baSBMWjcySkbFr/3eMA+GIs1D654e/8X7l fn1Nl08UPUsQAo2RzFuDlFnhkOkUbnegVS8OLf8t+XGUPyfpB8F5Nw2sxwKVw7YEloiQ k8at7tIJJtxX/XF+pymiNFiSxlPgbwDn1NFZx5jmngNuc6XJIkipT4v3pA+/eA+IUFZ3 iAqg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="lrvla/Wz"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-172390-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-172390-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id 206-20020a6301d7000000b005f7515ac97dsi11434286pgb.85.2024.05.07.16.33.57 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 May 2024 16:33:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-172390-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="lrvla/Wz"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-172390-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-172390-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 665D1282994 for ; Tue, 7 May 2024 23:33:57 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B8521146A73; Tue, 7 May 2024 23:09:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="lrvla/Wz" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DAA80136672; Tue, 7 May 2024 23:09:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715123395; cv=none; b=UI0857FcwIO8eQPMni1Rc/TGswd2JeeAxeN2M6jGkQ/NNrhYViBLBjMgjNfOCrzovRSTBMIYVFeJD2Ve0D3sDkpFHTl2HLFDch3jW/6VS9xWNg2a5i5msltHL232uvsw+MTltE7lTQiJDoLSfMcHh8sbTbdvg1srpPSrT5qOw88= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715123395; c=relaxed/simple; bh=PY5p4BR22hkl5nUDZo2IeOWjxL4AERGHJeNQcYeqpjc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=S4tVjV9l1nq5ZKre5xcxN0wWiphB3JoUBV74pZom/2jfU4OkZ0RghELHXCSlbTpjNerBgB4hf54swuNHSyAjqDYF+TkEOBJ/+IC7xccpI29dQp6Yd1qLnHY7Fyvn5T0SaGCXdmkfXS/91UUTpWKcXJ2rK9627Sl8h+SauWb8H6E= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=lrvla/Wz; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id C46B7C3277B; Tue, 7 May 2024 23:09:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1715123395; bh=PY5p4BR22hkl5nUDZo2IeOWjxL4AERGHJeNQcYeqpjc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lrvla/Wz6K2mCFIwrABTRGZjj02l9OoERYyMeiyq/bwy9KyPqnqNg5vmD7/SqsWNY V+8JElASEIkXTEjvwtGCLZ9RpbmVRbrhU6RK7TTHMzG+K8MmYpgFIrEhwrNK9IU3C7 4zGiCTT3V/QvqZge6LVzt5Iv6bIt4HncQTthemMiqNOWGR8x8vaDnun+J3A2XKE9aE McZlTRVxOz4yCXX5YXbGRmODqSFpzELau/78YHcfkXI/wJvCJBwvSl8t2t6tfIt0fn EF8TdMnxYsuocYqqtiAwyBDP/YQbf32ASE0U54HhTAX3TwRyLpnMrQ/o2Fle6X7TPn BaS6D4yRVHQag== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Maurizio Lombardi , Sagi Grimberg , Chaitanya Kulkarni , Keith Busch , Sasha Levin , hare@suse.de, linux-nvme@lists.infradead.org Subject: [PATCH AUTOSEL 6.8 47/52] nvmet-auth: replace pr_debug() with pr_err() to report an error. Date: Tue, 7 May 2024 19:07:13 -0400 Message-ID: <20240507230800.392128-47-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240507230800.392128-1-sashal@kernel.org> References: <20240507230800.392128-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 6.8.9 Content-Transfer-Encoding: 8bit From: Maurizio Lombardi [ Upstream commit 445f9119e70368ccc964575c2a6d3176966a9d65 ] In nvmet_auth_host_hash(), if a mismatch is detected in the hash length the kernel should print an error. Signed-off-by: Maurizio Lombardi Reviewed-by: Sagi Grimberg Reviewed-by: Chaitanya Kulkarni Signed-off-by: Keith Busch Signed-off-by: Sasha Levin --- drivers/nvme/target/auth.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/nvme/target/auth.c b/drivers/nvme/target/auth.c index 9e51c064b0728..fb518b00f71f6 100644 --- a/drivers/nvme/target/auth.c +++ b/drivers/nvme/target/auth.c @@ -285,9 +285,9 @@ int nvmet_auth_host_hash(struct nvmet_req *req, u8 *response, } if (shash_len != crypto_shash_digestsize(shash_tfm)) { - pr_debug("%s: hash len mismatch (len %d digest %d)\n", - __func__, shash_len, - crypto_shash_digestsize(shash_tfm)); + pr_err("%s: hash len mismatch (len %d digest %d)\n", + __func__, shash_len, + crypto_shash_digestsize(shash_tfm)); ret = -EINVAL; goto out_free_tfm; } -- 2.43.0