Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp1212580rdb; Fri, 9 Feb 2024 14:06:08 -0800 (PST) X-Google-Smtp-Source: AGHT+IGeL/VNcYyK3l9P9cvmnSKR1IKI6Tq7/CsqJA/T3shSGqU+/0LYEqWGPQwu14ikP7bYmZXr X-Received: by 2002:a05:6a00:92aa:b0:6de:3521:b3c2 with SMTP id jw42-20020a056a0092aa00b006de3521b3c2mr911791pfb.11.1707516368514; Fri, 09 Feb 2024 14:06:08 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707516368; cv=pass; d=google.com; s=arc-20160816; b=TFA9NUlbSCQxaWJ3pGogdaD18Y1BMX0cPb8dyEMDHX56Q9wrfsyoz56ZGas/r6JS/1 WhTJO5TaP0X/4PJyoayFqztfZZ/agyVWkpHfMwtRNOoy+k95mpSCAU049BK9YYGDYI/s jfPgOCLn2X46dl488+4Qj3LIwb69cCtDmWwCt7rok7SJu0EsF1wgGRYbFAI4dmtE/uxl Z4TqAGjoHjmauaY/MbDBmdcREMqEgozKl/JfygzRXCrlee+qwHszKgRQhpmwPa2gwRCf kOaPwyVcdl/CrcWRY+3rUknRRyZr0Ib7UFTNcgJlbLVoyPzBIjbC6f8w0T1cywZ/kH5I IghA== 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 :subject:cc:to:from:date:dkim-signature; bh=Nz8DaOlGSB/QNIL50I6mS0Oo9iIWgyvInJkoYLTcGA8=; fh=/oRZ3u/w2xIzRYtuzBZeGhQDVcaH/pWkASn0/nmV9Lk=; b=frc2KAN6V5fipHdR9xBqsDDFWocAK0B231jcvSBIFvJ9hxD67u9DPqRPdpa6jEJOgv H0FOoSW4nh6CMVBhsGUeuD4y26rBR+HdT3fbAMKR26sdSDh58qvQxqRawQwC6aTI/Tue fOMcJaEf6+y2HXgonGH+JD1FqIt16a9ykVKM17UMplGvysJ0RcSbuDg5ryPFDMvr2pSJ 5lXWD/mPBhVwwCa4RkLYd+TaEXhVI/0CDoJPxT2Pgek8KXRGoMs0TJ0CgiPtuddeXsZq eMcP1QJjokff3EeKxd3dvbYRP+W7GnOdqfHYJy4N43+7xMaE3FYUVdxQJmohl3JMBe5Q fsWA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Q+2KEg6G; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-60044-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-60044-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=2; AJvYcCUOuucni+HLLE3ofUeBC9hMYvcmPbv+SdvytE3cr3Kxfc2HM+X28TJ3qXVpMkEunoQsMszMpuTp1xxl5LzkQkhRUVti/JO3qyf90qAjMQ== Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id l62-20020a638841000000b005dc4202b41esi2355221pgd.300.2024.02.09.14.06.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 09 Feb 2024 14:06:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-60044-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Q+2KEg6G; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-60044-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-60044-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 sy.mirrors.kernel.org (Postfix) with ESMTPS id C54B1B213E0 for ; Fri, 9 Feb 2024 21:41:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 73C2721101; Fri, 9 Feb 2024 21:41:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Q+2KEg6G" 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 8F7EF149DFA; Fri, 9 Feb 2024 21:41:14 +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=1707514874; cv=none; b=R8rEgcOyxEbDRnHYcZeFcr2lLqODvGO3zs+rMQLzHjn3LjHhNAw+8pi1VpaNkf0jnMQlk+W+TnaSW6GVnBeS9Vbzj8+DyNgeHUwqTztlgXL01K+rwlTlYBSXCZqDrPdCrA7eEWAme1Eyl38U+7uiRtYn0gmZtX7exVFmf9SdzZ4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707514874; c=relaxed/simple; bh=tZosFHr8PqySTr1vT1GdQmj3Mjs87KTJSyGNLrRgLVk=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=NECZWS9HoBuaft07CVPD9AhcOFMVzkyxGX+WXWfxhFkS4gcIHT5ZW47U9pJVlV8vpfOmx7y4zNvhjJ7GZCtDOX/J2Z68ZGcKZr0i6J1RX4gW7Knzyn4oxs/NH+sKppaFlg6Pv4dDGAZdEWTBwoqI+sScvHWWe0JGLQ3BAHi+c0k= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Q+2KEg6G; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id A29ABC433C7; Fri, 9 Feb 2024 21:41:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707514874; bh=tZosFHr8PqySTr1vT1GdQmj3Mjs87KTJSyGNLrRgLVk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Q+2KEg6Gv8Azh+UWCEMd0oRMkG+S1rsEZelQvAtkkhRzbqXTAhWJdfrPtGsHejdEx 8FK3BDV5d+am8zpHfjdQDByOrgsmZ3puXFK9/8UpoL2NLBkup3GHKyeq5Ak2YsBduF VGBe5fDrkMbx3E/fF6tIBxR5MDrxMi83CpH+QMSYiNQ2OcRT7YUWEwLDeiePX6S6rF vZ5SOAJ33G01z/d8qkEiE6jD7BXELoY4E2FCYFqUGfDcH2iam4Sk3KtgiFD8AaprXh P+eAnthBzMVMrCltUvYZlVefEYmNmHKw0kwyi4O6gT43TRBcAgkUpK/6TaKAnDmilU 0sRs1CxmjSe8w== Date: Fri, 9 Feb 2024 13:41:12 -0800 From: Jakub Kicinski To: Stephen Hemminger Cc: netdev@vger.kernel.org, Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , Jamal Hadi Salim , Cong Wang , Jiri Pirko , "David S. Miller" , Eric Dumazet , Paolo Abeni , bpf@vger.kernel.org (open list:BPF [GENERAL] (Safe Dynamic Programs and Tools)), linux-kernel@vger.kernel.org (open list) Subject: Re: [PATCH net-next v2] net/sched: actions report errors with extack Message-ID: <20240209134112.4795eb19@kernel.org> In-Reply-To: <20240209131119.6399c91b@hermes.local> References: <20240205185537.216873-1-stephen@networkplumber.org> <20240208182731.682985dd@kernel.org> <20240209131119.6399c91b@hermes.local> 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=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 9 Feb 2024 13:11:19 -0800 Stephen Hemminger wrote: > On Thu, 8 Feb 2024 18:27:31 -0800 > Jakub Kicinski wrote: > > > > - if (!tb[TCA_ACT_BPF_PARMS]) > > > + if (NL_REQ_ATTR_CHECK(extack, nla, tb, TCA_ACT_BPF_PARMS)) { > > > + NL_SET_ERR_MSG(extack, "Missing required attribute"); > > > > Please fix the userspace to support missing attr parsing instead. > > I was just addressing the error handling. This keeps the same impact as > before, i.e no userspace API change. I mean that NL_REQ_ATTR_CHECK() should be more than enough by itself. We have full TC specs in YAML now, we can hack up a script to generate reverse parsing tables for iproute2 even if you don't want to go full YNL.