bool isp_updater(const u8 *fw_data, const size_t fw_size, const struct sec_ts_platform_data *sec_pdata) { bool result = true; set_power = sec_pdata->set_power; GPIO_IRQ = sec_pdata->gpio_irq; GPIO_SCL = sec_pdata->gpio_scl; GPIO_SDA = sec_pdata->gpio_sda; touch_i2c_to_gpio(true); if (fw_download(fw_data, fw_size) < 0) result = false; touch_i2c_to_gpio(false); return result; }
static int es705_slim_device_up(struct slim_device *sbdev) { struct es705_priv *priv; int rc; #ifdef CONFIG_SND_SOC_ES704_TEMP dev_selected = 1; #endif dev_info(&sbdev->dev, "%s(): name=%s\n", __func__, sbdev->name); dev_info(&sbdev->dev, "%s(): laddr=%d\n", __func__, sbdev->laddr); /* Start the firmware download in the workqueue context. */ priv = slim_get_devicedata(sbdev); if (strncmp(sbdev->name, CODEC_INTF_ID, strnlen(CODEC_INTF_ID, SLIMBUS_NAME_SIZE)) == 0) return 0; rc = fw_download(priv); BUG_ON(rc != 0); #if defined(SAMSUNG_ES705_FEATURE) if (priv->power_control) priv->power_control(ES705_SET_POWER_STATE_SLEEP, ES705_POWER_STATE); #endif return rc; }