wm8994 26 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994; wm8994 33 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 35 drivers/gpio/gpio-wm8994.c switch (wm8994->type) { wm8994 56 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 58 drivers/gpio/gpio-wm8994.c return wm8994_set_bits(wm8994, WM8994_GPIO_1 + offset, wm8994 65 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 68 drivers/gpio/gpio-wm8994.c ret = wm8994_reg_read(wm8994, WM8994_GPIO_1 + offset); wm8994 82 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 87 drivers/gpio/gpio-wm8994.c return wm8994_set_bits(wm8994, WM8994_GPIO_1 + offset, wm8994 94 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 99 drivers/gpio/gpio-wm8994.c wm8994_set_bits(wm8994, WM8994_GPIO_1 + offset, WM8994_GPN_LVL, value); wm8994 106 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 110 drivers/gpio/gpio-wm8994.c return wm8994_set_bits(wm8994, WM8994_GPIO_1 + offset, wm8994 114 drivers/gpio/gpio-wm8994.c return wm8994_set_bits(wm8994, WM8994_GPIO_1 + offset, wm8994 126 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 128 drivers/gpio/gpio-wm8994.c return regmap_irq_get_virq(wm8994->irq_data, offset); wm8994 190 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = wm8994_gpio->wm8994; wm8994 209 drivers/gpio/gpio-wm8994.c reg = wm8994_reg_read(wm8994, WM8994_GPIO_1 + i); wm8994 211 drivers/gpio/gpio-wm8994.c dev_err(wm8994->dev, wm8994 263 drivers/gpio/gpio-wm8994.c struct wm8994 *wm8994 = dev_get_drvdata(pdev->dev.parent); wm8994 264 drivers/gpio/gpio-wm8994.c struct wm8994_pdata *pdata = dev_get_platdata(wm8994->dev); wm8994 273 drivers/gpio/gpio-wm8994.c wm8994_gpio->wm8994 = wm8994; wm8994 116 drivers/mfd/wm8994-core.c struct wm8994 *wm8994 = dev_get_drvdata(dev); wm8994 121 drivers/mfd/wm8994-core.c switch (wm8994->type) { wm8994 124 drivers/mfd/wm8994-core.c ret = wm8994_reg_read(wm8994, WM8958_MIC_DETECT_1); wm8994 138 drivers/mfd/wm8994-core.c if (!wm8994->ldo_ena_always_driven) wm8994 139 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_PULL_CONTROL_2, wm8994 146 drivers/mfd/wm8994-core.c wm8994_reg_write(wm8994, WM8994_SOFTWARE_RESET, wm8994 147 drivers/mfd/wm8994-core.c wm8994_reg_read(wm8994, WM8994_SOFTWARE_RESET)); wm8994 149 drivers/mfd/wm8994-core.c regcache_mark_dirty(wm8994->regmap); wm8994 154 drivers/mfd/wm8994-core.c ret = regcache_sync_region(wm8994->regmap, WM8994_GPIO_1, wm8994 160 drivers/mfd/wm8994-core.c ret = regcache_sync_region(wm8994->regmap, wm8994 166 drivers/mfd/wm8994-core.c regcache_cache_only(wm8994->regmap, true); wm8994 167 drivers/mfd/wm8994-core.c wm8994->suspended = true; wm8994 169 drivers/mfd/wm8994-core.c ret = regulator_bulk_disable(wm8994->num_supplies, wm8994 170 drivers/mfd/wm8994-core.c wm8994->supplies); wm8994 181 drivers/mfd/wm8994-core.c struct wm8994 *wm8994 = dev_get_drvdata(dev); wm8994 185 drivers/mfd/wm8994-core.c if (!wm8994->suspended) wm8994 188 drivers/mfd/wm8994-core.c ret = regulator_bulk_enable(wm8994->num_supplies, wm8994 189 drivers/mfd/wm8994-core.c wm8994->supplies); wm8994 195 drivers/mfd/wm8994-core.c regcache_cache_only(wm8994->regmap, false); wm8994 196 drivers/mfd/wm8994-core.c ret = regcache_sync(wm8994->regmap); wm8994 203 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_PULL_CONTROL_2, wm8994 207 drivers/mfd/wm8994-core.c wm8994->suspended = false; wm8994 212 drivers/mfd/wm8994-core.c regulator_bulk_disable(wm8994->num_supplies, wm8994->supplies); wm8994 263 drivers/mfd/wm8994-core.c static int wm8994_set_pdata_from_of(struct wm8994 *wm8994) wm8994 265 drivers/mfd/wm8994-core.c struct device_node *np = wm8994->dev->of_node; wm8994 266 drivers/mfd/wm8994-core.c struct wm8994_pdata *pdata = &wm8994->pdata; wm8994 275 drivers/mfd/wm8994-core.c if (wm8994->pdata.gpio_defaults[i] == 0) wm8994 306 drivers/mfd/wm8994-core.c static int wm8994_set_pdata_from_of(struct wm8994 *wm8994) wm8994 315 drivers/mfd/wm8994-core.c static int wm8994_device_init(struct wm8994 *wm8994, int irq) wm8994 324 drivers/mfd/wm8994-core.c if (dev_get_platdata(wm8994->dev)) { wm8994 325 drivers/mfd/wm8994-core.c pdata = dev_get_platdata(wm8994->dev); wm8994 326 drivers/mfd/wm8994-core.c wm8994->pdata = *pdata; wm8994 328 drivers/mfd/wm8994-core.c pdata = &wm8994->pdata; wm8994 330 drivers/mfd/wm8994-core.c ret = wm8994_set_pdata_from_of(wm8994); wm8994 334 drivers/mfd/wm8994-core.c dev_set_drvdata(wm8994->dev, wm8994); wm8994 337 drivers/mfd/wm8994-core.c ret = mfd_add_devices(wm8994->dev, 0, wm8994 342 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to add children: %d\n", ret); wm8994 346 drivers/mfd/wm8994-core.c switch (wm8994->type) { wm8994 348 drivers/mfd/wm8994-core.c wm8994->num_supplies = ARRAY_SIZE(wm1811_main_supplies); wm8994 351 drivers/mfd/wm8994-core.c wm8994->num_supplies = ARRAY_SIZE(wm8994_main_supplies); wm8994 354 drivers/mfd/wm8994-core.c wm8994->num_supplies = ARRAY_SIZE(wm8958_main_supplies); wm8994 361 drivers/mfd/wm8994-core.c wm8994->supplies = devm_kcalloc(wm8994->dev, wm8994 362 drivers/mfd/wm8994-core.c wm8994->num_supplies, wm8994 365 drivers/mfd/wm8994-core.c if (!wm8994->supplies) { wm8994 370 drivers/mfd/wm8994-core.c switch (wm8994->type) { wm8994 373 drivers/mfd/wm8994-core.c wm8994->supplies[i].supply = wm1811_main_supplies[i]; wm8994 377 drivers/mfd/wm8994-core.c wm8994->supplies[i].supply = wm8994_main_supplies[i]; wm8994 381 drivers/mfd/wm8994-core.c wm8994->supplies[i].supply = wm8958_main_supplies[i]; wm8994 393 drivers/mfd/wm8994-core.c ret = regulator_bulk_get(wm8994->dev, wm8994->num_supplies, wm8994 394 drivers/mfd/wm8994-core.c wm8994->supplies); wm8994 396 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to get supplies: %d\n", ret); wm8994 400 drivers/mfd/wm8994-core.c ret = regulator_bulk_enable(wm8994->num_supplies, wm8994->supplies); wm8994 402 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to enable supplies: %d\n", ret); wm8994 406 drivers/mfd/wm8994-core.c ret = wm8994_reg_read(wm8994, WM8994_SOFTWARE_RESET); wm8994 408 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to read ID register\n"); wm8994 414 drivers/mfd/wm8994-core.c if (wm8994->type != WM1811) wm8994 415 drivers/mfd/wm8994-core.c dev_warn(wm8994->dev, "Device registered as type %d\n", wm8994 416 drivers/mfd/wm8994-core.c wm8994->type); wm8994 417 drivers/mfd/wm8994-core.c wm8994->type = WM1811; wm8994 421 drivers/mfd/wm8994-core.c if (wm8994->type != WM8994) wm8994 422 drivers/mfd/wm8994-core.c dev_warn(wm8994->dev, "Device registered as type %d\n", wm8994 423 drivers/mfd/wm8994-core.c wm8994->type); wm8994 424 drivers/mfd/wm8994-core.c wm8994->type = WM8994; wm8994 428 drivers/mfd/wm8994-core.c if (wm8994->type != WM8958) wm8994 429 drivers/mfd/wm8994-core.c dev_warn(wm8994->dev, "Device registered as type %d\n", wm8994 430 drivers/mfd/wm8994-core.c wm8994->type); wm8994 431 drivers/mfd/wm8994-core.c wm8994->type = WM8958; wm8994 434 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Device is not a WM8994, ID is %x\n", wm8994 440 drivers/mfd/wm8994-core.c ret = wm8994_reg_read(wm8994, WM8994_CHIP_REVISION); wm8994 442 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to read revision register: %d\n", wm8994 446 drivers/mfd/wm8994-core.c wm8994->revision = ret & WM8994_CHIP_REV_MASK; wm8994 447 drivers/mfd/wm8994-core.c wm8994->cust_id = (ret & WM8994_CUST_ID_MASK) >> WM8994_CUST_ID_SHIFT; wm8994 449 drivers/mfd/wm8994-core.c switch (wm8994->type) { wm8994 451 drivers/mfd/wm8994-core.c switch (wm8994->revision) { wm8994 454 drivers/mfd/wm8994-core.c dev_warn(wm8994->dev, wm8994 456 drivers/mfd/wm8994-core.c 'A' + wm8994->revision); wm8994 468 drivers/mfd/wm8994-core.c switch (wm8994->revision) { wm8994 480 drivers/mfd/wm8994-core.c if (wm8994->revision > 1) wm8994 481 drivers/mfd/wm8994-core.c wm8994->revision++; wm8994 491 drivers/mfd/wm8994-core.c dev_info(wm8994->dev, "%s revision %c CUST_ID %02x\n", devname, wm8994 492 drivers/mfd/wm8994-core.c 'A' + wm8994->revision, wm8994->cust_id); wm8994 494 drivers/mfd/wm8994-core.c switch (wm8994->type) { wm8994 505 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Unknown device type %d\n", wm8994->type); wm8994 510 drivers/mfd/wm8994-core.c ret = regmap_reinit_cache(wm8994->regmap, regmap_config); wm8994 512 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to reinit register cache: %d\n", wm8994 521 drivers/mfd/wm8994-core.c ret = wm8994_reg_write(wm8994, WM8994_SOFTWARE_RESET, wm8994 522 drivers/mfd/wm8994-core.c wm8994_reg_read(wm8994, WM8994_SOFTWARE_RESET)); wm8994 524 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to reset device: %d\n", ret); wm8994 529 drivers/mfd/wm8994-core.c ret = regmap_register_patch(wm8994->regmap, regmap_patch, wm8994 532 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to register patch: %d\n", wm8994 538 drivers/mfd/wm8994-core.c wm8994->irq_base = pdata->irq_base; wm8994 539 drivers/mfd/wm8994-core.c wm8994->gpio_base = pdata->gpio_base; wm8994 544 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_GPIO_1 + i, wm8994 549 drivers/mfd/wm8994-core.c wm8994->ldo_ena_always_driven = pdata->ldo_ena_always_driven; wm8994 557 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_PULL_CONTROL_2, wm8994 570 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_LDO_1 + i, wm8994 573 drivers/mfd/wm8994-core.c wm8994_set_bits(wm8994, WM8994_LDO_1 + i, wm8994 577 drivers/mfd/wm8994-core.c wm8994_irq_init(wm8994); wm8994 579 drivers/mfd/wm8994-core.c ret = mfd_add_devices(wm8994->dev, -1, wm8994 583 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to add children: %d\n", ret); wm8994 587 drivers/mfd/wm8994-core.c pm_runtime_enable(wm8994->dev); wm8994 588 drivers/mfd/wm8994-core.c pm_runtime_idle(wm8994->dev); wm8994 593 drivers/mfd/wm8994-core.c wm8994_irq_exit(wm8994); wm8994 595 drivers/mfd/wm8994-core.c regulator_bulk_disable(wm8994->num_supplies, wm8994 596 drivers/mfd/wm8994-core.c wm8994->supplies); wm8994 598 drivers/mfd/wm8994-core.c regulator_bulk_free(wm8994->num_supplies, wm8994->supplies); wm8994 600 drivers/mfd/wm8994-core.c mfd_remove_devices(wm8994->dev); wm8994 604 drivers/mfd/wm8994-core.c static void wm8994_device_exit(struct wm8994 *wm8994) wm8994 606 drivers/mfd/wm8994-core.c pm_runtime_disable(wm8994->dev); wm8994 607 drivers/mfd/wm8994-core.c wm8994_irq_exit(wm8994); wm8994 608 drivers/mfd/wm8994-core.c regulator_bulk_disable(wm8994->num_supplies, wm8994->supplies); wm8994 609 drivers/mfd/wm8994-core.c regulator_bulk_free(wm8994->num_supplies, wm8994->supplies); wm8994 610 drivers/mfd/wm8994-core.c mfd_remove_devices(wm8994->dev); wm8994 625 drivers/mfd/wm8994-core.c struct wm8994 *wm8994; wm8994 628 drivers/mfd/wm8994-core.c wm8994 = devm_kzalloc(&i2c->dev, sizeof(struct wm8994), GFP_KERNEL); wm8994 629 drivers/mfd/wm8994-core.c if (wm8994 == NULL) wm8994 632 drivers/mfd/wm8994-core.c i2c_set_clientdata(i2c, wm8994); wm8994 633 drivers/mfd/wm8994-core.c wm8994->dev = &i2c->dev; wm8994 634 drivers/mfd/wm8994-core.c wm8994->irq = i2c->irq; wm8994 639 drivers/mfd/wm8994-core.c wm8994->type = (enum wm8994_type)of_id->data; wm8994 641 drivers/mfd/wm8994-core.c wm8994->type = id->driver_data; wm8994 644 drivers/mfd/wm8994-core.c wm8994->regmap = devm_regmap_init_i2c(i2c, &wm8994_base_regmap_config); wm8994 645 drivers/mfd/wm8994-core.c if (IS_ERR(wm8994->regmap)) { wm8994 646 drivers/mfd/wm8994-core.c ret = PTR_ERR(wm8994->regmap); wm8994 647 drivers/mfd/wm8994-core.c dev_err(wm8994->dev, "Failed to allocate register map: %d\n", wm8994 652 drivers/mfd/wm8994-core.c return wm8994_device_init(wm8994, i2c->irq); wm8994 657 drivers/mfd/wm8994-core.c struct wm8994 *wm8994 = i2c_get_clientdata(i2c); wm8994 659 drivers/mfd/wm8994-core.c wm8994_device_exit(wm8994); wm8994 154 drivers/mfd/wm8994-irq.c struct wm8994 *wm8994 = data; wm8994 156 drivers/mfd/wm8994-irq.c while (gpio_get_value_cansleep(wm8994->pdata.irq_gpio)) wm8994 157 drivers/mfd/wm8994-irq.c handle_nested_irq(irq_create_mapping(wm8994->edge_irq, 0)); wm8994 165 drivers/mfd/wm8994-irq.c struct wm8994 *wm8994 = h->host_data; wm8994 167 drivers/mfd/wm8994-irq.c irq_set_chip_data(virq, wm8994); wm8994 180 drivers/mfd/wm8994-irq.c int wm8994_irq_init(struct wm8994 *wm8994) wm8994 184 drivers/mfd/wm8994-irq.c struct wm8994_pdata *pdata = &wm8994->pdata; wm8994 186 drivers/mfd/wm8994-irq.c if (!wm8994->irq) { wm8994 187 drivers/mfd/wm8994-irq.c dev_warn(wm8994->dev, wm8994 189 drivers/mfd/wm8994-irq.c wm8994->irq_base = 0; wm8994 200 drivers/mfd/wm8994-irq.c if (gpio_to_irq(pdata->irq_gpio) != wm8994->irq) { wm8994 201 drivers/mfd/wm8994-irq.c dev_warn(wm8994->dev, "IRQ %d is not GPIO %d (%d)\n", wm8994 202 drivers/mfd/wm8994-irq.c wm8994->irq, pdata->irq_gpio, wm8994 204 drivers/mfd/wm8994-irq.c wm8994->irq = gpio_to_irq(pdata->irq_gpio); wm8994 207 drivers/mfd/wm8994-irq.c ret = devm_gpio_request_one(wm8994->dev, pdata->irq_gpio, wm8994 211 drivers/mfd/wm8994-irq.c dev_err(wm8994->dev, "Failed to get IRQ GPIO: %d\n", wm8994 216 drivers/mfd/wm8994-irq.c wm8994->edge_irq = irq_domain_add_linear(NULL, 1, wm8994 218 drivers/mfd/wm8994-irq.c wm8994); wm8994 220 drivers/mfd/wm8994-irq.c ret = regmap_add_irq_chip(wm8994->regmap, wm8994 221 drivers/mfd/wm8994-irq.c irq_create_mapping(wm8994->edge_irq, wm8994 224 drivers/mfd/wm8994-irq.c wm8994->irq_base, &wm8994_irq_chip, wm8994 225 drivers/mfd/wm8994-irq.c &wm8994->irq_data); wm8994 227 drivers/mfd/wm8994-irq.c dev_err(wm8994->dev, "Failed to get IRQ: %d\n", wm8994 232 drivers/mfd/wm8994-irq.c ret = request_threaded_irq(wm8994->irq, wm8994 235 drivers/mfd/wm8994-irq.c "WM8994 edge", wm8994); wm8994 237 drivers/mfd/wm8994-irq.c ret = regmap_add_irq_chip(wm8994->regmap, wm8994->irq, wm8994 239 drivers/mfd/wm8994-irq.c wm8994->irq_base, &wm8994_irq_chip, wm8994 240 drivers/mfd/wm8994-irq.c &wm8994->irq_data); wm8994 244 drivers/mfd/wm8994-irq.c dev_err(wm8994->dev, "Failed to register IRQ chip: %d\n", ret); wm8994 249 drivers/mfd/wm8994-irq.c wm8994_reg_write(wm8994, WM8994_INTERRUPT_CONTROL, 0); wm8994 255 drivers/mfd/wm8994-irq.c void wm8994_irq_exit(struct wm8994 *wm8994) wm8994 257 drivers/mfd/wm8994-irq.c regmap_del_irq_chip(wm8994->irq, wm8994->irq_data); wm8994 1194 drivers/mfd/wm8994-regmap.c struct wm8994 *wm8994 = dev_get_drvdata(dev); wm8994 1198 drivers/mfd/wm8994-regmap.c if (wm8994->cust_id > 1 || wm8994->revision > 1) wm8994 26 drivers/regulator/wm8994-regulator.c struct wm8994 *wm8994; wm8994 49 drivers/regulator/wm8994-regulator.c switch (ldo->wm8994->type) { wm8994 122 drivers/regulator/wm8994-regulator.c struct wm8994 *wm8994 = dev_get_drvdata(pdev->dev.parent); wm8994 123 drivers/regulator/wm8994-regulator.c struct wm8994_pdata *pdata = dev_get_platdata(wm8994->dev); wm8994 136 drivers/regulator/wm8994-regulator.c ldo->wm8994 = wm8994; wm8994 138 drivers/regulator/wm8994-regulator.c ldo->supply.dev_name = dev_name(wm8994->dev); wm8994 140 drivers/regulator/wm8994-regulator.c config.dev = wm8994->dev; wm8994 142 drivers/regulator/wm8994-regulator.c config.regmap = wm8994->regmap; wm8994 158 drivers/regulator/wm8994-regulator.c if (!pdata || !pdata->ldo[id].init_data || wm8994->dev->of_node) { wm8994 159 drivers/regulator/wm8994-regulator.c dev_dbg(wm8994->dev, "Using default init data, supply %s %s\n", wm8994 180 drivers/regulator/wm8994-regulator.c dev_err(wm8994->dev, "Failed to register LDO%d: %d\n", wm8994 82 include/linux/mfd/wm8994/core.h static inline int wm8994_reg_read(struct wm8994 *wm8994, unsigned short reg) wm8994 87 include/linux/mfd/wm8994/core.h ret = regmap_read(wm8994->regmap, reg, &val); wm8994 95 include/linux/mfd/wm8994/core.h static inline int wm8994_reg_write(struct wm8994 *wm8994, unsigned short reg, wm8994 98 include/linux/mfd/wm8994/core.h return regmap_write(wm8994->regmap, reg, val); wm8994 101 include/linux/mfd/wm8994/core.h static inline int wm8994_bulk_read(struct wm8994 *wm8994, unsigned short reg, wm8994 104 include/linux/mfd/wm8994/core.h return regmap_bulk_read(wm8994->regmap, reg, buf, count); wm8994 107 include/linux/mfd/wm8994/core.h static inline int wm8994_bulk_write(struct wm8994 *wm8994, unsigned short reg, wm8994 110 include/linux/mfd/wm8994/core.h return regmap_raw_write(wm8994->regmap, reg, buf, count * sizeof(u16)); wm8994 113 include/linux/mfd/wm8994/core.h static inline int wm8994_set_bits(struct wm8994 *wm8994, unsigned short reg, wm8994 116 include/linux/mfd/wm8994/core.h return regmap_update_bits(wm8994->regmap, reg, mask, val); wm8994 120 include/linux/mfd/wm8994/core.h static inline int wm8994_request_irq(struct wm8994 *wm8994, int irq, wm8994 124 include/linux/mfd/wm8994/core.h if (!wm8994->irq_data) wm8994 126 include/linux/mfd/wm8994/core.h return request_threaded_irq(regmap_irq_get_virq(wm8994->irq_data, irq), wm8994 130 include/linux/mfd/wm8994/core.h static inline void wm8994_free_irq(struct wm8994 *wm8994, int irq, void *data) wm8994 132 include/linux/mfd/wm8994/core.h if (!wm8994->irq_data) wm8994 134 include/linux/mfd/wm8994/core.h free_irq(regmap_irq_get_virq(wm8994->irq_data, irq), data); wm8994 137 include/linux/mfd/wm8994/core.h int wm8994_irq_init(struct wm8994 *wm8994); wm8994 138 include/linux/mfd/wm8994/core.h void wm8994_irq_exit(struct wm8994 *wm8994); wm8994 42 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 51 sound/soc/codecs/wm8958-dsp2.c if (wm8994->cur_fw == fw) wm8994 153 sound/soc/codecs/wm8958-dsp2.c wm8994_bulk_write(wm8994->wm8994, wm8994 174 sound/soc/codecs/wm8958-dsp2.c wm8994->cur_fw = fw; wm8994 194 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 195 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 203 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc) wm8994 204 sound/soc/codecs/wm8958-dsp2.c wm8958_dsp2_fw(component, "MBC", wm8994->mbc, false); wm8994 212 sound/soc/codecs/wm8958-dsp2.c = &control->pdata.mbc_cfgs[wm8994->mbc_cfg]; wm8994 238 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 239 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 242 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc_vss) wm8994 243 sound/soc/codecs/wm8958-dsp2.c wm8958_dsp2_fw(component, "MBC+VSS", wm8994->mbc_vss, false); wm8994 251 sound/soc/codecs/wm8958-dsp2.c = &control->pdata.mbc_cfgs[wm8994->mbc_cfg]; wm8994 260 sound/soc/codecs/wm8958-dsp2.c = &control->pdata.vss_cfgs[wm8994->vss_cfg]; wm8994 268 sound/soc/codecs/wm8958-dsp2.c = &control->pdata.vss_hpf_cfgs[wm8994->vss_hpf_cfg]; wm8994 280 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc_ena[path]) wm8994 282 sound/soc/codecs/wm8958-dsp2.c if (wm8994->hpf2_ena[path]) wm8994 284 sound/soc/codecs/wm8958-dsp2.c if (wm8994->hpf1_ena[path]) wm8994 286 sound/soc/codecs/wm8958-dsp2.c if (wm8994->vss_ena[path]) wm8994 299 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 300 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 303 sound/soc/codecs/wm8958-dsp2.c wm8958_dsp2_fw(component, "ENH_EQ", wm8994->enh_eq, false); wm8994 311 sound/soc/codecs/wm8958-dsp2.c = &control->pdata.enh_eq_cfgs[wm8994->enh_eq_cfg]; wm8994 330 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 353 sound/soc/codecs/wm8958-dsp2.c ena = wm8994->mbc_ena[path] || wm8994->vss_ena[path] || wm8994 354 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf1_ena[path] || wm8994->hpf2_ena[path] || wm8994 355 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_ena[path]; wm8994 362 sound/soc/codecs/wm8958-dsp2.c path, wm8994->dsp_active, start, pwr_reg, reg); wm8994 382 sound/soc/codecs/wm8958-dsp2.c if (wm8994->enh_eq_ena[path]) wm8994 384 sound/soc/codecs/wm8958-dsp2.c else if (wm8994->vss_ena[path] || wm8994->hpf1_ena[path] || wm8994 385 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf2_ena[path]) wm8994 387 sound/soc/codecs/wm8958-dsp2.c else if (wm8994->mbc_ena[path]) wm8994 390 sound/soc/codecs/wm8958-dsp2.c wm8994->dsp_active = path; wm8994 395 sound/soc/codecs/wm8958-dsp2.c if (!start && wm8994->dsp_active == path) { wm8994 409 sound/soc/codecs/wm8958-dsp2.c wm8994->dsp_active = -1; wm8994 438 sound/soc/codecs/wm8958-dsp2.c static int wm8958_dsp2_busy(struct wm8994_priv *wm8994, int aif) wm8994 442 sound/soc/codecs/wm8958-dsp2.c for (i = 0; i < ARRAY_SIZE(wm8994->mbc_ena); i++) { wm8994 445 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc_ena[i] || wm8994->vss_ena[i] || wm8994 446 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf1_ena[i] || wm8994->hpf2_ena[i]) wm8994 457 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 458 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 470 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_cfg = value; wm8994 479 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 481 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.enumerated.item[0] = wm8994->mbc_cfg; wm8994 501 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 503 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.integer.value[0] = wm8994->mbc_ena[mbc]; wm8994 513 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 515 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc_ena[mbc] == ucontrol->value.integer.value[0]) wm8994 521 sound/soc/codecs/wm8958-dsp2.c if (wm8958_dsp2_busy(wm8994, mbc)) { wm8994 526 sound/soc/codecs/wm8958-dsp2.c if (wm8994->enh_eq_ena[mbc]) wm8994 529 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_ena[mbc] = ucontrol->value.integer.value[0]; wm8994 531 sound/soc/codecs/wm8958-dsp2.c wm8958_dsp_apply(component, mbc, wm8994->mbc_ena[mbc]); wm8994 547 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 548 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 560 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_cfg = value; wm8994 569 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 571 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.enumerated.item[0] = wm8994->vss_cfg; wm8994 580 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 581 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 593 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_hpf_cfg = value; wm8994 602 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 604 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.enumerated.item[0] = wm8994->vss_hpf_cfg; wm8994 624 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 626 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.integer.value[0] = wm8994->vss_ena[vss]; wm8994 636 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 638 sound/soc/codecs/wm8958-dsp2.c if (wm8994->vss_ena[vss] == ucontrol->value.integer.value[0]) wm8994 644 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->mbc_vss) wm8994 647 sound/soc/codecs/wm8958-dsp2.c if (wm8958_dsp2_busy(wm8994, vss)) { wm8994 652 sound/soc/codecs/wm8958-dsp2.c if (wm8994->enh_eq_ena[vss]) wm8994 655 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_ena[vss] = ucontrol->value.integer.value[0]; wm8994 657 sound/soc/codecs/wm8958-dsp2.c wm8958_dsp_apply(component, vss, wm8994->vss_ena[vss]); wm8994 685 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 688 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.integer.value[0] = wm8994->hpf1_ena[hpf % 3]; wm8994 690 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.integer.value[0] = wm8994->hpf2_ena[hpf % 3]; wm8994 700 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 703 sound/soc/codecs/wm8958-dsp2.c if (wm8994->hpf1_ena[hpf % 3] == wm8994 707 sound/soc/codecs/wm8958-dsp2.c if (wm8994->hpf2_ena[hpf % 3] == wm8994 715 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->mbc_vss) wm8994 718 sound/soc/codecs/wm8958-dsp2.c if (wm8958_dsp2_busy(wm8994, hpf % 3)) { wm8994 723 sound/soc/codecs/wm8958-dsp2.c if (wm8994->enh_eq_ena[hpf % 3]) wm8994 727 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf1_ena[hpf % 3] = ucontrol->value.integer.value[0]; wm8994 729 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf2_ena[hpf % 3] = ucontrol->value.integer.value[0]; wm8994 747 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 748 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 760 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_cfg = value; wm8994 769 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 771 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.enumerated.item[0] = wm8994->enh_eq_cfg; wm8994 791 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 793 sound/soc/codecs/wm8958-dsp2.c ucontrol->value.integer.value[0] = wm8994->enh_eq_ena[eq]; wm8994 803 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 805 sound/soc/codecs/wm8958-dsp2.c if (wm8994->enh_eq_ena[eq] == ucontrol->value.integer.value[0]) wm8994 811 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->enh_eq) wm8994 814 sound/soc/codecs/wm8958-dsp2.c if (wm8958_dsp2_busy(wm8994, eq)) { wm8994 819 sound/soc/codecs/wm8958-dsp2.c if (wm8994->mbc_ena[eq] || wm8994->vss_ena[eq] || wm8994 820 sound/soc/codecs/wm8958-dsp2.c wm8994->hpf1_ena[eq] || wm8994->hpf2_ena[eq]) wm8994 823 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_ena[eq] = ucontrol->value.integer.value[0]; wm8994 864 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 867 sound/soc/codecs/wm8958-dsp2.c mutex_lock(&wm8994->fw_lock); wm8994 868 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq = fw; wm8994 869 sound/soc/codecs/wm8958-dsp2.c mutex_unlock(&wm8994->fw_lock); wm8994 876 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 879 sound/soc/codecs/wm8958-dsp2.c mutex_lock(&wm8994->fw_lock); wm8994 880 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_vss = fw; wm8994 881 sound/soc/codecs/wm8958-dsp2.c mutex_unlock(&wm8994->fw_lock); wm8994 888 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 891 sound/soc/codecs/wm8958-dsp2.c mutex_lock(&wm8994->fw_lock); wm8994 892 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc = fw; wm8994 893 sound/soc/codecs/wm8958-dsp2.c mutex_unlock(&wm8994->fw_lock); wm8994 899 sound/soc/codecs/wm8958-dsp2.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 900 sound/soc/codecs/wm8958-dsp2.c struct wm8994 *control = wm8994->wm8994; wm8994 904 sound/soc/codecs/wm8958-dsp2.c wm8994->dsp_active = -1; wm8994 927 sound/soc/codecs/wm8958-dsp2.c SOC_ENUM_EXT("MBC Mode", wm8994->mbc_enum, wm8994 932 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_texts = kmalloc_array(pdata->num_mbc_cfgs, wm8994 935 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->mbc_texts) wm8994 939 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_texts[i] = pdata->mbc_cfgs[i].name; wm8994 941 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_enum.items = pdata->num_mbc_cfgs; wm8994 942 sound/soc/codecs/wm8958-dsp2.c wm8994->mbc_enum.texts = wm8994->mbc_texts; wm8994 944 sound/soc/codecs/wm8958-dsp2.c ret = snd_soc_add_component_controls(wm8994->hubs.component, wm8994 947 sound/soc/codecs/wm8958-dsp2.c dev_err(wm8994->hubs.component->dev, wm8994 953 sound/soc/codecs/wm8958-dsp2.c SOC_ENUM_EXT("VSS Mode", wm8994->vss_enum, wm8994 958 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_texts = kmalloc_array(pdata->num_vss_cfgs, wm8994 961 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->vss_texts) wm8994 965 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_texts[i] = pdata->vss_cfgs[i].name; wm8994 967 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_enum.items = pdata->num_vss_cfgs; wm8994 968 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_enum.texts = wm8994->vss_texts; wm8994 970 sound/soc/codecs/wm8958-dsp2.c ret = snd_soc_add_component_controls(wm8994->hubs.component, wm8994 973 sound/soc/codecs/wm8958-dsp2.c dev_err(wm8994->hubs.component->dev, wm8994 979 sound/soc/codecs/wm8958-dsp2.c SOC_ENUM_EXT("VSS HPF Mode", wm8994->vss_hpf_enum, wm8994 985 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_hpf_texts = kmalloc_array(pdata->num_vss_hpf_cfgs, wm8994 988 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->vss_hpf_texts) wm8994 992 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_hpf_texts[i] = pdata->vss_hpf_cfgs[i].name; wm8994 994 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_hpf_enum.items = pdata->num_vss_hpf_cfgs; wm8994 995 sound/soc/codecs/wm8958-dsp2.c wm8994->vss_hpf_enum.texts = wm8994->vss_hpf_texts; wm8994 997 sound/soc/codecs/wm8958-dsp2.c ret = snd_soc_add_component_controls(wm8994->hubs.component, wm8994 1000 sound/soc/codecs/wm8958-dsp2.c dev_err(wm8994->hubs.component->dev, wm8994 1007 sound/soc/codecs/wm8958-dsp2.c SOC_ENUM_EXT("Enhanced EQ Mode", wm8994->enh_eq_enum, wm8994 1013 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_texts = kmalloc_array(pdata->num_enh_eq_cfgs, wm8994 1016 sound/soc/codecs/wm8958-dsp2.c if (!wm8994->enh_eq_texts) wm8994 1020 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_texts[i] = pdata->enh_eq_cfgs[i].name; wm8994 1022 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_enum.items = pdata->num_enh_eq_cfgs; wm8994 1023 sound/soc/codecs/wm8958-dsp2.c wm8994->enh_eq_enum.texts = wm8994->enh_eq_texts; wm8994 1025 sound/soc/codecs/wm8958-dsp2.c ret = snd_soc_add_component_controls(wm8994->hubs.component, wm8994 1028 sound/soc/codecs/wm8958-dsp2.c dev_err(wm8994->hubs.component->dev, wm8994 107 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 108 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 114 sound/soc/codecs/wm8994.c idle = !wm8994->jack_mic; wm8994 118 sound/soc/codecs/wm8994.c sysclk = wm8994->aifclk[1]; wm8994 120 sound/soc/codecs/wm8994.c sysclk = wm8994->aifclk[0]; wm8994 125 sound/soc/codecs/wm8994.c } else if (wm8994->jackdet) { wm8994 158 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 168 sound/soc/codecs/wm8994.c switch (wm8994->sysclk[aif]) { wm8994 170 sound/soc/codecs/wm8994.c rate = wm8994->mclk[0]; wm8994 175 sound/soc/codecs/wm8994.c rate = wm8994->mclk[1]; wm8994 180 sound/soc/codecs/wm8994.c rate = wm8994->fll[0].out; wm8994 185 sound/soc/codecs/wm8994.c rate = wm8994->fll[1].out; wm8994 200 sound/soc/codecs/wm8994.c wm8994->aifclk[aif] = rate; wm8994 212 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 226 sound/soc/codecs/wm8994.c if (wm8994->aifclk[0] == wm8994->aifclk[1]) { wm8994 231 sound/soc/codecs/wm8994.c if (wm8994->aifclk[0] < wm8994->aifclk[1]) wm8994 320 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 321 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 324 sound/soc/codecs/wm8994.c int cfg = wm8994->drc_cfg[drc]; wm8994 357 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 358 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 369 sound/soc/codecs/wm8994.c wm8994->drc_cfg[drc] = value; wm8994 380 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 385 sound/soc/codecs/wm8994.c ucontrol->value.enumerated.item[0] = wm8994->drc_cfg[drc]; wm8994 392 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 393 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 398 sound/soc/codecs/wm8994.c if (!pdata || !wm8994->num_retune_mobile_texts) wm8994 415 sound/soc/codecs/wm8994.c cfg = wm8994->retune_mobile_cfg[block]; wm8994 420 sound/soc/codecs/wm8994.c wm8994->retune_mobile_texts[cfg]) == 0 && wm8994 422 sound/soc/codecs/wm8994.c - wm8994->dac_rates[iface]) < best_val) { wm8994 425 sound/soc/codecs/wm8994.c - wm8994->dac_rates[iface]); wm8994 433 sound/soc/codecs/wm8994.c wm8994->dac_rates[iface]); wm8994 464 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 465 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 476 sound/soc/codecs/wm8994.c wm8994->retune_mobile_cfg[block] = value; wm8994 487 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 493 sound/soc/codecs/wm8994.c ucontrol->value.enumerated.item[0] = wm8994->retune_mobile_cfg[block]; wm8994 746 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 748 sound/soc/codecs/wm8994.c if (!wm8994->jackdet || !wm8994->micdet[0].jack) wm8994 751 sound/soc/codecs/wm8994.c if (wm8994->active_refcount) wm8994 754 sound/soc/codecs/wm8994.c if (mode == wm8994->jackdet_mode) wm8994 757 sound/soc/codecs/wm8994.c wm8994->jackdet_mode = mode; wm8994 769 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 771 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 773 sound/soc/codecs/wm8994.c wm8994->active_refcount++; wm8994 776 sound/soc/codecs/wm8994.c wm8994->active_refcount); wm8994 781 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 786 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 789 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 791 sound/soc/codecs/wm8994.c wm8994->active_refcount--; wm8994 794 sound/soc/codecs/wm8994.c wm8994->active_refcount); wm8994 796 sound/soc/codecs/wm8994.c if (wm8994->active_refcount == 0) { wm8994 798 sound/soc/codecs/wm8994.c if (wm8994->jack_mic || wm8994->mic_detecting) wm8994 806 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 813 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 827 sound/soc/codecs/wm8994.c if (wm8994->jackdet && !wm8994->clk_has_run) { wm8994 829 sound/soc/codecs/wm8994.c &wm8994->jackdet_bootstrap, wm8994 831 sound/soc/codecs/wm8994.c wm8994->clk_has_run = true; wm8994 845 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 849 sound/soc/codecs/wm8994.c wm8994->vmid_refcount++; wm8994 852 sound/soc/codecs/wm8994.c wm8994->vmid_refcount); wm8994 854 sound/soc/codecs/wm8994.c if (wm8994->vmid_refcount == 1) { wm8994 861 sound/soc/codecs/wm8994.c switch (wm8994->vmid_mode) { wm8994 924 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 926 sound/soc/codecs/wm8994.c wm8994->vmid_refcount--; wm8994 929 sound/soc/codecs/wm8994.c wm8994->vmid_refcount); wm8994 931 sound/soc/codecs/wm8994.c if (wm8994->vmid_refcount == 0) { wm8994 932 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout1_se) wm8994 939 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout2_se) wm8994 1045 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 1046 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 1065 sound/soc/codecs/wm8994.c if (wm8994->channels[0] <= 2) wm8994 1228 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 1232 sound/soc/codecs/wm8994.c wm8994->aif1clk_enable = 1; wm8994 1235 sound/soc/codecs/wm8994.c wm8994->aif1clk_disable = 1; wm8994 1246 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 1250 sound/soc/codecs/wm8994.c wm8994->aif2clk_enable = 1; wm8994 1253 sound/soc/codecs/wm8994.c wm8994->aif2clk_disable = 1; wm8994 1264 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 1268 sound/soc/codecs/wm8994.c if (wm8994->aif1clk_enable) { wm8994 1274 sound/soc/codecs/wm8994.c wm8994->aif1clk_enable = 0; wm8994 1276 sound/soc/codecs/wm8994.c if (wm8994->aif2clk_enable) { wm8994 1282 sound/soc/codecs/wm8994.c wm8994->aif2clk_enable = 0; wm8994 1297 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 1301 sound/soc/codecs/wm8994.c if (wm8994->aif1clk_disable) { wm8994 1306 sound/soc/codecs/wm8994.c wm8994->aif1clk_disable = 0; wm8994 1308 sound/soc/codecs/wm8994.c if (wm8994->aif2clk_disable) { wm8994 1313 sound/soc/codecs/wm8994.c wm8994->aif2clk_disable = 0; wm8994 2051 sound/soc/codecs/wm8994.c static int wm8994_get_fll_config(struct wm8994 *control, struct fll_div *fll, wm8994 2137 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2138 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 2168 sound/soc/codecs/wm8994.c src = wm8994->fll[id].src; wm8994 2184 sound/soc/codecs/wm8994.c if (wm8994->fll[id].src == src && wm8994 2185 sound/soc/codecs/wm8994.c wm8994->fll[id].in == freq_in && wm8994->fll[id].out == freq_out) wm8994 2195 sound/soc/codecs/wm8994.c ret = wm8994_get_fll_config(control, &fll, wm8994->fll[id].in, wm8994 2196 sound/soc/codecs/wm8994.c wm8994->fll[id].out); wm8994 2219 sound/soc/codecs/wm8994.c if (wm8994->fll_byp && src == WM8994_FLL_SRC_BCLK && wm8994 2261 sound/soc/codecs/wm8994.c try_wait_for_completion(&wm8994->fll_locked[id]); wm8994 2293 sound/soc/codecs/wm8994.c if (wm8994->fll_locked_irq) { wm8994 2294 sound/soc/codecs/wm8994.c timeout = wait_for_completion_timeout(&wm8994->fll_locked[id], wm8994 2321 sound/soc/codecs/wm8994.c wm8994->fll[id].in = freq_in; wm8994 2322 sound/soc/codecs/wm8994.c wm8994->fll[id].out = freq_out; wm8994 2323 sound/soc/codecs/wm8994.c wm8994->fll[id].src = src; wm8994 2331 sound/soc/codecs/wm8994.c if (max(wm8994->aifclk[0], wm8994->aifclk[1]) < 50000) { wm8994 2334 sound/soc/codecs/wm8994.c wm8994->aifdiv[0] = snd_soc_component_read32(component, WM8994_AIF1_RATE) wm8994 2336 sound/soc/codecs/wm8994.c wm8994->aifdiv[1] = snd_soc_component_read32(component, WM8994_AIF2_RATE) wm8994 2343 sound/soc/codecs/wm8994.c } else if (wm8994->aifdiv[0]) { wm8994 2346 sound/soc/codecs/wm8994.c wm8994->aifdiv[0]); wm8994 2349 sound/soc/codecs/wm8994.c wm8994->aifdiv[1]); wm8994 2351 sound/soc/codecs/wm8994.c wm8994->aifdiv[0] = 0; wm8994 2352 sound/soc/codecs/wm8994.c wm8994->aifdiv[1] = 0; wm8994 2379 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2394 sound/soc/codecs/wm8994.c wm8994->sysclk[dai->id - 1] = WM8994_SYSCLK_MCLK1; wm8994 2395 sound/soc/codecs/wm8994.c wm8994->mclk[0] = freq; wm8994 2402 sound/soc/codecs/wm8994.c wm8994->sysclk[dai->id - 1] = WM8994_SYSCLK_MCLK2; wm8994 2403 sound/soc/codecs/wm8994.c wm8994->mclk[1] = freq; wm8994 2409 sound/soc/codecs/wm8994.c wm8994->sysclk[dai->id - 1] = WM8994_SYSCLK_FLL1; wm8994 2414 sound/soc/codecs/wm8994.c wm8994->sysclk[dai->id - 1] = WM8994_SYSCLK_FLL2; wm8994 2448 sound/soc/codecs/wm8994.c if (max(wm8994->aifclk[0], wm8994->aifclk[1]) < 50000) { wm8994 2451 sound/soc/codecs/wm8994.c wm8994->aifdiv[0] = snd_soc_component_read32(component, WM8994_AIF1_RATE) wm8994 2453 sound/soc/codecs/wm8994.c wm8994->aifdiv[1] = snd_soc_component_read32(component, WM8994_AIF2_RATE) wm8994 2460 sound/soc/codecs/wm8994.c } else if (wm8994->aifdiv[0]) { wm8994 2463 sound/soc/codecs/wm8994.c wm8994->aifdiv[0]); wm8994 2466 sound/soc/codecs/wm8994.c wm8994->aifdiv[1]); wm8994 2468 sound/soc/codecs/wm8994.c wm8994->aifdiv[0] = 0; wm8994 2469 sound/soc/codecs/wm8994.c wm8994->aifdiv[1] = 0; wm8994 2478 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2479 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 2551 sound/soc/codecs/wm8994.c wm8994->cur_fw = NULL; wm8994 2560 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2567 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout1_se) { wm8994 2573 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout2_se) { wm8994 2582 sound/soc/codecs/wm8994.c wm8994->vmid_mode = mode; wm8994 2590 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout1_se) { wm8994 2596 sound/soc/codecs/wm8994.c if (wm8994->hubs.lineout2_se) { wm8994 2603 sound/soc/codecs/wm8994.c wm8994->vmid_mode = mode; wm8994 2619 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2620 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 2775 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2776 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 2799 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[0]) { wm8994 2812 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[1]) { wm8994 2844 sound/soc/codecs/wm8994.c wm8994->channels[id] = params_channels(params); wm8994 2846 sound/soc/codecs/wm8994.c wm8994->channels[id] > pdata->max_channels_clocked[id]) { wm8994 2848 sound/soc/codecs/wm8994.c pdata->max_channels_clocked[id], wm8994->channels[id]); wm8994 2849 sound/soc/codecs/wm8994.c wm8994->channels[id] = pdata->max_channels_clocked[id]; wm8994 2852 sound/soc/codecs/wm8994.c switch (wm8994->channels[id]) { wm8994 2872 sound/soc/codecs/wm8994.c dai->id, wm8994->aifclk[id], bclk_rate); wm8994 2874 sound/soc/codecs/wm8994.c if (wm8994->channels[id] == 1 && wm8994 2878 sound/soc/codecs/wm8994.c if (wm8994->aifclk[id] == 0) { wm8994 2886 sound/soc/codecs/wm8994.c - wm8994->aifclk[id]); wm8994 2889 sound/soc/codecs/wm8994.c - wm8994->aifclk[id]); wm8994 2906 sound/soc/codecs/wm8994.c cur_val = (wm8994->aifclk[id] * 10 / bclk_divs[i]) - bclk_rate; wm8994 2911 sound/soc/codecs/wm8994.c bclk_rate = wm8994->aifclk[id] * 10 / bclk_divs[best]; wm8994 2936 sound/soc/codecs/wm8994.c wm8994->dac_rates[0] = params_rate(params); wm8994 2941 sound/soc/codecs/wm8994.c wm8994->dac_rates[1] = params_rate(params); wm8994 2955 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 2956 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3159 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3162 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll); i++) { wm8994 3163 sound/soc/codecs/wm8994.c memcpy(&wm8994->fll_suspend[i], &wm8994->fll[i], wm8994 3178 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3181 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll); i++) { wm8994 3182 sound/soc/codecs/wm8994.c if (!wm8994->fll_suspend[i].out) wm8994 3186 sound/soc/codecs/wm8994.c wm8994->fll_suspend[i].src, wm8994 3187 sound/soc/codecs/wm8994.c wm8994->fll_suspend[i].in, wm8994 3188 sound/soc/codecs/wm8994.c wm8994->fll_suspend[i].out); wm8994 3201 sound/soc/codecs/wm8994.c static void wm8994_handle_retune_mobile_pdata(struct wm8994_priv *wm8994) wm8994 3203 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3204 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3208 sound/soc/codecs/wm8994.c wm8994->retune_mobile_enum, wm8994 3212 sound/soc/codecs/wm8994.c wm8994->retune_mobile_enum, wm8994 3216 sound/soc/codecs/wm8994.c wm8994->retune_mobile_enum, wm8994 3227 sound/soc/codecs/wm8994.c wm8994->num_retune_mobile_texts = 0; wm8994 3228 sound/soc/codecs/wm8994.c wm8994->retune_mobile_texts = NULL; wm8994 3230 sound/soc/codecs/wm8994.c for (j = 0; j < wm8994->num_retune_mobile_texts; j++) { wm8994 3232 sound/soc/codecs/wm8994.c wm8994->retune_mobile_texts[j]) == 0) wm8994 3236 sound/soc/codecs/wm8994.c if (j != wm8994->num_retune_mobile_texts) wm8994 3240 sound/soc/codecs/wm8994.c t = krealloc(wm8994->retune_mobile_texts, wm8994 3242 sound/soc/codecs/wm8994.c (wm8994->num_retune_mobile_texts + 1), wm8994 3248 sound/soc/codecs/wm8994.c t[wm8994->num_retune_mobile_texts] = wm8994 3252 sound/soc/codecs/wm8994.c wm8994->num_retune_mobile_texts++; wm8994 3253 sound/soc/codecs/wm8994.c wm8994->retune_mobile_texts = t; wm8994 3257 sound/soc/codecs/wm8994.c wm8994->num_retune_mobile_texts); wm8994 3259 sound/soc/codecs/wm8994.c wm8994->retune_mobile_enum.items = wm8994->num_retune_mobile_texts; wm8994 3260 sound/soc/codecs/wm8994.c wm8994->retune_mobile_enum.texts = wm8994->retune_mobile_texts; wm8994 3262 sound/soc/codecs/wm8994.c ret = snd_soc_add_component_controls(wm8994->hubs.component, controls, wm8994 3265 sound/soc/codecs/wm8994.c dev_err(wm8994->hubs.component->dev, wm8994 3269 sound/soc/codecs/wm8994.c static void wm8994_handle_pdata(struct wm8994_priv *wm8994) wm8994 3271 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3272 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3294 sound/soc/codecs/wm8994.c SOC_ENUM_EXT("AIF1DRC1 Mode", wm8994->drc_enum, wm8994 3296 sound/soc/codecs/wm8994.c SOC_ENUM_EXT("AIF1DRC2 Mode", wm8994->drc_enum, wm8994 3298 sound/soc/codecs/wm8994.c SOC_ENUM_EXT("AIF2DRC Mode", wm8994->drc_enum, wm8994 3303 sound/soc/codecs/wm8994.c wm8994->drc_texts = devm_kcalloc(wm8994->hubs.component->dev, wm8994 3305 sound/soc/codecs/wm8994.c if (!wm8994->drc_texts) wm8994 3309 sound/soc/codecs/wm8994.c wm8994->drc_texts[i] = pdata->drc_cfgs[i].name; wm8994 3311 sound/soc/codecs/wm8994.c wm8994->drc_enum.items = pdata->num_drc_cfgs; wm8994 3312 sound/soc/codecs/wm8994.c wm8994->drc_enum.texts = wm8994->drc_texts; wm8994 3314 sound/soc/codecs/wm8994.c ret = snd_soc_add_component_controls(wm8994->hubs.component, controls, wm8994 3319 sound/soc/codecs/wm8994.c ret = snd_soc_add_component_controls(wm8994->hubs.component, wm8994 3325 sound/soc/codecs/wm8994.c dev_err(wm8994->hubs.component->dev, wm8994 3333 sound/soc/codecs/wm8994.c wm8994_handle_retune_mobile_pdata(wm8994); wm8994 3335 sound/soc/codecs/wm8994.c snd_soc_add_component_controls(wm8994->hubs.component, wm8994_eq_controls, wm8994 3365 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3367 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3377 sound/soc/codecs/wm8994.c micdet = &wm8994->micdet[0]; wm8994 3384 sound/soc/codecs/wm8994.c micdet = &wm8994->micdet[1]; wm8994 3407 sound/soc/codecs/wm8994.c if (wm8994->micdet[0].jack || wm8994->micdet[1].jack) wm8994 3431 sound/soc/codecs/wm8994.c struct regmap *regmap = priv->wm8994->regmap; wm8994 3432 sound/soc/codecs/wm8994.c struct device *dev = priv->wm8994->dev; wm8994 3511 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3513 sound/soc/codecs/wm8994.c if (!wm8994->jackdet) wm8994 3520 sound/soc/codecs/wm8994.c if (wm8994->wm8994->pdata.jd_ext_cap) wm8994 3526 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3548 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, report, wm8994 3549 sound/soc/codecs/wm8994.c wm8994->btn_mask); wm8994 3554 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = container_of(work, wm8994 3557 sound/soc/codecs/wm8994.c struct device *dev = wm8994->wm8994->dev; wm8994 3559 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 3561 sound/soc/codecs/wm8994.c wm1811_micd_stop(wm8994->hubs.component); wm8994 3565 sound/soc/codecs/wm8994.c wm8994->jack_mic = false; wm8994 3566 sound/soc/codecs/wm8994.c wm8994->mic_detecting = true; wm8994 3568 sound/soc/codecs/wm8994.c wm8958_micd_set_rate(wm8994->hubs.component); wm8994 3570 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, 0, wm8994 3571 sound/soc/codecs/wm8994.c wm8994->btn_mask | wm8994 3574 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 3580 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3588 sound/soc/codecs/wm8994.c &wm8994->open_circuit_work, wm8994 3599 sound/soc/codecs/wm8994.c wm8994->mic_detecting = false; wm8994 3600 sound/soc/codecs/wm8994.c wm8994->jack_mic = true; wm8994 3604 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, SND_JACK_HEADSET, wm8994 3611 sound/soc/codecs/wm8994.c wm8994->mic_detecting = false; wm8994 3618 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, SND_JACK_HEADPHONE, wm8994 3626 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = container_of(work, struct wm8994_priv, wm8994 3628 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3629 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3640 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 3645 sound/soc/codecs/wm8994.c if (wm8994->micd_cb) { wm8994 3646 sound/soc/codecs/wm8994.c wm8994->micd_cb(wm8994->micd_cb_data); wm8994 3652 sound/soc/codecs/wm8994.c wm8994->mic_detecting = true; wm8994 3659 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 3666 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = data; wm8994 3667 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3668 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3675 sound/soc/codecs/wm8994.c cancel_delayed_work_sync(&wm8994->mic_complete_work); wm8994 3677 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 3682 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 3705 sound/soc/codecs/wm8994.c &wm8994->mic_work, wm8994 3710 sound/soc/codecs/wm8994.c cancel_delayed_work_sync(&wm8994->mic_work); wm8994 3719 sound/soc/codecs/wm8994.c wm8994->mic_detecting = false; wm8994 3720 sound/soc/codecs/wm8994.c wm8994->jack_mic = false; wm8994 3726 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 3733 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, wm8994 3736 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, 0, wm8994 3738 sound/soc/codecs/wm8994.c wm8994->btn_mask); wm8994 3742 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, 0, 0); wm8994 3750 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = container_of(work, wm8994 3753 sound/soc/codecs/wm8994.c wm1811_jackdet_irq(0, wm8994); wm8994 3777 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 3778 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 3793 sound/soc/codecs/wm8994.c wm8994->micdet[0].jack = jack; wm8994 3796 sound/soc/codecs/wm8994.c wm8994->micd_cb = det_cb; wm8994 3797 sound/soc/codecs/wm8994.c wm8994->micd_cb_data = det_cb_data; wm8994 3799 sound/soc/codecs/wm8994.c wm8994->mic_detecting = true; wm8994 3800 sound/soc/codecs/wm8994.c wm8994->jack_mic = false; wm8994 3804 sound/soc/codecs/wm8994.c wm8994->mic_id_cb = id_cb; wm8994 3805 sound/soc/codecs/wm8994.c wm8994->mic_id_cb_data = id_cb_data; wm8994 3807 sound/soc/codecs/wm8994.c wm8994->mic_id_cb = wm8958_mic_id; wm8994 3808 sound/soc/codecs/wm8994.c wm8994->mic_id_cb_data = component; wm8994 3819 sound/soc/codecs/wm8994.c wm8994->btn_mask = SND_JACK_BTN_0 | SND_JACK_BTN_1 | wm8994 3832 sound/soc/codecs/wm8994.c if (wm8994->jackdet) { wm8994 3863 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = container_of(work, wm8994 3866 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3870 sound/soc/codecs/wm8994.c mutex_lock(&wm8994->accdet_lock); wm8994 3872 sound/soc/codecs/wm8994.c wm8994->mic_id_cb(wm8994->mic_id_cb_data, wm8994->mic_status); wm8994 3874 sound/soc/codecs/wm8994.c mutex_unlock(&wm8994->accdet_lock); wm8994 3881 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = data; wm8994 3882 sound/soc/codecs/wm8994.c struct snd_soc_component *component = wm8994->hubs.component; wm8994 3893 sound/soc/codecs/wm8994.c cancel_delayed_work_sync(&wm8994->mic_complete_work); wm8994 3894 sound/soc/codecs/wm8994.c cancel_delayed_work_sync(&wm8994->open_circuit_work); wm8994 3931 sound/soc/codecs/wm8994.c if (wm8994->jackdet) { wm8994 3941 sound/soc/codecs/wm8994.c snd_soc_jack_report(wm8994->micdet[0].jack, 0, wm8994 3943 sound/soc/codecs/wm8994.c wm8994->btn_mask); wm8994 3944 sound/soc/codecs/wm8994.c wm8994->mic_detecting = true; wm8994 3948 sound/soc/codecs/wm8994.c wm8994->mic_status = reg; wm8994 3949 sound/soc/codecs/wm8994.c id_delay = wm8994->wm8994->pdata.mic_id_delay; wm8994 3951 sound/soc/codecs/wm8994.c if (wm8994->mic_detecting) wm8994 3953 sound/soc/codecs/wm8994.c &wm8994->mic_complete_work, wm8994 3993 sound/soc/codecs/wm8994.c struct wm8994 *control = dev_get_drvdata(component->dev->parent); wm8994 3994 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 4000 sound/soc/codecs/wm8994.c wm8994->hubs.component = component; wm8994 4002 sound/soc/codecs/wm8994.c mutex_init(&wm8994->accdet_lock); wm8994 4003 sound/soc/codecs/wm8994.c INIT_DELAYED_WORK(&wm8994->jackdet_bootstrap, wm8994 4005 sound/soc/codecs/wm8994.c INIT_DELAYED_WORK(&wm8994->open_circuit_work, wm8994 4010 sound/soc/codecs/wm8994.c INIT_DELAYED_WORK(&wm8994->mic_work, wm8994_mic_work); wm8994 4013 sound/soc/codecs/wm8994.c INIT_DELAYED_WORK(&wm8994->mic_work, wm1811_mic_work); wm8994 4019 sound/soc/codecs/wm8994.c INIT_DELAYED_WORK(&wm8994->mic_complete_work, wm8958_mic_work); wm8994 4021 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll_locked); i++) wm8994 4022 sound/soc/codecs/wm8994.c init_completion(&wm8994->fll_locked[i]); wm8994 4024 sound/soc/codecs/wm8994.c wm8994->micdet_irq = control->pdata.micdet_irq; wm8994 4040 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_codes_l = -5; wm8994 4041 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_codes_r = -5; wm8994 4042 sound/soc/codecs/wm8994.c wm8994->hubs.hp_startup_mode = 1; wm8994 4043 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_readback_mode = 1; wm8994 4044 sound/soc/codecs/wm8994.c wm8994->hubs.series_startup = 1; wm8994 4047 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_readback_mode = 2; wm8994 4053 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_readback_mode = 1; wm8994 4054 sound/soc/codecs/wm8994.c wm8994->hubs.hp_startup_mode = 1; wm8994 4060 sound/soc/codecs/wm8994.c wm8994->fll_byp = true; wm8994 4066 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_readback_mode = 2; wm8994 4067 sound/soc/codecs/wm8994.c wm8994->hubs.no_series_update = 1; wm8994 4068 sound/soc/codecs/wm8994.c wm8994->hubs.hp_startup_mode = 1; wm8994 4069 sound/soc/codecs/wm8994.c wm8994->hubs.no_cache_dac_hp_direct = true; wm8994 4070 sound/soc/codecs/wm8994.c wm8994->fll_byp = true; wm8994 4072 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_codes_l = -9; wm8994 4073 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_codes_r = -7; wm8994 4083 sound/soc/codecs/wm8994.c wm8994_request_irq(wm8994->wm8994, WM8994_IRQ_FIFOS_ERR, wm8994 4085 sound/soc/codecs/wm8994.c wm8994_request_irq(wm8994->wm8994, WM8994_IRQ_TEMP_WARN, wm8994 4087 sound/soc/codecs/wm8994.c wm8994_request_irq(wm8994->wm8994, WM8994_IRQ_TEMP_SHUT, wm8994 4092 sound/soc/codecs/wm8994.c if (wm8994->micdet_irq) wm8994 4093 sound/soc/codecs/wm8994.c ret = request_threaded_irq(wm8994->micdet_irq, NULL, wm8994 4098 sound/soc/codecs/wm8994.c wm8994); wm8994 4100 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4103 sound/soc/codecs/wm8994.c wm8994); wm8994 4111 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4114 sound/soc/codecs/wm8994.c wm8994); wm8994 4120 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4123 sound/soc/codecs/wm8994.c wm8994); wm8994 4129 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4132 sound/soc/codecs/wm8994.c wm8994); wm8994 4141 sound/soc/codecs/wm8994.c if (wm8994->micdet_irq) { wm8994 4142 sound/soc/codecs/wm8994.c ret = request_threaded_irq(wm8994->micdet_irq, NULL, wm8994 4147 sound/soc/codecs/wm8994.c wm8994); wm8994 4153 sound/soc/codecs/wm8994.c wm8994_request_irq(wm8994->wm8994, WM8994_IRQ_MIC1_DET, wm8994 4155 sound/soc/codecs/wm8994.c wm8994); wm8994 4162 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4165 sound/soc/codecs/wm8994.c wm8994); wm8994 4167 sound/soc/codecs/wm8994.c wm8994->jackdet = true; wm8994 4174 sound/soc/codecs/wm8994.c wm8994->fll_locked_irq = true; wm8994 4175 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll_locked); i++) { wm8994 4176 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, wm8994 4179 sound/soc/codecs/wm8994.c &wm8994->fll_locked[i]); wm8994 4181 sound/soc/codecs/wm8994.c wm8994->fll_locked_irq = false; wm8994 4197 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[0] = 1; wm8994 4200 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[0] = 0; wm8994 4209 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[1] = 1; wm8994 4212 sound/soc/codecs/wm8994.c wm8994->lrclk_shared[1] = 0; wm8994 4260 sound/soc/codecs/wm8994.c wm8994->hubs.check_class_w_digital = wm8994_check_class_w_digital; wm8994 4263 sound/soc/codecs/wm8994.c wm8994_handle_pdata(wm8994); wm8994 4332 sound/soc/codecs/wm8994.c ret = wm8994_request_irq(wm8994->wm8994, WM8994_IRQ_DCS_DONE, wm8994 4334 sound/soc/codecs/wm8994.c &wm8994->hubs); wm8994 4336 sound/soc/codecs/wm8994.c wm8994->hubs.dcs_done_irq = true; wm8994 4382 sound/soc/codecs/wm8994.c if (wm8994->jackdet) wm8994 4383 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_GPIO(6), wm8994); wm8994 4384 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC2_SHRT, wm8994); wm8994 4385 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC2_DET, wm8994); wm8994 4386 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC1_SHRT, wm8994); wm8994 4387 sound/soc/codecs/wm8994.c if (wm8994->micdet_irq) wm8994 4388 sound/soc/codecs/wm8994.c free_irq(wm8994->micdet_irq, wm8994); wm8994 4389 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll_locked); i++) wm8994 4390 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_FLL1_LOCK + i, wm8994 4391 sound/soc/codecs/wm8994.c &wm8994->fll_locked[i]); wm8994 4392 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_DCS_DONE, wm8994 4393 sound/soc/codecs/wm8994.c &wm8994->hubs); wm8994 4394 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_FIFOS_ERR, component); wm8994 4395 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_TEMP_SHUT, component); wm8994 4396 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_TEMP_WARN, component); wm8994 4403 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = snd_soc_component_get_drvdata(component); wm8994 4404 sound/soc/codecs/wm8994.c struct wm8994 *control = wm8994->wm8994; wm8994 4407 sound/soc/codecs/wm8994.c for (i = 0; i < ARRAY_SIZE(wm8994->fll_locked); i++) wm8994 4408 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_FLL1_LOCK + i, wm8994 4409 sound/soc/codecs/wm8994.c &wm8994->fll_locked[i]); wm8994 4411 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_DCS_DONE, wm8994 4412 sound/soc/codecs/wm8994.c &wm8994->hubs); wm8994 4413 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_FIFOS_ERR, component); wm8994 4414 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_TEMP_SHUT, component); wm8994 4415 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_TEMP_WARN, component); wm8994 4417 sound/soc/codecs/wm8994.c if (wm8994->jackdet) wm8994 4418 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_GPIO(6), wm8994); wm8994 4422 sound/soc/codecs/wm8994.c if (wm8994->micdet_irq) wm8994 4423 sound/soc/codecs/wm8994.c free_irq(wm8994->micdet_irq, wm8994); wm8994 4424 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC2_DET, wm8994 4425 sound/soc/codecs/wm8994.c wm8994); wm8994 4426 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC1_SHRT, wm8994 4427 sound/soc/codecs/wm8994.c wm8994); wm8994 4428 sound/soc/codecs/wm8994.c wm8994_free_irq(wm8994->wm8994, WM8994_IRQ_MIC1_DET, wm8994 4429 sound/soc/codecs/wm8994.c wm8994); wm8994 4434 sound/soc/codecs/wm8994.c if (wm8994->micdet_irq) wm8994 4435 sound/soc/codecs/wm8994.c free_irq(wm8994->micdet_irq, wm8994); wm8994 4438 sound/soc/codecs/wm8994.c release_firmware(wm8994->mbc); wm8994 4439 sound/soc/codecs/wm8994.c release_firmware(wm8994->mbc_vss); wm8994 4440 sound/soc/codecs/wm8994.c release_firmware(wm8994->enh_eq); wm8994 4441 sound/soc/codecs/wm8994.c kfree(wm8994->retune_mobile_texts); wm8994 4458 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994; wm8994 4460 sound/soc/codecs/wm8994.c wm8994 = devm_kzalloc(&pdev->dev, sizeof(struct wm8994_priv), wm8994 4462 sound/soc/codecs/wm8994.c if (wm8994 == NULL) wm8994 4464 sound/soc/codecs/wm8994.c platform_set_drvdata(pdev, wm8994); wm8994 4466 sound/soc/codecs/wm8994.c mutex_init(&wm8994->fw_lock); wm8994 4468 sound/soc/codecs/wm8994.c wm8994->wm8994 = dev_get_drvdata(pdev->dev.parent); wm8994 4487 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = dev_get_drvdata(dev); wm8994 4490 sound/soc/codecs/wm8994.c if (wm8994->jackdet && !wm8994->active_refcount) wm8994 4491 sound/soc/codecs/wm8994.c regmap_update_bits(wm8994->wm8994->regmap, WM8994_ANTIPOP_2, wm8994 4493 sound/soc/codecs/wm8994.c wm8994->jackdet_mode); wm8994 4500 sound/soc/codecs/wm8994.c struct wm8994_priv *wm8994 = dev_get_drvdata(dev); wm8994 4502 sound/soc/codecs/wm8994.c if (wm8994->jackdet && wm8994->jackdet_mode) wm8994 4503 sound/soc/codecs/wm8994.c regmap_update_bits(wm8994->wm8994->regmap, WM8994_ANTIPOP_2, wm8994 71 sound/soc/codecs/wm8994.h struct wm8994; wm8994 75 sound/soc/codecs/wm8994.h struct wm8994 *wm8994; wm8994 76 sound/soc/pxa/brownstone.c SND_SOC_DAILINK_DEFS(wm8994, wm8994 88 sound/soc/pxa/brownstone.c SND_SOC_DAILINK_REG(wm8994),