All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Vladimir Oltean <vladimir.oltean@nxp.com>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>,
	Vladimir Oltean <olteanv@gmail.com>,
	netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>,
	Cong Wang <xiyou.wangcong@gmail.com>,
	Jiri Pirko <jiri@resnulli.us>,
	Vinicius Costa Gomes <vinicius.gomes@intel.com>,
	Kurt Kanzenbach <kurt@linutronix.de>,
	Gerhard Engleder <gerhard@engleder-embedded.com>,
	Amritha Nambiar <amritha.nambiar@intel.com>,
	Ferenc Fejes <ferenc.fejes@ericsson.com>,
	Xiaoliang Yang <xiaoliang.yang_1@nxp.com>,
	Roger Quadros <rogerq@kernel.org>,
	Pranavi Somisetty <pranavi.somisetty@amd.com>,
	Harini Katakam <harini.katakam@amd.com>,
	Giuseppe Cavallaro <peppe.cavallaro@st.com>,
	Alexandre Torgue <alexandre.torgue@foss.st.com>,
	Michael Sit Wei Hong <michael.wei.hong.sit@intel.com>,
	Mohammad Athari Bin Ismail <mohammad.athari.ismail@intel.com>,
	Oleksij Rempel <linux@rempel-privat.de>,
	Jacob Keller <jacob.e.keller@intel.com>,
	linux-kernel@vger.kernel.org, Ferenc Fejes <fejes@inf.elte.hu>,
	Simon Horman <simon.horman@corigine.com>
Subject: Re: [PATCH v4 net-next 6/9] net/sched: mqprio: allow per-TC user input of FP adminStatus
Date: Fri, 7 Apr 2023 18:01:48 -0700	[thread overview]
Message-ID: <20230407180148.281307c3@kernel.org> (raw)
In-Reply-To: <20230407215252.x3lwkhfp4u6vptxl@skbuf>

On Sat, 8 Apr 2023 00:52:52 +0300 Vladimir Oltean wrote:
> On Fri, Apr 07, 2023 at 05:40:20PM -0400, Jamal Hadi Salim wrote:
> > Yes, it is minor (and usually minor things generate the most emails;->).
> > I may be misunderstanding what you mean by "doesnt justify exporting
> > something to UAPI"  - those definitions are part of uapi and are
> > already being exported.  
> 
> In my proposed patch set there isn't any TC_FP_MAX. I'm saying it
> doesn't help user space, and so, it just pollutes the name space of C
> programs with no good reason.

+1  we tend to sprinkle MAX and UNSPEC into every enum

> > No, no, it is a matter of taste and opinion. You may have noticed,
> > trivial stuff like this gets the most comments and reviews normally(we
> > just spent like 4-5 emails on this?). Poteto/potato: IOW, if i was to
> > do it i would have used a u16 or u32 because i feel it would be more
> > readable. I would have used NLA_U8 because i felt it is more fitting
> > and i would have used a max value because it would save me one line in
> > a patch in the future. I think weve spent enough electrons on this - I
> > defer to you.  
> 
> Ok, I won't change preemptible_tcs from unsigned long to u32.
> Things like for_each_set_bit() take unsigned long, and so, I got used
> to using that consistently for small bitfield types.
> 
> If there's a second opinion stating that I should prefer the smallest
> netlink attribute type that fits the estimated data, then I'll transition
> from NLA_U32 to NLA_U8. Otherwise, I won't :) since I would need to
> change iproute2 too, and I'd have to re-test more thoroughly to make
> sure I don't introduce stupid bugs.

And here also agreed. We should have a patchwork check for new uses of
NLA_*{8,16} if you ask me :S  NLA_FLAG or NLA_U32, anything in between
needs a strong justification.  Until Alex L posts the variable size
ints, then NLA_FLAG or NLA_UINT ;)

  reply	other threads:[~2023-04-08  1:07 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-03 10:34 [PATCH v4 net-next 0/9] Add tc-mqprio and tc-taprio support for preemptible traffic classes Vladimir Oltean
2023-04-03 10:34 ` [PATCH v4 net-next 1/9] net: ethtool: create and export ethtool_dev_mm_supported() Vladimir Oltean
2023-04-03 10:34 ` [PATCH v4 net-next 2/9] net/sched: mqprio: simplify handling of nlattr portion of TCA_OPTIONS Vladimir Oltean
2023-04-07 16:05   ` Jamal Hadi Salim
2023-04-03 10:34 ` [PATCH v4 net-next 3/9] net/sched: mqprio: add extack to mqprio_parse_nlattr() Vladimir Oltean
2023-04-07 16:06   ` Jamal Hadi Salim
2023-04-03 10:34 ` [PATCH v4 net-next 4/9] net/sched: mqprio: add an extack message to mqprio_parse_opt() Vladimir Oltean
2023-04-07 16:08   ` Jamal Hadi Salim
2023-04-03 10:34 ` [PATCH v4 net-next 5/9] net/sched: pass netlink extack to mqprio and taprio offload Vladimir Oltean
2023-04-07 16:09   ` Jamal Hadi Salim
2023-04-03 10:34 ` [PATCH v4 net-next 6/9] net/sched: mqprio: allow per-TC user input of FP adminStatus Vladimir Oltean
2023-04-06  1:12   ` Jakub Kicinski
2023-04-11 17:01     ` Vladimir Oltean
2023-04-11 18:18       ` Jakub Kicinski
2023-04-07 16:22   ` Jamal Hadi Salim
2023-04-07 16:41     ` Vladimir Oltean
2023-04-07 18:49       ` Jamal Hadi Salim
2023-04-07 19:30         ` Vladimir Oltean
2023-04-07 21:40           ` Jamal Hadi Salim
2023-04-07 21:52             ` Vladimir Oltean
2023-04-08  1:01               ` Jakub Kicinski [this message]
2023-04-03 10:34 ` [PATCH v4 net-next 7/9] net/sched: taprio: " Vladimir Oltean
2023-04-07 16:27   ` Jamal Hadi Salim
2023-04-03 10:34 ` [PATCH v4 net-next 8/9] net: enetc: rename "mqprio" to "qopt" Vladimir Oltean
2023-04-03 10:34 ` [PATCH v4 net-next 9/9] net: enetc: add support for preemptible traffic classes Vladimir Oltean
2023-04-03 10:54 ` [PATCH v4 net-next 0/9] Add tc-mqprio and tc-taprio " Vladimir Oltean
2023-04-03 11:04 ` Vladimir Oltean
2023-04-03 21:32   ` Jakub Kicinski
2023-04-03 23:43     ` Vladimir Oltean
2023-04-04  0:11       ` Jakub Kicinski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230407180148.281307c3@kernel.org \
    --to=kuba@kernel.org \
    --cc=alexandre.torgue@foss.st.com \
    --cc=amritha.nambiar@intel.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=fejes@inf.elte.hu \
    --cc=ferenc.fejes@ericsson.com \
    --cc=gerhard@engleder-embedded.com \
    --cc=harini.katakam@amd.com \
    --cc=jacob.e.keller@intel.com \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=kurt@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@rempel-privat.de \
    --cc=michael.wei.hong.sit@intel.com \
    --cc=mohammad.athari.ismail@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.com \
    --cc=peppe.cavallaro@st.com \
    --cc=pranavi.somisetty@amd.com \
    --cc=rogerq@kernel.org \
    --cc=simon.horman@corigine.com \
    --cc=vinicius.gomes@intel.com \
    --cc=vladimir.oltean@nxp.com \
    --cc=xiaoliang.yang_1@nxp.com \
    --cc=xiyou.wangcong@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.