Commit ec45f016 authored by Todd Poynor's avatar Todd Poynor Committed by Greg Kroah-Hartman

staging: gasket: don't treat no device reset callback as an error

It is not an error for a device to not have a reset callback registered.
Signed-off-by: default avatarSimon Que <sque@chromium.org>
Signed-off-by: default avatarTodd Poynor <toddpoynor@google.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent ed6e96c7
...@@ -1836,11 +1836,8 @@ int gasket_reset_nolock(struct gasket_dev *gasket_dev, uint reset_type) ...@@ -1836,11 +1836,8 @@ int gasket_reset_nolock(struct gasket_dev *gasket_dev, uint reset_type)
const struct gasket_driver_desc *driver_desc; const struct gasket_driver_desc *driver_desc;
driver_desc = gasket_dev->internal_desc->driver_desc; driver_desc = gasket_dev->internal_desc->driver_desc;
if (!driver_desc->device_reset_cb) { if (!driver_desc->device_reset_cb)
gasket_log_error( return 0;
gasket_dev, "No device reset callback was registered.");
return -EINVAL;
}
/* Perform a device reset of the requested type. */ /* Perform a device reset of the requested type. */
ret = driver_desc->device_reset_cb(gasket_dev, reset_type); ret = driver_desc->device_reset_cb(gasket_dev, reset_type);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment