Received: by 2002:ab2:6203:0:b0:1f5:f2ab:c469 with SMTP id o3csp2844000lqt; Tue, 23 Apr 2024 03:28:34 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXiBelMKtwjjo94CsK38f00m7lRst6hXOjMupPQ6HotTC1DDiPX2qUlQEXcM5buf7NpwTmJzIaPvkZm0/X8X6R5JKtkPGlzCNbWtQslvw== X-Google-Smtp-Source: AGHT+IEh96+zMqutmTw+nkbelrSzlFNTcRUSTNH9+cjoYb1SICXzV+/CzncAIwcRSZiMfQiC2j61 X-Received: by 2002:a05:6a20:970b:b0:1ab:7a57:e466 with SMTP id hr11-20020a056a20970b00b001ab7a57e466mr11282407pzc.52.1713868114188; Tue, 23 Apr 2024 03:28:34 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713868114; cv=pass; d=google.com; s=arc-20160816; b=uUq8UeoAw7IDDOTRt8OrZPIEXuBfcqSsHKjgoh18jCVSHEf38clPd/YyIfz0Dn1lW9 6OucmGDmX0OXAlWzuL0mS0GirEH3LrHo6t2twgtuaynkhtrxX8IShXSsA5Q7fL+VDEY5 ingo+cbCg+z8HRlJM6WJVgU0w1S25mArN7UBhZW+4jSx7W3EVYtO6F8kj22TmUOKx67H /AsxWJiVVqYNQLSg/g90IxqbmSwdSEVxsGodYnSpYiHYebThj3Q3ycfdMN2MB5oSAkTK /U0DSqY86AfMGHgojBDfI/0ceYTOvKzyMLoz4fEoMBLBadq12Vz26nKi/BQGPyM4Bnql zqew== 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:message-id:date:subject:cc:to :from:dkim-signature; bh=G24/iSdU9Nst9pXintNREVELetKCHQThwoplCC8H/xI=; fh=H55gNw+1hb+/1gs6PFLX5z/jE2YzPsD8zDM+jpdqhyI=; b=x3GmL4Dw3Ifk1nVIogHHsbYjCUqCRoF5WK/StMMbikfxaTyDtB6PIOYmokxYZJED31 jPRZDRm+45l2bVF9VDr2G1LZ3dqncJXfmELqiWzZZ+hK/5ymEdkthOOeCJvLos8msJm2 0y4VGaJKlg0U1hYfr46XteMN2rthEsod+O1Cnd2hpc0BtHHA9WZF65dgbXfKVuyJT7z3 yVMjQl8RT0+5gvYbisy8HCT+U+2yqtEn6JjJCaccSWq9qb+31eKV64unL++BDmtypKNG bkAYerYUnq/34DwNzrVw1S4UBJIoxQLfKiA7wp7BKw6ajKzLh6GaqC2b2E3mhTRtBbX3 mKwg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@fiberby.net header.s=202008 header.b=dreCglqb; arc=pass (i=1 spf=pass spfdomain=fiberby.net dkim=pass dkdomain=fiberby.net dmarc=pass fromdomain=fiberby.net); spf=pass (google.com: domain of linux-kernel+bounces-154862-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-154862-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=fiberby.net Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id s3-20020a62e703000000b006ed26c096b0si9363385pfh.141.2024.04.23.03.28.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Apr 2024 03:28:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-154862-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@fiberby.net header.s=202008 header.b=dreCglqb; arc=pass (i=1 spf=pass spfdomain=fiberby.net dkim=pass dkdomain=fiberby.net dmarc=pass fromdomain=fiberby.net); spf=pass (google.com: domain of linux-kernel+bounces-154862-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-154862-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=fiberby.net 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 CA0E7283400 for ; Tue, 23 Apr 2024 10:28:33 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 13CD96997A; Tue, 23 Apr 2024 10:28:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=fiberby.net header.i=@fiberby.net header.b="dreCglqb" Received: from mail1.fiberby.net (mail1.fiberby.net [193.104.135.124]) (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 AB86261694; Tue, 23 Apr 2024 10:28:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.104.135.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713868096; cv=none; b=SNfyLnqwK9y+sA8Z+UlmXdUT829Y8W+ExneTuKdaiMePNjI1UKvZ7YqnmgtnJPCvVAnbwGTs7F9w1M3aNDv3ieDjVZ3myAmTdZj6tP3oHdLQO5a7eJJaK9bPcjMMNjOzIchoE7DAaFO6UJvxQZpSb/J59+2u8WoltPjkRa5zjJA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713868096; c=relaxed/simple; bh=b7EYECfaQpkuXRm4fwoJzpN0LrsyfwmAPnfkai828dE=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type; b=R4I5kU5cqq8ZKXsBzecAfqLMpqQqx/vxKDtEa2eFY2sDCtAt2ms+mxptL8p5ptnWL5TaoNLljvpr/hQp1hzpmCO1Fs+GiI0FlIW3m4NbzE+lvV3+CBQgsDh1aDYELqGuy5wMUHxJ74L1JvLHQgoqufOVP9GG84pNsVbNZzvMQaY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=fiberby.net; spf=pass smtp.mailfrom=fiberby.net; dkim=pass (2048-bit key) header.d=fiberby.net header.i=@fiberby.net header.b=dreCglqb; arc=none smtp.client-ip=193.104.135.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=fiberby.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=fiberby.net Received: from x201s (193-104-135-243.ip4.fiberby.net [193.104.135.243]) by mail1.fiberby.net (Postfix) with ESMTPSA id 69071600AF; Tue, 23 Apr 2024 10:28:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=fiberby.net; s=202008; t=1713868087; bh=b7EYECfaQpkuXRm4fwoJzpN0LrsyfwmAPnfkai828dE=; h=From:To:Cc:Subject:Date:From; b=dreCglqb9B46tN4utGlbkHf0tCeEhW1Sqy+zGl1z7i3igNJ0ANs9PuCjrAGUml8PR eGt6Y21FK9E7Dqm3yuxX099PXg9tE9FzMSld1zP1fbOmcsFcw43p1pHQ+nrovGobT+ CLHu14yip5KBr/qIrHk+ve5xgYR8IckKFSJ9rCtcbTBrQ3fiY5gDzDRMpCtKwlaFF7 ogeeoIR1EZ06u/gk55N8PikAk8jHnVKPNmxHgtAB5nJAlGbQxb8JusTaX1st4UwWdh n7tUTA8j1oHcGjBHCVysdBphyDm40lR9Lc4xgNiInhFtQOtQelMyVuNDyVAkuVGgul umL3JD75v63hQ== Received: by x201s (Postfix, from userid 1000) id A8D1B205A1A; Tue, 23 Apr 2024 10:27:20 +0000 (UTC) From: =?UTF-8?q?Asbj=C3=B8rn=20Sloth=20T=C3=B8nnesen?= To: netdev@vger.kernel.org Cc: =?UTF-8?q?Asbj=C3=B8rn=20Sloth=20T=C3=B8nnesen?= , Horatiu Vultur , UNGLinuxDriver@microchip.com, "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , linux-kernel@vger.kernel.org Subject: [PATCH net-next 1/2] net: lan966x: cleanup lan966x_tc_flower_handler_control_usage() Date: Tue, 23 Apr 2024 10:27:17 +0000 Message-ID: <20240423102720.228728-1-ast@fiberby.net> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Define extack locally, to reduce line lengths and future users. Rename goto, as the error message is specific to the fragment flags. Only compile-tested. Signed-off-by: Asbjørn Sloth Tønnesen --- .../net/ethernet/microchip/lan966x/lan966x_tc_flower.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/microchip/lan966x/lan966x_tc_flower.c b/drivers/net/ethernet/microchip/lan966x/lan966x_tc_flower.c index d696cf9dbd19..8baec0cd8d95 100644 --- a/drivers/net/ethernet/microchip/lan966x/lan966x_tc_flower.c +++ b/drivers/net/ethernet/microchip/lan966x/lan966x_tc_flower.c @@ -45,6 +45,7 @@ static bool lan966x_tc_is_known_etype(struct vcap_tc_flower_parse_usage *st, static int lan966x_tc_flower_handler_control_usage(struct vcap_tc_flower_parse_usage *st) { + struct netlink_ext_ack *extack = st->fco->common.extack; struct flow_match_control match; int err = 0; @@ -59,7 +60,7 @@ lan966x_tc_flower_handler_control_usage(struct vcap_tc_flower_parse_usage *st) VCAP_KF_L3_FRAGMENT, VCAP_BIT_0); if (err) - goto out; + goto bad_frag_out; } if (match.mask->flags & FLOW_DIS_FIRST_FRAG) { @@ -72,15 +73,15 @@ lan966x_tc_flower_handler_control_usage(struct vcap_tc_flower_parse_usage *st) VCAP_KF_L3_FRAG_OFS_GT0, VCAP_BIT_1); if (err) - goto out; + goto bad_frag_out; } st->used_keys |= BIT_ULL(FLOW_DISSECTOR_KEY_CONTROL); return err; -out: - NL_SET_ERR_MSG_MOD(st->fco->common.extack, "ip_frag parse error"); +bad_frag_out: + NL_SET_ERR_MSG_MOD(extack, "ip_frag parse error"); return err; } -- 2.43.0