[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y2YsSfcGgrxuuivW@nanopsycho>
Date: Sat, 5 Nov 2022 10:26:33 +0100
From: Jiri Pirko <jiri@...nulli.us>
To: Jakub Kicinski <kuba@...nel.org>
Cc: netdev@...r.kernel.org, davem@...emloft.net, pabeni@...hat.com,
edumazet@...gle.com
Subject: Re: [patch net-next] net: devlink: expose the info about version
representing a component
Sat, Nov 05, 2022 at 03:25:10AM CET, kuba@...nel.org wrote:
>On Fri, 4 Nov 2022 16:24:25 +0100 Jiri Pirko wrote:
>> If certain version exposed by a driver is marked to be representing a
>> component, expose this info to the user.
>>
>> Example:
>> $ devlink dev info
>> netdevsim/netdevsim10:
>> driver netdevsim
>> versions:
>> running:
>> fw.mgmt 10.20.30
>> flash_components:
>> fw.mgmt
>
>Didn't I complain that this makes no practical sense because
>user needs to know what file to flash, to which component?
>Or was that a different flag that I was complaining about?
Different. That was about exposing a default component.
>
>> diff --git a/include/uapi/linux/devlink.h b/include/uapi/linux/devlink.h
>> index 2f24b53a87a5..7f2874189188 100644
>> --- a/include/uapi/linux/devlink.h
>> +++ b/include/uapi/linux/devlink.h
>> @@ -607,6 +607,8 @@ enum devlink_attr {
>>
>> DEVLINK_ATTR_SELFTESTS, /* nested */
>>
>> + DEVLINK_ATTR_INFO_VERSION_IS_COMPONENT, /* u8 0 or 1 */
>
>In the interest of fairness I should complain about the use of u8/u16
>
>devlink is genetlink so user will know kernel supports the attribute
>(by looking at family->maxattr). So this can be a flag.
Okay, makes sense.
Powered by blists - more mailing lists