Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp1942133imn; Mon, 1 Aug 2022 05:52:30 -0700 (PDT) X-Google-Smtp-Source: AGRyM1s8FazYZWkSgzn1CYNYWHF/kSLo68K9q63cre1RluyzB/YvOMqqfuSNDG+bEmFqcOc3XhND X-Received: by 2002:a05:6402:5cb:b0:434:eb48:754f with SMTP id n11-20020a05640205cb00b00434eb48754fmr16325518edx.421.1659358350357; Mon, 01 Aug 2022 05:52:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659358350; cv=none; d=google.com; s=arc-20160816; b=d3WXRzkn83uRmyxhqE8C9jij9tc0Rl4ybviuEXeZOreun7M3ce9wZAmmNfP1wj4RgA JEgpPUw+3k1WqHBTBPKZQmjYNbuGTa6sJGHx/e2/u0M7f4SNjwgZBNf8ecTqY8P2xGOA +PxPj7MdocGD0dGtMgT4S0R4+EFYkGoSb9KFHvGVk5zH22cDv+crcwTYjkTSUXlHY2ql +XK8ug8qAb77KzeAzExtWoUnejPxM3B19CiaHQaKbcuP+MY7dPw2jCprCzB8huNm9XY4 9yQYKdaM5evbNGyfbzZPTKx6thE1VRkTzQ7F5twopgjrXbaHBItaf8gaiHtQ8kNaUiMK KToA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=rm7dB4bqW9uLVhd20tuD+hRJ8FVGVtSVdMXyrp7BgyY=; b=VDG9k10Sj8f2yDJVvD0mKXYMS0OvAACWrJCXvTgkKwvpb9UtgziKZel2SMqPvnZm/a kWmLXwGToBHyeDX0PYpD+NAzcvbjOGJ9VCxx9ZDrPbANPfhLcrNQQs/ylw3tj47PMCzo qCGvr/cwnuGcTJH2pE1AbbaIPxqMWC4JfFCww8AajyWP6cyDGFNtwBbfghjHqSHeXOVH 7zXEHzf2bhCo50V3f0o9Iz7oQkLngxDvjkAHeqx055YAMPbf/6ZtfaY5+THALqYEynx4 tkBZ+AfK1QQYhHvOLdTVSzd5wD1i1ox68IaAcYkWMaUXPLz0n9BwHVKjGiODWLy9Wngx 0j/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=M7L50dtI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q31-20020a056402249f00b0043d75b37d2asi4244088eda.258.2022.08.01.05.52.05; Mon, 01 Aug 2022 05:52:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=M7L50dtI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232512AbiHALzd (ORCPT + 99 others); Mon, 1 Aug 2022 07:55:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232262AbiHALyj (ORCPT ); Mon, 1 Aug 2022 07:54:39 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 12E633E765; Mon, 1 Aug 2022 04:51:00 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id C9F10B8116D; Mon, 1 Aug 2022 11:50:58 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 21C83C433C1; Mon, 1 Aug 2022 11:50:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1659354657; bh=fccSz834zV3hpRoaHeJs1Um/CBE6M8nxqixFWsZs9f0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=M7L50dtIcJuYrf2TrMPGPjQHaEg7XvrF6x5cmUoB8NxklAyqVmuFwAR533ZmEmOc1 uIsBZJABPilmH1Bj1b9Sw5vbx6ISmHvHwWf+jowvBLV4/9hVfQr1quowAHBPoYkes1 +Kaci+ub6NZfZJXg5wappnBxlMJUvwdKCRuVr7Bk= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Sabrina Dubroca , "David S. Miller" , Sasha Levin Subject: [PATCH 5.10 32/65] macsec: fix error message in macsec_add_rxsa and _txsa Date: Mon, 1 Aug 2022 13:46:49 +0200 Message-Id: <20220801114135.048046088@linuxfoundation.org> X-Mailer: git-send-email 2.37.1 In-Reply-To: <20220801114133.641770326@linuxfoundation.org> References: <20220801114133.641770326@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Sabrina Dubroca [ Upstream commit 3240eac4ff20e51b87600dbd586ed814daf313db ] The expected length is MACSEC_SALT_LEN, not MACSEC_SA_ATTR_SALT. Fixes: 48ef50fa866a ("macsec: Netlink support of XPN cipher suites (IEEE 802.1AEbw)") Signed-off-by: Sabrina Dubroca Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/macsec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/macsec.c b/drivers/net/macsec.c index 0b53c7cadd87..c2d8bcda2503 100644 --- a/drivers/net/macsec.c +++ b/drivers/net/macsec.c @@ -1767,7 +1767,7 @@ static int macsec_add_rxsa(struct sk_buff *skb, struct genl_info *info) if (nla_len(tb_sa[MACSEC_SA_ATTR_SALT]) != MACSEC_SALT_LEN) { pr_notice("macsec: nl: add_rxsa: bad salt length: %d != %d\n", nla_len(tb_sa[MACSEC_SA_ATTR_SALT]), - MACSEC_SA_ATTR_SALT); + MACSEC_SALT_LEN); rtnl_unlock(); return -EINVAL; } @@ -2009,7 +2009,7 @@ static int macsec_add_txsa(struct sk_buff *skb, struct genl_info *info) if (nla_len(tb_sa[MACSEC_SA_ATTR_SALT]) != MACSEC_SALT_LEN) { pr_notice("macsec: nl: add_txsa: bad salt length: %d != %d\n", nla_len(tb_sa[MACSEC_SA_ATTR_SALT]), - MACSEC_SA_ATTR_SALT); + MACSEC_SALT_LEN); rtnl_unlock(); return -EINVAL; } -- 2.35.1