Partially revert "block: fail op_is_write() requests to read-only partitions"
Linus Torvalds authored
It turns out that commit 721c7fc7 ("block: fail op_is_write()
requests to read-only partitions"), while obviously correct, causes
problems for some older lvm2 installations.

The reason is that the lvm snapshotting will continue to write to the
snapshow COW volume, even after the volume has been marked read-only.
End result: snapshot failure.

This has actually been fixed in newer version of the lvm2 tool, but the
old tools still exist, and the breakage was reported both in the kernel
bugzilla and in the Debian bugzilla:

  https://bugzilla.kernel.org/show_bug.cgi?id=200439
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=900442

The lvm2 fix is here

  https://sourceware.org/git/?p=lvm2.git;a=commit;h=a6fdb9d9d70f51c49ad11a87ab4243344e6701a3

but until everybody has updated to recent versions, we'll have to weaken
the "never write to read-only partitions" check.  It now allows the
write to happen, but causes a warning, s...
a32e236e
Name Last commit Last update
..
partitions treewide: Use array_size() in vzalloc()
Kconfig docs: Fix some broken references
Kconfig.iosched License cleanup: add SPDX GPL-2.0 license identifier to files with no license
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license
badblocks.c badblocks: fix wrong return value in badblocks_set if badblocks are disabled
bfq-cgroup.c block: use ktime_get_ns() instead of sched_clock() for cfq and bfq
bfq-iosched.c block, bfq: prevent soft_rt_next_start from being stuck at infinity
bfq-iosched.h block, bfq: remove slow-system class
bfq-wf2q.c block, bfq: limit sectors served with interactive weight raising
bio-integrity.c block: Convert bio_set to mempool_init()
bio.c Merge tag 'for-linus-20180727' of git://git.kernel.dk/linux-block
blk-cgroup.c blkcg: init root blkcg_gq under lock
blk-core.c Partially revert "block: fail op_is_write() requests to read-only partitions"
blk-exec.c blk-mq-sched: remove unused 'can_block' arg from blk_mq_sched_insert_request
blk-flush.c block: fix use-after-free in block flush handling
blk-integrity.c block drivers/block: Use octal not symbolic permissions
blk-ioc.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license
blk-lib.c block: break discard submissions into the user defined size
blk-map.c Merge branch 'for-4.16/block' of git://git.kernel.dk/linux-block
blk-merge.c block: don't use blocking queue entered for recursive bio submits
blk-mq-cpumap.c blk-mq: don't keep offline CPUs mapped to hctx 0
blk-mq-debugfs.c blk-mq-debugfs: Off by one in blk_mq_rq_state_name()
blk-mq-debugfs.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license
blk-mq-pci.c blk-mq: Allow PCI vector offset for mapping queues
blk-mq-rdma.c block: Add rdma affinity based queue mapping helper
blk-mq-sched.c
blk-mq-sched.h
blk-mq-sysfs.c
blk-mq-tag.c
blk-mq-tag.h
blk-mq-virtio.c
blk-mq.c
blk-mq.h
blk-settings.c
blk-softirq.c
blk-stat.c
blk-stat.h
blk-sysfs.c
blk-tag.c
blk-throttle.c
blk-timeout.c
blk-wbt.c
blk-wbt.h
blk-zoned.c
blk.h
bounce.c
bsg-lib.c
bsg.c
cfq-iosched.c
cmdline-parser.c
compat_ioctl.c
deadline-iosched.c
elevator.c
genhd.c
ioctl.c
ioprio.c
kyber-iosched.c
mq-deadline.c
noop-iosched.c
opal_proto.h
partition-generic.c
scsi_ioctl.c
sed-opal.c
t10-pi.c