> We historically allow a writable fd on block devices even when they > are read-only. I suspect your use case is doing that and the new > check for write_iter is interfering with that: After deleting the "if ((mode & BLK_OPEN_WRITE) && !file->f_op->write_iter)", everything should be normal.