On Sat, Aug 03, 2024 at 11:50:54PM +0100, Al Viro wrote: > The best way to fix that is in dup_fd() - there we both can easily check > whether we might need to fix anything up and see which word needs the > upper bits cleared. PS: we could try and handle that in copy_fd_bitmaps() instead, but there it's harder to tell whether we need to bother in the first place, so that add overhead on a fairly hot paths.