• M
    dm: make sure to obey max_io_len_target_boundary · 51b86f9a
    Michael Lass 提交于
    Commit 61697a6a ("dm: eliminate 'split_discard_bios' flag from DM
    target interface") incorrectly removed code from
    __send_changing_extent_only() that is required to impose a per-target IO
    boundary on IO that exceeds max_io_len_target_boundary().  Otherwise
    "special" IO (e.g. DISCARD, WRITE SAME, WRITE ZEROES) can write beyond
    where allowed.
    
    Fix this by restoring the max_io_len_target_boundary() limit in
    __send_changing_extent_only()
    
    Fixes: 61697a6a ("dm: eliminate 'split_discard_bios' flag from DM target interface")
    Cc: stable@vger.kernel.org # 5.1+
    Signed-off-by: NMichael Lass <bevan@bi-co.net>
    Signed-off-by: NMike Snitzer <snitzer@redhat.com>
    51b86f9a
dm.c 73.9 KB