nvmet: use invalid cmd opcode helper
authorChaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Wed, 10 Feb 2021 05:47:57 +0000 (21:47 -0800)
committerChristoph Hellwig <hch@lst.de>
Wed, 10 Feb 2021 15:38:05 +0000 (16:38 +0100)
commit1c2c76136875d2329339275d431484a33dbb612d
tree49e087d1698104667a89576a9876367f20b662a3
parentd81d57cf1b4702b7c2fa8ce8f1d5c6961a0c20b5
nvmet: use invalid cmd opcode helper

In the NVMeOF block device backend, file backend, and passthru backend
we reject and report the commands if opcode is not handled.

Use the previously introduced helper in file backend to reduce the
duplicate code and make the error message uniform.

Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/target/io-cmd-file.c