On Wed, Oct 7, 2020 at 12:40 PM Christoph Hellwig <hch@xxxxxx> wrote: > > On Wed, Oct 07, 2020 at 11:28:58AM +0200, Arnd Bergmann wrote: > > The only one I have actually given up on is the atomisp staging driver, > > which uses an awful hack, copying the x86 implementation of > > copy_in_user()/compat_alloc_user_space() into the driver. > > That is gross. Just mark the driver as broken for now. Ah, it seems that Hans has already done that in commit 57e6b6f2303e ("media: atomisp_fops.c: disable atomisp_compat_ioctl32"), which removes the only reference to this code. In this case, I think a one-line change to stop building that file would be best, then if anyone ever wants to fix the bug that Hans and Sakari found, they get to do also deal with replacing compat_alloc_user_space(). I'll send a patch for that right away, the patch I have in my tree was so evil that I hadn't dared submit that, but it was useful for compile-testing the compat_alloc_user_space() removal patch. Arnd