Commit f4524cc4 authored by Maxim Levitsky's avatar Maxim Levitsky Committed by Christoph Hellwig

nvme-pci: add known admin effects to augument admin effects log page

Add known admin effects even if hardware has known admin effects page,
since hardware can't be ever trusted to report sane values.
(on my Intel DC P3700, it reports no side effects for namespace format)
Signed-off-by: default avatarMaxim Levitsky <mlevitsk@redhat.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent e8fd41bb
...@@ -1257,10 +1257,9 @@ static u32 nvme_passthru_start(struct nvme_ctrl *ctrl, struct nvme_ns *ns, ...@@ -1257,10 +1257,9 @@ static u32 nvme_passthru_start(struct nvme_ctrl *ctrl, struct nvme_ns *ns,
return 0; return 0;
} }
effects |= nvme_known_admin_effects(opcode);
if (ctrl->effects) if (ctrl->effects)
effects = le32_to_cpu(ctrl->effects->acs[opcode]); effects = le32_to_cpu(ctrl->effects->acs[opcode]);
else
effects = nvme_known_admin_effects(opcode);
/* /*
* For simplicity, IO to all namespaces is quiesced even if the command * For simplicity, IO to all namespaces is quiesced even if the command
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment