From a27cb25b64d9737df3e12f970ef9b5b638f7907f Mon Sep 17 00:00:00 2001 From: Andrey Shvetsov Date: Fri, 9 Sep 2016 15:25:39 +0200 Subject: [PATCH] staging: most: hdm-usb: unify returned errors This patch is needed to return the same error codes for the same error cases in the functions show_value() and store_value(). Signed-off-by: Andrey Shvetsov Signed-off-by: Christian Gromm Signed-off-by: Greg Kroah-Hartman --- drivers/staging/most/hdm-usb/hdm_usb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/most/hdm-usb/hdm_usb.c b/drivers/staging/most/hdm-usb/hdm_usb.c index c82b8c1c0fc0..9c9a43835305 100644 --- a/drivers/staging/most/hdm-usb/hdm_usb.c +++ b/drivers/staging/most/hdm-usb/hdm_usb.c @@ -1083,7 +1083,7 @@ static ssize_t show_value(struct most_dci_obj *dci_obj, reg_addr = dci_obj->reg_addr; else if (get_static_reg_addr(ro_regs, attr->attr.name, ®_addr) && get_static_reg_addr(rw_regs, attr->attr.name, ®_addr)) - return -EIO; + return -EFAULT; err = drci_rd_reg(dci_obj->usb_device, reg_addr, &tmp_val); if (err < 0) -- 2.39.5