On Fri, Sep 20, 2024 at 10:25:54AM +1000, Dave Chinner wrote: > > Sure. If you have a better idea I'm all ears, too. > > I would have thought a -EBUSY error would have been appropriate. > i.e. there was an extending write in progress (busy doing IO) so we > couldn't perform the zeroing operation and hence the write needs to > be restarted now the IO has been drained... I can't say that I'm a huge fan of overloading errno values when there is quite a few call that could return basically arbitrary errors in the chain. See the "fix a DEBUG-only assert failure in xfs/538" series for when this kind of errno overloading causes problems later on in unexpected ways.