Re: [PATCH 3/5] fs/locks: change all *_conflict() functions to return a new enum.

2018-08-09 Thread J. Bruce Fields
On Fri, Aug 10, 2018 at 09:40:35AM +1000, NeilBrown wrote: > caller_fl is first and sys_fl is second. > > if sys_fl, the second, is a read lock, and caller_fl, the first, is a > write lock, they clearly conflict but any other lock that conflict > with caller_fl (The write lock) would *not* necessa

Re: [PATCH 3/5] fs/locks: change all *_conflict() functions to return a new enum.

2018-08-09 Thread NeilBrown
On Thu, Aug 09 2018, J. Bruce Fields wrote: > On Thu, Aug 09, 2018 at 12:04:41PM +1000, NeilBrown wrote: >> In a future patch we will need to differentiate between conflicts that >> are "transitive" and those that aren't. >> A "transitive" conflict is defined as one where any lock that >> conflict

Re: [PATCH 3/5] fs/locks: change all *_conflict() functions to return a new enum.

2018-08-09 Thread J. Bruce Fields
On Thu, Aug 09, 2018 at 12:04:41PM +1000, NeilBrown wrote: > In a future patch we will need to differentiate between conflicts that > are "transitive" and those that aren't. > A "transitive" conflict is defined as one where any lock that > conflicts with the first (newly requested) lock would confl

Re: [PATCH 3/5] fs/locks: change all *_conflict() functions to return a new enum.

2018-08-09 Thread Jeff Layton
On Thu, 2018-08-09 at 12:04 +1000, NeilBrown wrote: > In a future patch we will need to differentiate between conflicts that > are "transitive" and those that aren't. > A "transitive" conflict is defined as one where any lock that > conflicts with the first (newly requested) lock would conflict wit

[PATCH 3/5] fs/locks: change all *_conflict() functions to return a new enum.

2018-08-08 Thread NeilBrown
In a future patch we will need to differentiate between conflicts that are "transitive" and those that aren't. A "transitive" conflict is defined as one where any lock that conflicts with the first (newly requested) lock would conflict with the existing lock. So change posix_locks_conflict(), floc