summaryrefslogtreecommitdiff
path: root/drivers/acpi/nfit
diff options
context:
space:
mode:
authorZhang Qilong <zhangqilong3@huawei.com>2020-10-27 21:49:01 +0800
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2020-10-27 19:34:56 +0100
commit85f971b65a692b68181438e099b946cc06ed499b (patch)
tree2063798f30fade6679483f578d2b2f5993a48585 /drivers/acpi/nfit
parent3650b228f83adda7e5ee532e2b90429c03f7b9ec (diff)
ACPI: NFIT: Fix comparison to '-ENXIO'
Initial value of rc is '-ENXIO', and we should use the initial value to check it. Signed-off-by: Zhang Qilong <zhangqilong3@huawei.com> Reviewed-by: Pankaj Gupta <pankaj.gupta.linux@gmail.com> Reviewed-by: Vishal Verma <vishal.l.verma@intel.com> [ rjw: Subject edit ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/nfit')
-rw-r--r--drivers/acpi/nfit/core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/acpi/nfit/core.c b/drivers/acpi/nfit/core.c
index 756227837b3b..3a3c209ed3d3 100644
--- a/drivers/acpi/nfit/core.c
+++ b/drivers/acpi/nfit/core.c
@@ -1564,7 +1564,7 @@ static ssize_t format1_show(struct device *dev,
le16_to_cpu(nfit_dcr->dcr->code));
break;
}
- if (rc != ENXIO)
+ if (rc != -ENXIO)
break;
}
mutex_unlock(&acpi_desc->init_mutex);