Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1392354 > unrolled thread
| Started by | Dan Williams <dan.j.williams@intel.com> |
|---|---|
| First post | 2016-05-02 18:30 +0200 |
| Last post | 2016-05-03 09:20 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH] nfit: fix translation of command status results Dan Williams <dan.j.williams@intel.com> - 2016-05-02 18:30 +0200
Re: [PATCH] nfit: fix translation of command status results Johannes Thumshirn <jthmshirn@suse.de> - 2016-05-03 09:20 +0200
| From | Dan Williams <dan.j.williams@intel.com> |
|---|---|
| Date | 2016-05-02 18:30 +0200 |
| Subject | [PATCH] nfit: fix translation of command status results |
| Message-ID | <ruoTp-6N4-13@gated-at.bofh.it> |
When transportation of the command completes successfully, it indicates
that the 'status' result is valid. Fix the missed checking and
translation of the status field at the end of acpi_nfit_ctl().
Otherwise, we fail to handle reported errors and assume commands
complete successfully.
Reported-by: Linda Knippers <linda.knippers@hpe.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
---
drivers/acpi/nfit.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/acpi/nfit.c b/drivers/acpi/nfit.c
index d0f35e63640b..63cc9dbe4f3b 100644
--- a/drivers/acpi/nfit.c
+++ b/drivers/acpi/nfit.c
@@ -287,8 +287,11 @@ static int acpi_nfit_ctl(struct nvdimm_bus_descriptor *nd_desc,
offset);
rc = -ENXIO;
}
- } else
+ } else {
rc = 0;
+ if (cmd_rc)
+ *cmd_rc = xlat_status(buf, cmd);
+ }
out:
ACPI_FREE(out_obj);
[toc] | [next] | [standalone]
| From | Johannes Thumshirn <jthmshirn@suse.de> |
|---|---|
| Date | 2016-05-03 09:20 +0200 |
| Message-ID | <ruCMF-3wS-1@gated-at.bofh.it> |
| In reply to | #1392354 |
On Mon, May 02, 2016 at 09:25:41AM -0700, Dan Williams wrote: > When transportation of the command completes successfully, it indicates > that the 'status' result is valid. Fix the missed checking and > translation of the status field at the end of acpi_nfit_ctl(). > Otherwise, we fail to handle reported errors and assume commands > complete successfully. > > Reported-by: Linda Knippers <linda.knippers@hpe.com> > Signed-off-by: Dan Williams <dan.j.williams@intel.com> Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> -- Johannes Thumshirn Storage jthumshirn@suse.de +49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web