summaryrefslogtreecommitdiff
path: root/drivers/input/touchscreen/silead.c
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2016-09-08 05:25:37 +0300
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2016-09-10 20:49:12 +0300
commit43ba588346455dcc984dc98a49af1c2eb1e9aa75 (patch)
treeaefde270d98b14e8270a0a85492a3e6f9c19c112 /drivers/input/touchscreen/silead.c
parente3a888a4bff0bef0b256d55c58bc32c99fb44ece (diff)
downloadlinux-43ba588346455dcc984dc98a49af1c2eb1e9aa75.tar.xz
Input: silead_gsl1680 - document firmware-name, fix implementation
The driver has supported touchscreen-fw-name to specify the firmware to load since it has been merged, but this was omitted from the dt-binding documentation. During review of adding touchscreen-fw-name to the binding documentation it was brought up that there is a standard property name called "firmware-name" for this, which should be used. Since there are no users of touchscreen-fw-name yet, this commit adds documentation of "firmware-name" to the dt-binding documentation and switches the driver over to use this. This commit also makes the driver add a "silead/" prefix to the firmware name from dt before calling request_firmware. That the firmware files are stored under /lib/firmware/silead under Linux is an implementation detail and does not belong in devicetree. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/touchscreen/silead.c')
-rw-r--r--drivers/input/touchscreen/silead.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/input/touchscreen/silead.c b/drivers/input/touchscreen/silead.c
index b2744a64e933..c7ab116a16b3 100644
--- a/drivers/input/touchscreen/silead.c
+++ b/drivers/input/touchscreen/silead.c
@@ -390,9 +390,10 @@ static void silead_ts_read_props(struct i2c_client *client)
data->max_fingers = 5; /* Most devices handle up-to 5 fingers */
}
- error = device_property_read_string(dev, "touchscreen-fw-name", &str);
+ error = device_property_read_string(dev, "firmware-name", &str);
if (!error)
- snprintf(data->fw_name, sizeof(data->fw_name), "%s", str);
+ snprintf(data->fw_name, sizeof(data->fw_name),
+ "silead/%s", str);
else
dev_dbg(dev, "Firmware file name read error. Using default.");
}