diff options
author | Ziyan <jaraidaniel@gmail.com> | 2016-01-05 16:57:12 +0100 |
---|---|---|
committer | Ziyan <jaraidaniel@gmail.com> | 2016-01-08 10:44:51 +0100 |
commit | 3f90fbb2db74fe04e7c49c1573b61d6cf90e6bb4 (patch) | |
tree | c2f9da4b4ee1e77b0ac91a5ddaf6e9396e415325 /drivers/input | |
parent | 8a300ec0aa85c4520ee140dd6dfb8ef9f3c5a42f (diff) | |
download | kernel_samsung_tuna-3f90fbb2db74fe04e7c49c1573b61d6cf90e6bb4.zip kernel_samsung_tuna-3f90fbb2db74fe04e7c49c1573b61d6cf90e6bb4.tar.gz kernel_samsung_tuna-3f90fbb2db74fe04e7c49c1573b61d6cf90e6bb4.tar.bz2 |
input: mms_ts: store the firmware in the kernel
It makes more sense to just store it in the kernel, so it doesn't have
to wait for the filesystem to get mounted.
Change-Id: I738ad7f55064724fdaa46e725faf6d407b42c8fb
Diffstat (limited to 'drivers/input')
-rwxr-xr-x | drivers/input/touchscreen/mms_ts.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/drivers/input/touchscreen/mms_ts.c b/drivers/input/touchscreen/mms_ts.c index 69c5bb5..0411657 100755 --- a/drivers/input/touchscreen/mms_ts.c +++ b/drivers/input/touchscreen/mms_ts.c @@ -63,6 +63,11 @@ enum { #define ISP_MAX_FW_SIZE (0x1F00 * 4) #define ISP_IC_INFO_ADDR 0x1F00 +#define FW_NAME_REV31 "melfas/mms144_ts_rev31.fw" +#define FW_NAME_REV32 "melfas/mms144_ts_rev32.fw" +MODULE_FIRMWARE(FW_NAME_REV31); +MODULE_FIRMWARE(FW_NAME_REV32); + static bool mms_force_reflash = false; module_param_named(force_reflash, mms_force_reflash, bool, S_IWUSR | S_IRUGO); @@ -726,22 +731,22 @@ static int __devinit mms_ts_config(struct mms_ts_info *info, bool nowait) { struct i2c_client *client = info->client; int ret = 0; - const char *filename = info->pdata->fw_name ?: "mms144_ts.fw"; + const char *filename = info->pdata->fw_name ?: "melfas/mms144_ts_rev32.fw"; mms_pwr_on_reset(info); + info->fw_name = kasprintf(GFP_KERNEL, "melfas/%s", filename); + if (nowait) { const struct firmware *fw; - info->fw_name = kasprintf(GFP_KERNEL, "melfas/%s", filename); ret = request_firmware(&fw, info->fw_name, &client->dev); if (ret) { dev_err(&client->dev, - "error requesting built-in firmware\n"); + "error requesting built-in firmware: %s\n", filename); goto out; } mms_ts_fw_load(fw, info); } else { - info->fw_name = kstrdup(filename, GFP_KERNEL); ret = request_firmware_nowait(THIS_MODULE, true, info->fw_name, &client->dev, GFP_KERNEL, info, mms_ts_fw_load); |