HID: hid-lenovo-tpkbd: remove doubled hid_get_drvdata
authorJiri Slaby <jslaby@suse.cz>
Thu, 4 Apr 2013 20:32:12 +0000 (22:32 +0200)
committerJiri Kosina <jkosina@suse.cz>
Thu, 4 Apr 2013 22:37:02 +0000 (00:37 +0200)
In pointer_press_speed_show, we do
    data_pointer = hid_get_drvdata(hdev);
twice in a row. Remove one of those.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-lenovo-tpkbd.c

index 956c3b135f64fe61e4a4636e2e81e911ad3ee141..c842ece2be378cbd38a94486c130b3b091ccd89d 100644 (file)
@@ -228,8 +228,6 @@ static ssize_t pointer_press_speed_show(struct device *dev,
        struct hid_device *hdev = container_of(dev, struct hid_device, dev);
        struct tpkbd_data_pointer *data_pointer = hid_get_drvdata(hdev);
 
-       data_pointer = hid_get_drvdata(hdev);
-
        return snprintf(buf, PAGE_SIZE, "%u\n",
                data_pointer->press_speed);
 }