On Sun, 24 Feb 2019 12:03:19 +0100, Jiri Pirko wrote:
> Fri, Feb 22, 2019 at 11:07:57PM CET, jakub.kicin...@netronome.com wrote:
>> Commit 76726ccb7f46 ("devlink: add flash update command") and
>> commit 2d8dc5bbf4e7 ("devlink: Add support for reload")
>> access devlink ops without NULL-checking. Add the missing checks.
>> Note that all drivers currently implementing devlink pass non-NULL
>> ops, so this is not a problem.  
> 
> Wouldn't it be better to rather put WARN_ON&fail when driver calls
> devlink_alloc() with NULL ops and avoid these checks in the whole code?

Sounds good! Should I remove the existing ones?

Reply via email to