On Wed, Jun 17, 2020 at 12:29:40PM -0300, Jason Gunthorpe wrote: > On Wed, Jun 17, 2020 at 09:57:54AM +0200, Daniel Vetter wrote: > > > > At the very least I think there should be some big warning that > > > dma_fence in notifiers should be avoided. > > > > Yeah I'm working on documentation, and also the notifiers here > > hopefully make it clear it's massive pain. I think we could even make > > a hard rule that dma_fence in mmu notifier outside of drivers/gpu is a > > bug/misfeature. > > Yep! > > > Might be a good idea to add a MAINTAINERS entry with a K: regex > > pattern, so that you can catch such modifiers. We do already have such > > a pattern for dma-fence, to catch abuse. So if you want I could type > > up a documentation patch for this, get your and others acks and the > > dri-devel folks would enforce that the dma_fence_wait madness doesn't > > leak beyond drivers/gpu > > It seems like the best thing Just thought about where to best put this, and I think including it as another paragraph in the next round of this series makes the most sense. You'll get cc'ed for acking when that happens - might take a while since there's a lot of details here all over to sort out. -Daniel > > > Oded has agreed to remove the dma-fence usage, since they really don't > > need it (and all the baggage that comes with it), plain old completion > > is enough for their use. This use is also why I added the regex to > > MAINTAINERS, so that in the future we can catch people who try to use > > dma_fence because it looks cute and useful, and are completely > > oblivious to all the pain and headaches involved. > > This is good! > > Thanks, > Jason -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch