On Fri, Nov 13, 2020 at 08:37:39AM -0500, Dennis Dalessandro wrote: > On 11/12/2020 7:33 PM, Ira Weiny wrote: > > So I think the final point is the key to fixing the bug. Keeping any > > current->mm which is not the one we opened the file with... (or more > > specifically the one which first registered memory). In some ways this may be > > worse than before because technically the parent could open the fd and hand it > > to the child and have the child register with it's mm. But that is ok > > really... May just be odd behavior for some users depending on what operations > > they do and in what order. > > I don't think that's worse than before. 'worse' was a bad word... sorry. I just meant that the new code opens up the opportunity to get it to work with the child when this is really not the way I the API was intended... But now I am just bike shedding... ;-) > Before we were letting it operate on > the wrong mm. That's so much worse. Yes, parent could open fd and hand it > off, which is OK. The "odd" behavior is up to whoever wrote the user space > code to do that in the first place. > > > [1] Also, you probably should credit Jann for the idea with a suggested by tag. > > Will change reported-by to suggested-by. Ah yea both are appropriate. I'm not an expert on if both should be tagged or not... But to me it seems suggested-by is a bit stronger because a solution was provided beyond just a bug reported. Ira > > -Denny >