[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YsqVHWhNLOP5qKlk@shredder>
Date: Sun, 10 Jul 2022 12:00:13 +0300
From: Ido Schimmel <idosch@...sch.org>
To: Jakub Kicinski <kuba@...nel.org>, vikas.gupta@...adcom.com
Cc: jiri@...dia.com, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, davem@...emloft.net,
dsahern@...nel.org, stephen@...workplumber.org,
edumazet@...gle.com, pabeni@...hat.com, ast@...nel.org,
leon@...nel.org, linux-doc@...r.kernel.org, corbet@....net,
michael.chan@...adcom.com, andrew.gospodarek@...adcom.com
Subject: Re: [PATCH net-next v2 1/3] devlink: introduce framework for
selftests
On Thu, Jul 07, 2022 at 06:20:22PM -0700, Jakub Kicinski wrote:
> On Thu, 7 Jul 2022 23:59:48 +0530 Vikas Gupta wrote:
> > static const struct genl_small_ops devlink_nl_ops[] = {
> > @@ -9361,6 +9493,18 @@ static const struct genl_small_ops devlink_nl_ops[] = {
> > .doit = devlink_nl_cmd_trap_policer_set_doit,
> > .flags = GENL_ADMIN_PERM,
> > },
> > + {
> > + .cmd = DEVLINK_CMD_SELFTESTS_SHOW,
> > + .validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
>
> I think we can validate strict for new commands, so no validation flags
> needed.
>
> > + .doit = devlink_nl_cmd_selftests_show,
>
> What about dump? Listing all tests on all devices?
>
> > + .flags = GENL_ADMIN_PERM,
Related to Jakub's question, is there a reason that the show command
requires 'GENL_ADMIN_PERM' ?
> > + },
> > + {
> > + .cmd = DEVLINK_CMD_SELFTESTS_RUN,
> > + .validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
> > + .doit = devlink_nl_cmd_selftests_run,
> > + .flags = GENL_ADMIN_PERM,
> > + },
> > };
> >
> > static struct genl_family devlink_nl_family __ro_after_init = {
>
Powered by blists - more mailing lists