wm5100 120 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 132 sound/soc/codecs/wm5100.c if ((wm5100->sysclk % rate) == 0) { wm5100 136 sound/soc/codecs/wm5100.c if (!wm5100->sr_ref[i] && sr_free == -1) { wm5100 146 sound/soc/codecs/wm5100.c wm5100->sr_ref[i]++; wm5100 148 sound/soc/codecs/wm5100.c rate, i, wm5100->sr_ref[i]); wm5100 159 sound/soc/codecs/wm5100.c wm5100->sr_ref[sr_free]++; wm5100 169 sound/soc/codecs/wm5100.c rate, wm5100->sysclk, wm5100->asyncclk); wm5100 176 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 189 sound/soc/codecs/wm5100.c if (!wm5100->sr_ref[i]) wm5100 197 sound/soc/codecs/wm5100.c wm5100->sr_ref[i]--; wm5100 199 sound/soc/codecs/wm5100.c rate, wm5100->sr_ref[i]); wm5100 206 sound/soc/codecs/wm5100.c static int wm5100_reset(struct wm5100_priv *wm5100) wm5100 208 sound/soc/codecs/wm5100.c if (wm5100->pdata.reset) { wm5100 209 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.reset, 0); wm5100 210 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.reset, 1); wm5100 214 sound/soc/codecs/wm5100.c return regmap_write(wm5100->regmap, WM5100_SOFTWARE_RESET, 0); wm5100 736 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 740 sound/soc/codecs/wm5100.c if (wm5100->out_ena[0]) { wm5100 745 sound/soc/codecs/wm5100.c wm5100->out_ena[0] = false; wm5100 755 sound/soc/codecs/wm5100.c if (wm5100->out_ena[1]) { wm5100 760 sound/soc/codecs/wm5100.c wm5100->out_ena[1] = false; wm5100 776 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 780 sound/soc/codecs/wm5100.c wm5100->out_ena[0] = true; wm5100 783 sound/soc/codecs/wm5100.c wm5100->out_ena[0] = true; wm5100 792 sound/soc/codecs/wm5100.c static void wm5100_log_status3(struct wm5100_priv *wm5100, int val) wm5100 795 sound/soc/codecs/wm5100.c dev_crit(wm5100->dev, "Speaker shutdown warning\n"); wm5100 797 sound/soc/codecs/wm5100.c dev_crit(wm5100->dev, "Speaker shutdown\n"); wm5100 799 sound/soc/codecs/wm5100.c dev_crit(wm5100->dev, "SYSCLK underclocked\n"); wm5100 801 sound/soc/codecs/wm5100.c dev_crit(wm5100->dev, "ASYNCCLK underclocked\n"); wm5100 804 sound/soc/codecs/wm5100.c static void wm5100_log_status4(struct wm5100_priv *wm5100, int val) wm5100 807 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF3 configuration error\n"); wm5100 809 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF2 configuration error\n"); wm5100 811 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF1 configuration error\n"); wm5100 813 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Control interface error\n"); wm5100 815 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "ISRC2 underclocked\n"); wm5100 817 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "ISRC1 underclocked\n"); wm5100 819 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "FX underclocked\n"); wm5100 821 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF3 underclocked\n"); wm5100 823 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF2 underclocked\n"); wm5100 825 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "AIF1 underclocked\n"); wm5100 827 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "ASRC underclocked\n"); wm5100 829 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "DAC underclocked\n"); wm5100 831 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "ADC underclocked\n"); wm5100 833 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Mixer underclocked\n"); wm5100 841 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 848 sound/soc/codecs/wm5100.c wm5100_log_status3(wm5100, ret); wm5100 851 sound/soc/codecs/wm5100.c wm5100_log_status4(wm5100, ret); wm5100 1400 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 1401 sound/soc/codecs/wm5100.c bool async = wm5100->aif_async[dai->id]; wm5100 1425 sound/soc/codecs/wm5100.c aif_rate = wm5100->sysclk; wm5100 1431 sound/soc/codecs/wm5100.c aif_rate = wm5100->asyncclk; wm5100 1479 sound/soc/codecs/wm5100.c wm5100->aif_symmetric[dai->id]) wm5100 1509 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 1516 sound/soc/codecs/wm5100.c rate_store = &wm5100->sysclk; wm5100 1520 sound/soc/codecs/wm5100.c rate_store = &wm5100->asyncclk; wm5100 1543 sound/soc/codecs/wm5100.c wm5100->aif_async[clk_id - 1] = false; wm5100 1546 sound/soc/codecs/wm5100.c wm5100->aif_async[clk_id - 1] = true; wm5100 1758 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 1766 sound/soc/codecs/wm5100.c fll = &wm5100->fll[0]; wm5100 1771 sound/soc/codecs/wm5100.c fll = &wm5100->fll[1]; wm5100 1970 sound/soc/codecs/wm5100.c static void wm5100_set_detect_mode(struct wm5100_priv *wm5100, int the_mode) wm5100 1972 sound/soc/codecs/wm5100.c struct wm5100_jack_mode *mode = &wm5100->pdata.jack_modes[the_mode]; wm5100 1974 sound/soc/codecs/wm5100.c if (WARN_ON(the_mode >= ARRAY_SIZE(wm5100->pdata.jack_modes))) wm5100 1977 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.hp_pol, mode->hp_pol); wm5100 1978 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_ACCESSORY_DETECT_MODE_1, wm5100 1983 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_MISC_CONTROL, wm5100 1987 sound/soc/codecs/wm5100.c wm5100->jack_mode = the_mode; wm5100 1989 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Set microphone polarity to %d\n", wm5100 1990 sound/soc/codecs/wm5100.c wm5100->jack_mode); wm5100 1993 sound/soc/codecs/wm5100.c static void wm5100_report_headphone(struct wm5100_priv *wm5100) wm5100 1995 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Headphone detected\n"); wm5100 1996 sound/soc/codecs/wm5100.c wm5100->jack_detecting = false; wm5100 1997 sound/soc/codecs/wm5100.c snd_soc_jack_report(wm5100->jack, SND_JACK_HEADPHONE, wm5100 2001 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_MIC_DETECT_1, wm5100 2006 sound/soc/codecs/wm5100.c static void wm5100_micd_irq(struct wm5100_priv *wm5100) wm5100 2011 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_MIC_DETECT_3, &val); wm5100 2013 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Failed to read microphone status: %d\n", wm5100 2018 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Microphone event: %x\n", val); wm5100 2021 sound/soc/codecs/wm5100.c dev_warn(wm5100->dev, "Microphone detection state invalid\n"); wm5100 2027 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Jack removal detected\n"); wm5100 2028 sound/soc/codecs/wm5100.c wm5100->jack_mic = false; wm5100 2029 sound/soc/codecs/wm5100.c wm5100->jack_detecting = true; wm5100 2030 sound/soc/codecs/wm5100.c wm5100->jack_flips = 0; wm5100 2031 sound/soc/codecs/wm5100.c snd_soc_jack_report(wm5100->jack, 0, wm5100 2035 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_MIC_DETECT_1, wm5100 2046 sound/soc/codecs/wm5100.c if (wm5100->jack_detecting) { wm5100 2047 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Microphone detected\n"); wm5100 2048 sound/soc/codecs/wm5100.c wm5100->jack_mic = true; wm5100 2049 sound/soc/codecs/wm5100.c wm5100->jack_detecting = false; wm5100 2050 sound/soc/codecs/wm5100.c snd_soc_jack_report(wm5100->jack, wm5100 2056 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_MIC_DETECT_1, wm5100 2060 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Mic button up\n"); wm5100 2061 sound/soc/codecs/wm5100.c snd_soc_jack_report(wm5100->jack, 0, SND_JACK_BTN_0); wm5100 2073 sound/soc/codecs/wm5100.c if (wm5100->jack_detecting && (val & 0x3f8)) { wm5100 2074 sound/soc/codecs/wm5100.c wm5100->jack_flips++; wm5100 2076 sound/soc/codecs/wm5100.c if (wm5100->jack_flips > 1) wm5100 2077 sound/soc/codecs/wm5100.c wm5100_report_headphone(wm5100); wm5100 2079 sound/soc/codecs/wm5100.c wm5100_set_detect_mode(wm5100, !wm5100->jack_mode); wm5100 2088 sound/soc/codecs/wm5100.c if (wm5100->jack_mic) { wm5100 2089 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "Mic button detected\n"); wm5100 2090 sound/soc/codecs/wm5100.c snd_soc_jack_report(wm5100->jack, SND_JACK_BTN_0, wm5100 2092 sound/soc/codecs/wm5100.c } else if (wm5100->jack_detecting) { wm5100 2093 sound/soc/codecs/wm5100.c wm5100_report_headphone(wm5100); wm5100 2100 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 2104 sound/soc/codecs/wm5100.c wm5100->jack = jack; wm5100 2105 sound/soc/codecs/wm5100.c wm5100->jack_detecting = true; wm5100 2106 sound/soc/codecs/wm5100.c wm5100->jack_flips = 0; wm5100 2108 sound/soc/codecs/wm5100.c wm5100_set_detect_mode(wm5100, 0); wm5100 2144 sound/soc/codecs/wm5100.c wm5100->jack = NULL; wm5100 2153 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = data; wm5100 2158 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_INTERRUPT_STATUS_3, &irq_val); wm5100 2160 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Failed to read IRQ status 3: %d\n", wm5100 2165 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_INTERRUPT_STATUS_3_MASK, wm5100 2168 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Failed to read IRQ mask 3: %d\n", wm5100 2175 sound/soc/codecs/wm5100.c regmap_write(wm5100->regmap, WM5100_INTERRUPT_STATUS_3, irq_val); wm5100 2180 sound/soc/codecs/wm5100.c wm5100_log_status3(wm5100, irq_val); wm5100 2183 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "FLL1 locked\n"); wm5100 2184 sound/soc/codecs/wm5100.c complete(&wm5100->fll[0].lock); wm5100 2187 sound/soc/codecs/wm5100.c dev_dbg(wm5100->dev, "FLL2 locked\n"); wm5100 2188 sound/soc/codecs/wm5100.c complete(&wm5100->fll[1].lock); wm5100 2192 sound/soc/codecs/wm5100.c wm5100_micd_irq(wm5100); wm5100 2194 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_INTERRUPT_STATUS_4, &irq_val); wm5100 2196 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Failed to read IRQ status 4: %d\n", wm5100 2201 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_INTERRUPT_STATUS_4_MASK, wm5100 2204 sound/soc/codecs/wm5100.c dev_err(wm5100->dev, "Failed to read IRQ mask 4: %d\n", wm5100 2214 sound/soc/codecs/wm5100.c regmap_write(wm5100->regmap, WM5100_INTERRUPT_STATUS_4, irq_val); wm5100 2216 sound/soc/codecs/wm5100.c wm5100_log_status4(wm5100, irq_val); wm5100 2238 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = gpiochip_get_data(chip); wm5100 2240 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, WM5100_GPIO_CTRL_1 + offset, wm5100 2247 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = gpiochip_get_data(chip); wm5100 2252 sound/soc/codecs/wm5100.c ret = regmap_update_bits(wm5100->regmap, WM5100_GPIO_CTRL_1 + offset, wm5100 2263 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = gpiochip_get_data(chip); wm5100 2267 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_GPIO_CTRL_1 + offset, ®); wm5100 2276 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = gpiochip_get_data(chip); wm5100 2278 sound/soc/codecs/wm5100.c return regmap_update_bits(wm5100->regmap, WM5100_GPIO_CTRL_1 + offset, wm5100 2296 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = i2c_get_clientdata(i2c); wm5100 2299 sound/soc/codecs/wm5100.c wm5100->gpio_chip = wm5100_template_chip; wm5100 2300 sound/soc/codecs/wm5100.c wm5100->gpio_chip.ngpio = 6; wm5100 2301 sound/soc/codecs/wm5100.c wm5100->gpio_chip.parent = &i2c->dev; wm5100 2303 sound/soc/codecs/wm5100.c if (wm5100->pdata.gpio_base) wm5100 2304 sound/soc/codecs/wm5100.c wm5100->gpio_chip.base = wm5100->pdata.gpio_base; wm5100 2306 sound/soc/codecs/wm5100.c wm5100->gpio_chip.base = -1; wm5100 2308 sound/soc/codecs/wm5100.c ret = gpiochip_add_data(&wm5100->gpio_chip, wm5100); wm5100 2315 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = i2c_get_clientdata(i2c); wm5100 2317 sound/soc/codecs/wm5100.c gpiochip_remove(&wm5100->gpio_chip); wm5100 2333 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 2336 sound/soc/codecs/wm5100.c wm5100->component = component; wm5100 2352 sound/soc/codecs/wm5100.c if (wm5100->pdata.hp_pol) { wm5100 2353 sound/soc/codecs/wm5100.c ret = gpio_request_one(wm5100->pdata.hp_pol, wm5100 2357 sound/soc/codecs/wm5100.c wm5100->pdata.hp_pol, ret); wm5100 2371 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = snd_soc_component_get_drvdata(component); wm5100 2373 sound/soc/codecs/wm5100.c if (wm5100->pdata.hp_pol) { wm5100 2374 sound/soc/codecs/wm5100.c gpio_free(wm5100->pdata.hp_pol); wm5100 2418 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100; wm5100 2422 sound/soc/codecs/wm5100.c wm5100 = devm_kzalloc(&i2c->dev, sizeof(struct wm5100_priv), wm5100 2424 sound/soc/codecs/wm5100.c if (wm5100 == NULL) wm5100 2427 sound/soc/codecs/wm5100.c wm5100->dev = &i2c->dev; wm5100 2429 sound/soc/codecs/wm5100.c wm5100->regmap = devm_regmap_init_i2c(i2c, &wm5100_regmap); wm5100 2430 sound/soc/codecs/wm5100.c if (IS_ERR(wm5100->regmap)) { wm5100 2431 sound/soc/codecs/wm5100.c ret = PTR_ERR(wm5100->regmap); wm5100 2437 sound/soc/codecs/wm5100.c for (i = 0; i < ARRAY_SIZE(wm5100->fll); i++) wm5100 2438 sound/soc/codecs/wm5100.c init_completion(&wm5100->fll[i].lock); wm5100 2441 sound/soc/codecs/wm5100.c wm5100->pdata = *pdata; wm5100 2443 sound/soc/codecs/wm5100.c i2c_set_clientdata(i2c, wm5100); wm5100 2445 sound/soc/codecs/wm5100.c for (i = 0; i < ARRAY_SIZE(wm5100->core_supplies); i++) wm5100 2446 sound/soc/codecs/wm5100.c wm5100->core_supplies[i].supply = wm5100_core_supply_names[i]; wm5100 2449 sound/soc/codecs/wm5100.c ARRAY_SIZE(wm5100->core_supplies), wm5100 2450 sound/soc/codecs/wm5100.c wm5100->core_supplies); wm5100 2457 sound/soc/codecs/wm5100.c ret = regulator_bulk_enable(ARRAY_SIZE(wm5100->core_supplies), wm5100 2458 sound/soc/codecs/wm5100.c wm5100->core_supplies); wm5100 2465 sound/soc/codecs/wm5100.c if (wm5100->pdata.ldo_ena) { wm5100 2466 sound/soc/codecs/wm5100.c ret = gpio_request_one(wm5100->pdata.ldo_ena, wm5100 2470 sound/soc/codecs/wm5100.c wm5100->pdata.ldo_ena, ret); wm5100 2476 sound/soc/codecs/wm5100.c if (wm5100->pdata.reset) { wm5100 2477 sound/soc/codecs/wm5100.c ret = gpio_request_one(wm5100->pdata.reset, wm5100 2481 sound/soc/codecs/wm5100.c wm5100->pdata.reset, ret); wm5100 2486 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_SOFTWARE_RESET, ®); wm5100 2502 sound/soc/codecs/wm5100.c ret = regmap_read(wm5100->regmap, WM5100_DEVICE_REVISION, ®); wm5100 2507 sound/soc/codecs/wm5100.c wm5100->rev = reg & WM5100_DEVICE_REVISION_MASK; wm5100 2509 sound/soc/codecs/wm5100.c dev_info(&i2c->dev, "revision %c\n", wm5100->rev + 'A'); wm5100 2511 sound/soc/codecs/wm5100.c ret = wm5100_reset(wm5100); wm5100 2517 sound/soc/codecs/wm5100.c switch (wm5100->rev) { wm5100 2519 sound/soc/codecs/wm5100.c ret = regmap_register_patch(wm5100->regmap, wm5100 2535 sound/soc/codecs/wm5100.c for (i = 0; i < ARRAY_SIZE(wm5100->pdata.gpio_defaults); i++) { wm5100 2536 sound/soc/codecs/wm5100.c if (!wm5100->pdata.gpio_defaults[i]) wm5100 2539 sound/soc/codecs/wm5100.c regmap_write(wm5100->regmap, WM5100_GPIO_CTRL_1 + i, wm5100 2540 sound/soc/codecs/wm5100.c wm5100->pdata.gpio_defaults[i]); wm5100 2543 sound/soc/codecs/wm5100.c for (i = 0; i < ARRAY_SIZE(wm5100->pdata.in_mode); i++) { wm5100 2544 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, wm5100_mic_ctrl_reg[i], wm5100 2547 sound/soc/codecs/wm5100.c (wm5100->pdata.in_mode[i] << wm5100 2549 sound/soc/codecs/wm5100.c (wm5100->pdata.dmic_sup[i] << wm5100 2554 sound/soc/codecs/wm5100.c if (wm5100->pdata.irq_flags) wm5100 2555 sound/soc/codecs/wm5100.c irq_flags = wm5100->pdata.irq_flags; wm5100 2564 sound/soc/codecs/wm5100.c "wm5100", wm5100); wm5100 2568 sound/soc/codecs/wm5100.c wm5100); wm5100 2575 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, wm5100 2586 sound/soc/codecs/wm5100.c regmap_update_bits(wm5100->regmap, wm5100 2622 sound/soc/codecs/wm5100.c free_irq(i2c->irq, wm5100); wm5100 2624 sound/soc/codecs/wm5100.c if (wm5100->pdata.reset) { wm5100 2625 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.reset, 0); wm5100 2626 sound/soc/codecs/wm5100.c gpio_free(wm5100->pdata.reset); wm5100 2629 sound/soc/codecs/wm5100.c if (wm5100->pdata.ldo_ena) { wm5100 2630 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.ldo_ena, 0); wm5100 2631 sound/soc/codecs/wm5100.c gpio_free(wm5100->pdata.ldo_ena); wm5100 2634 sound/soc/codecs/wm5100.c regulator_bulk_disable(ARRAY_SIZE(wm5100->core_supplies), wm5100 2635 sound/soc/codecs/wm5100.c wm5100->core_supplies); wm5100 2642 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = i2c_get_clientdata(i2c); wm5100 2646 sound/soc/codecs/wm5100.c free_irq(i2c->irq, wm5100); wm5100 2648 sound/soc/codecs/wm5100.c if (wm5100->pdata.reset) { wm5100 2649 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.reset, 0); wm5100 2650 sound/soc/codecs/wm5100.c gpio_free(wm5100->pdata.reset); wm5100 2652 sound/soc/codecs/wm5100.c if (wm5100->pdata.ldo_ena) { wm5100 2653 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.ldo_ena, 0); wm5100 2654 sound/soc/codecs/wm5100.c gpio_free(wm5100->pdata.ldo_ena); wm5100 2663 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = dev_get_drvdata(dev); wm5100 2665 sound/soc/codecs/wm5100.c regcache_cache_only(wm5100->regmap, true); wm5100 2666 sound/soc/codecs/wm5100.c regcache_mark_dirty(wm5100->regmap); wm5100 2667 sound/soc/codecs/wm5100.c if (wm5100->pdata.ldo_ena) wm5100 2668 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.ldo_ena, 0); wm5100 2669 sound/soc/codecs/wm5100.c regulator_bulk_disable(ARRAY_SIZE(wm5100->core_supplies), wm5100 2670 sound/soc/codecs/wm5100.c wm5100->core_supplies); wm5100 2677 sound/soc/codecs/wm5100.c struct wm5100_priv *wm5100 = dev_get_drvdata(dev); wm5100 2680 sound/soc/codecs/wm5100.c ret = regulator_bulk_enable(ARRAY_SIZE(wm5100->core_supplies), wm5100 2681 sound/soc/codecs/wm5100.c wm5100->core_supplies); wm5100 2688 sound/soc/codecs/wm5100.c if (wm5100->pdata.ldo_ena) { wm5100 2689 sound/soc/codecs/wm5100.c gpio_set_value_cansleep(wm5100->pdata.ldo_ena, 1); wm5100 2693 sound/soc/codecs/wm5100.c regcache_cache_only(wm5100->regmap, false); wm5100 2694 sound/soc/codecs/wm5100.c regcache_sync(wm5100->regmap);