On Mon, 28 Oct 2024 at 01:17, Christian Brauner <brauner@xxxxxxxxxx> wrote: > > Thanks for catching this. So what I did is: You had better remove the __randomize_layout from 'struct file' too, otherwise your patch is entirely broken. We should damn well remove it anyway, the whole struct randomization is just a bad joke. Nobody sane enables it, afaik. But for your patch in particular, it's now an active bug. Also, I wonder if we would be better off with f_count _away_ from the other fields we touch, because the file count ref always ends up making it cpu-local, so no shared caching behavior. We had that reported for the inode contents. So any threaded use of the same file will end up bouncing not just the refcount, but also won't be caching some of the useful info at the beginning of the file, that is basically read-only and could be shared across CPUs. Linus