Commit a27cb25b authored by Andrey Shvetsov's avatar Andrey Shvetsov Committed by Greg Kroah-Hartman
Browse files

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: default avatarAndrey Shvetsov <andrey.shvetsov@k2l.de>
Signed-off-by: default avatarChristian Gromm <christian.gromm@microchip.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a747b42c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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, &reg_addr) &&
		 get_static_reg_addr(rw_regs, attr->attr.name, &reg_addr))
		return -EIO;
		return -EFAULT;

	err = drci_rd_reg(dci_obj->usb_device, reg_addr, &tmp_val);
	if (err < 0)