staging: usbip: usbip_host_driver.c: avoid assignment in if
Fix coding style issue "do not use assignment in if condition" detected by checkpatch.pl in usbip_host_driver.c. Signed-off-by: Wahib Faizi <wahibfaizi@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0c248b621b
commit
da87dba817
1 changed files with 2 additions and 1 deletions
|
|
@ -47,7 +47,8 @@ static int32_t read_attr_usbip_status(struct usbip_usb_device *udev)
|
||||||
snprintf(status_attr_path, SYSFS_PATH_MAX, "%s/usbip_status",
|
snprintf(status_attr_path, SYSFS_PATH_MAX, "%s/usbip_status",
|
||||||
udev->path);
|
udev->path);
|
||||||
|
|
||||||
if ((fd = open(status_attr_path, O_RDONLY)) < 0) {
|
fd = open(status_attr_path, O_RDONLY);
|
||||||
|
if (fd < 0) {
|
||||||
err("error opening attribute %s", status_attr_path);
|
err("error opening attribute %s", status_attr_path);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue