Lines Matching refs:max9768
18 #include <sound/max9768.h>
28 struct max9768 {
44 struct max9768 *max9768 = snd_soc_component_get_drvdata(c);
45 int val = gpio_get_value_cansleep(max9768->mute_gpio);
56 struct max9768 *max9768 = snd_soc_component_get_drvdata(c);
58 gpio_set_value_cansleep(max9768->mute_gpio, !ucontrol->value.integer.value[0]);
131 struct max9768 *max9768 = snd_soc_component_get_drvdata(component);
134 if (max9768->flags & MAX9768_FLAG_CLASSIC_PWM) {
135 ret = regmap_write(max9768->regmap, MAX9768_CTRL,
141 if (gpio_is_valid(max9768->mute_gpio)) {
172 struct max9768 *max9768;
176 max9768 = devm_kzalloc(&client->dev, sizeof(*max9768), GFP_KERNEL);
177 if (!max9768)
184 max9768->mute_gpio = err ?: pdata->mute_gpio;
189 max9768->shdn_gpio = err ?: pdata->shdn_gpio;
191 max9768->flags = pdata->flags;
193 max9768->shdn_gpio = -EINVAL;
194 max9768->mute_gpio = -EINVAL;
197 i2c_set_clientdata(client, max9768);
199 max9768->regmap = devm_regmap_init_i2c(client, &max9768_i2c_regmap_config);
200 if (IS_ERR(max9768->regmap))
201 return PTR_ERR(max9768->regmap);
208 { "max9768", 0 },
215 .name = "max9768",