nvmet: use req->cmd directly in bdev-ns fast path
The function nvmet_bdev_parse_io_cmd() is called from the fast path. The local variable to that function cmd is only used once. Remove the local variable and use req->cmd directly. Signed-off-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
This commit is contained in:
Родитель
87fd4cc1c0
Коммит
46eca4702d
|
@ -429,9 +429,7 @@ static void nvmet_bdev_execute_write_zeroes(struct nvmet_req *req)
|
||||||
|
|
||||||
u16 nvmet_bdev_parse_io_cmd(struct nvmet_req *req)
|
u16 nvmet_bdev_parse_io_cmd(struct nvmet_req *req)
|
||||||
{
|
{
|
||||||
struct nvme_command *cmd = req->cmd;
|
switch (req->cmd->common.opcode) {
|
||||||
|
|
||||||
switch (cmd->common.opcode) {
|
|
||||||
case nvme_cmd_read:
|
case nvme_cmd_read:
|
||||||
case nvme_cmd_write:
|
case nvme_cmd_write:
|
||||||
req->execute = nvmet_bdev_execute_rw;
|
req->execute = nvmet_bdev_execute_rw;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче