Re: [PATCH net-next] devlink: Require devlink lock during device reload

From
Jiri Pirko <jiri@resnulli.us>
Date
2021-11-11 12:05:19
Also in
lkml
Reply to
Jason Gunthorpe, 2021-11-09
Tue, Nov 09, 2021 at 07:24:27PM CET, jgg@nvidia.com wrote:
On Tue, Nov 09, 2021 at 08:20:42AM -0800, Jakub Kicinski wrote:
quoted
On Tue, 9 Nov 2021 11:33:35 -0400 Jason Gunthorpe wrote:
quoted
quoted
quoted
I once sketched out fixing this by removing the need to hold the
per_net_rwsem just for list iteration, which in turn avoids holding it
over the devlink reload paths. It seemed like a reasonable step toward
finer grained locking.  
Seems to me the locking is just a symptom.  
My fear is this reload during net ns destruction is devlink uAPI now
and, yes it may be only a symptom, but the root cause may be unfixable
uAPI constraints.
If I'm reading this right it locks up 100% of the time, what is a uAPI
for? DoS? ;)

Hence my questions about the actual use cases.
Removing namespace support from devlink would solve the crasher. I
certainly didn't feel bold enough to suggest such a thing :)

If no other devlink driver cares about this it is probably the best
idea.
Devlink namespace support is not generic, not related to any driver.
Jason
Thread (42 messages) 42 messages, 5 authors, last reply 2021-11-17
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help