On Wed, 9 Sep 2020 10:58:19 -0700 Shannon Nelson wrote:
> On 9/9/20 9:44 AM, Jakub Kicinski wrote:
> > On Wed, 9 Sep 2020 09:23:08 -0700 Shannon Nelson wrote:  
> >> On 9/8/20 4:54 PM, Jakub Kicinski wrote:  
> >>> On Tue,  8 Sep 2020 15:48:12 -0700 Shannon Nelson wrote:  
> >>>> +        dl = priv_to_devlink(ionic);
> >>>> +        devlink_flash_update_status_notify(dl, label, NULL, 1, timeout);
> >>>> +        start_time = jiffies;
> >>>> +        end_time = start_time + (timeout * HZ);
> >>>> +        do {
> >>>> +                mutex_lock(&ionic->dev_cmd_lock);
> >>>> +                ionic_dev_cmd_go(&ionic->idev, &cmd);
> >>>> +                err = ionic_dev_cmd_wait(ionic, DEVCMD_TIMEOUT);
> >>>> +                mutex_unlock(&ionic->dev_cmd_lock);
> >>>> +
> >>>> +                devlink_flash_update_status_notify(dl, label, NULL,
> >>>> +                                                   (jiffies - 
> >>>> start_time) / HZ,
> >>>> +                                                   timeout);  
> >>> That's not what I meant. I think we can plumb proper timeout parameter
> >>> through devlink all the way to user space.  
> >> Sure, but until that gets worked out, this should suffice.  
> > I don't understand - what will get worked out?  
> 
> I'm suggesting that this implementation using the existing devlink 
> logging services should suffice until someone can design, implement, and 
> get accepted a different bit of plumbing.  Unfortunately, that's not a 
> job that I can get to right now.

This hack is too nasty to be accepted.

So to be clear your options are:
 - plumb the single extra netlink parameter through to devlink
 - wait for someone else to do that for you, before you get firmware
   flashing accepted upstream.

Your "NIC" is quite "special", so you gotta be willing to lay the
groundwork it you want it to be supported upstream.

I already regret acking your weird live reset without proper APIs.
Now Mellanox is doing the plumbing for the exact same feature.

Reply via email to