• C
    nvmet: add ns write protect support · dedf0be5
    Chaitanya Kulkarni 提交于
    This patch implements the Namespace Write Protect feature described in
    "NVMe TP 4005a Namespace Write Protect". In this version, we implement
    No Write Protect and Write Protect states for target ns which can be
    toggled by set-features commands from the host side.
    
    For write-protect state transition, we need to flush the ns specified
    as a part of command so we also add helpers for carrying out synchronous
    flush operations.
    Signed-off-by: NChaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
    [hch: fixed an incorrect endianess conversion, minor cleanups]
    Signed-off-by: NChristoph Hellwig <hch@lst.de>
    dedf0be5
io-cmd-file.c 8.4 KB