On Fri, Mar 30, 2018 at 08:45:50AM -0600, David Ahern wrote: > On 3/29/18 2:33 PM, Ido Schimmel wrote: > > From: Jiri Pirko <j...@mellanox.com> > > > > This resolves race during initialization where the resources with > > ops are registered before driver and the structures used by occ_get > > op is initialized. So keep occ_get callbacks registered only when > > all structs are initialized. > > Why can't the occ_get handler look at some flag in an mlxsw struct to > know if the system has initialized? > > Separate registration here is awkward. You register a resource and then > register its op later. > > Also, this should be a standalone patch rather than embedded in a > 'mlxsw: Various cleanups' set.
I'll drop it from v2 and ask Jiri to post it as a standalone patch.