summaryrefslogtreecommitdiffstats
path: root/drivers/hid/hid-lg4ff.c
diff options
context:
space:
mode:
authorMichal Malý <madcatxster@devoid-pointer.net>2015-04-08 22:56:51 +0200
committerJiri Kosina <jkosina@suse.cz>2015-05-07 16:27:17 +0200
commitd61a70ec93251d77608864e0f6daf6dd1bfd4a6f (patch)
treedd20931fe443660a33214376306a08c08019943d /drivers/hid/hid-lg4ff.c
parent5d9d60ad308c867b271cc03233f2c93a0f5d80ec (diff)
downloadtalos-obmc-linux-d61a70ec93251d77608864e0f6daf6dd1bfd4a6f.tar.gz
talos-obmc-linux-d61a70ec93251d77608864e0f6daf6dd1bfd4a6f.zip
HID: hid-lg4ff: Allow the driver to continue without sysfs interface
Allow the driver to continue without sysfs interface. Instead of bailing out allow the driver to continue in a degraded mode. Signed-off-by: Michal Malý <madcatxster@devoid-pointer.net> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-lg4ff.c')
-rw-r--r--drivers/hid/hid-lg4ff.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/hid/hid-lg4ff.c b/drivers/hid/hid-lg4ff.c
index dcaf481ddee0..02cec83caac3 100644
--- a/drivers/hid/hid-lg4ff.c
+++ b/drivers/hid/hid-lg4ff.c
@@ -1229,15 +1229,14 @@ int lg4ff_init(struct hid_device *hid)
/* Create sysfs interface */
error = device_create_file(&hid->dev, &dev_attr_range);
if (error)
- goto err_init;
+ hid_warn(hid, "Unable to create sysfs interface for \"range\", errno %d\n", error);
if (mmode_ret == LG4FF_MMODE_IS_MULTIMODE) {
error = device_create_file(&hid->dev, &dev_attr_real_id);
if (error)
- goto err_init;
-
+ hid_warn(hid, "Unable to create sysfs interface for \"real_id\", errno %d\n", error);
error = device_create_file(&hid->dev, &dev_attr_alternate_modes);
if (error)
- goto err_init;
+ hid_warn(hid, "Unable to create sysfs interface for \"alternate_modes\", errno %d\n", error);
}
dbg_hid("sysfs interface created\n");
OpenPOWER on IntegriCloud