[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1e78f7c7-e1c9-01c7-c4a6-6936a3499398@pensando.io>
Date: Thu, 17 Sep 2020 13:46:46 -0700
From: Shannon Nelson <snelson@...sando.io>
To: Jakub Kicinski <kuba@...nel.org>
Cc: netdev@...r.kernel.org, davem@...emloft.net
Subject: Re: [PATCH v4 net-next 2/5] devlink: collect flash notify params into
a struct
On 9/17/20 12:47 PM, Jakub Kicinski wrote:
> On Wed, 16 Sep 2020 20:02:01 -0700 Shannon Nelson wrote:
>> The dev flash status notify function parameter lists are getting
>> rather long, so add a struct to be filled and passed rather than
>> continuously changing the function signatures.
>>
>> Signed-off-by: Shannon Nelson <snelson@...sando.io>
>> ---
>> include/net/devlink.h | 21 ++++++++++++
>> net/core/devlink.c | 80 +++++++++++++++++++++++--------------------
>> 2 files changed, 63 insertions(+), 38 deletions(-)
>>
>> diff --git a/include/net/devlink.h b/include/net/devlink.h
>> index f206accf80ad..9ab2014885cb 100644
>> --- a/include/net/devlink.h
>> +++ b/include/net/devlink.h
>> @@ -391,6 +391,27 @@ struct devlink_param_gset_ctx {
>> enum devlink_param_cmode cmode;
>> };
>>
>> +/**
>> + * struct devlink_flash_notify - devlink dev flash notify data
>> + * @cmd: devlink notify command code
>> + * @status_msg: current status string
>> + * @component: firmware component being updated
>> + * @done: amount of work completed of total amount
>> + * @total: amount of work expected to be done
>> + * @timeout: expected max timeout in seconds
>> + *
>> + * These are values to be given to userland to be displayed in order
>> + * to show current activity in a firmware update process.
>> + */
>> +struct devlink_flash_notify {
>> + enum devlink_command cmd;
> I'd leave out cmd out of the params structure, otherwise I'll be
> slightly awkward for drivers to fill in given the current helpers
> are per cmd.
Sure. I wavered back and forth on that, no problem to change it.
sln
Powered by blists - more mailing lists