On Mon, 2024-09-30 at 11:52 +0000, bernacki@xxxxxxxxxxxx wrote: > Tim, > > [...] > > Why is it useful to return the same `loc` value that was passed in, > > rather than just returning `0`? The caller already knows the value > > of > > `loc`, so they aren't being told anything new. > > > > I think this should continue to return `0` for success. > > I think Jan just followed the conventions, when he returned 'loc' > instead of > '0', some others request/release locality function do exactly the > same. > > [...] > > For each of these ` WARN_ONCE((chip->locality < 0), ...).`, can it > > return immediately rather than attempting to continue using an > > invalid > > locality value? Do the following commands have a chance of > > succeeding > > with the invalid value? > > WARN_ONCE() macro does not remove checking of locality. If I > understand > the code correctly layer above should not called this function if > request locality fails, so this code is an extra check. > I can remove it in the next patchset if you want. > > Jarkko, > > Would it be possible to merge this changes. Patch 1. has already been > merged, > only 2 and 3 are still waiting. Do you want me to create a new > patchset for > these two patches? Send a rebased version that applies. Let's check that through then. Quick recap and some time gone, I don't see anything extremely bad. Still acking patches that even do not apply is not possible. So yeah, send. If glitches are spotted in worst case this means two rounds. > > thanks, > greg BR, Jarkko