Re: [PATCH net-next RFC 01/13] devlink: Add reload level option to devlink reload command

From: Jakub Kicinski
Date: Mon Aug 10 2020 - 14:17:31 EST


On Mon, 10 Aug 2020 10:09:20 -0700 Jacob Keller wrote:
> >> But I am still missing something: fw-activate implies that it will
> >> activate a new FW image stored on flash, pending activation. What if the
> >> user wants to reset and reload the FW if no new FW pending ? Should we
> >> add --force option to fw-activate level ?
> >
> > Since reload does not check today if anything changed - i.e. if reload
> > is actually needed, neither should fw-activate, IMO. I'd expect the
> > "--force behavior" to be the default.
> >
>
> Yep. What about if there is HW/FW that can't initiate the fw-activate
> reset unless there is a pending update? I think ice firmware might
> respond to the "please reset/activate" command with a specific status
> code indicating that no update was pending.
>
> I think the simplest solution is to just interpret this as a success.
> Alternatively we could report a specific error to inform user that no
> activation took place?

I'd do EOPNOTSUPP + extack.