mfd: arizona: Rename thermal shutdown interrupt
Newer versions of the IP introduce short circuit protection which will also shutdown the speaker. Rename the interrupt and associated register bits associated with thermal events to better fit the function and avoid conflict with future interrupt additions. Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:

committed by
Lee Jones

parent
3d2108dae4
commit
c0fe2c5b3f
@@ -107,7 +107,7 @@ static int arizona_spk_ev(struct snd_soc_dapm_widget *w,
|
||||
break;
|
||||
case SND_SOC_DAPM_POST_PMU:
|
||||
val = snd_soc_read(codec, ARIZONA_INTERRUPT_RAW_STATUS_3);
|
||||
if (val & ARIZONA_SPK_SHUTDOWN_STS) {
|
||||
if (val & ARIZONA_SPK_OVERHEAT_STS) {
|
||||
dev_crit(arizona->dev,
|
||||
"Speaker not enabled due to temperature\n");
|
||||
return -EBUSY;
|
||||
@@ -159,7 +159,7 @@ static irqreturn_t arizona_thermal_warn(int irq, void *data)
|
||||
if (ret != 0) {
|
||||
dev_err(arizona->dev, "Failed to read thermal status: %d\n",
|
||||
ret);
|
||||
} else if (val & ARIZONA_SPK_SHUTDOWN_WARN_STS) {
|
||||
} else if (val & ARIZONA_SPK_OVERHEAT_WARN_STS) {
|
||||
dev_crit(arizona->dev, "Thermal warning\n");
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ static irqreturn_t arizona_thermal_shutdown(int irq, void *data)
|
||||
if (ret != 0) {
|
||||
dev_err(arizona->dev, "Failed to read thermal status: %d\n",
|
||||
ret);
|
||||
} else if (val & ARIZONA_SPK_SHUTDOWN_STS) {
|
||||
} else if (val & ARIZONA_SPK_OVERHEAT_STS) {
|
||||
dev_crit(arizona->dev, "Thermal shutdown\n");
|
||||
ret = regmap_update_bits(arizona->regmap,
|
||||
ARIZONA_OUTPUT_ENABLES_1,
|
||||
@@ -223,7 +223,7 @@ int arizona_init_spk(struct snd_soc_codec *codec)
|
||||
break;
|
||||
}
|
||||
|
||||
ret = arizona_request_irq(arizona, ARIZONA_IRQ_SPK_SHUTDOWN_WARN,
|
||||
ret = arizona_request_irq(arizona, ARIZONA_IRQ_SPK_OVERHEAT_WARN,
|
||||
"Thermal warning", arizona_thermal_warn,
|
||||
arizona);
|
||||
if (ret != 0)
|
||||
@@ -231,7 +231,7 @@ int arizona_init_spk(struct snd_soc_codec *codec)
|
||||
"Failed to get thermal warning IRQ: %d\n",
|
||||
ret);
|
||||
|
||||
ret = arizona_request_irq(arizona, ARIZONA_IRQ_SPK_SHUTDOWN,
|
||||
ret = arizona_request_irq(arizona, ARIZONA_IRQ_SPK_OVERHEAT,
|
||||
"Thermal shutdown", arizona_thermal_shutdown,
|
||||
arizona);
|
||||
if (ret != 0)
|
||||
|
Reference in New Issue
Block a user