Skip to contentSkip to conversation

mfd: TPS65910: Make usable even if interrupt unused

PATCH Superseded Afzal Mohammed 3 participants 3 messages Dec 13, 2011

Subsystems (2)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mfd: TPS65910: Make usable even if interrupt unused

TPS65910 can be used even if interrupt is unused. Hence let probe succeed in case interrupt can't be configured and let Kernel only to complain about it

---
Hi Samuel,

I sent this yesterday, but did not reach LKML, so assumed you also may not have recieved it; resending.

Regards
Afzal

 drivers/mfd/tps65910.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)
drivers/mfd/tps65910.c +1 -4
index 6f5b8cf..2fa0178 100644
@@ -172,15 +172,12 @@ static int tps65910_i2c_probe(struct i2c_client *i2c,
 
 	tps65910_gpio_init(tps65910, pmic_plat_data->gpio_base);
 
-	ret = tps65910_irq_init(tps65910, init_data->irq, init_data);
-	if (ret < 0)
-		goto err;
+	tps65910_irq_init(tps65910, init_data->irq, init_data);
 
 	kfree(init_data);
 	return ret;
 
 err:
-	mfd_remove_devices(tps65910->dev);
 	kfree(tps65910);
 	kfree(init_data);
 	return ret;
Signature · 1 line
1.7.1
#1 lore raw

Is there any potential issue when calling free_irq on a non-requested irq? If it is, there should be a !irq check in tps65910_irq_exit or tps65910_i2c_remove.

/Marcus

2011/12/13 Afzal Mohammed <[email protected]>:

Quoted 48 lines

TPS65910 can be used even if interrupt is unused. Hence let probe succeed in case interrupt can't be configured and let Kernel only to complain about it

---
Hi Samuel,

I sent this yesterday, but did not reach LKML,
so assumed you also may not have recieved it;
resending.

Regards
Afzal

 drivers/mfd/tps65910.c |    5 +----

 1 files changed, 1 insertions(+), 4 deletions(-)
drivers/mfd/tps65910.c +1 -3
index 6f5b8cf..2fa0178 100644
@@ -172,15 +172,12 @@ static int tps65910_i2c_probe(struct i2c_client *i2c,
 
        tps65910_gpio_init(tps65910, pmic_plat_data->gpio_base);
 
-       ret = tps65910_irq_init(tps65910, init_data->irq, init_data);
-       if (ret < 0)
-               goto err;
+       tps65910_irq_init(tps65910, init_data->irq, init_data);
 
        kfree(init_data);
        return ret;
 

 err:
-       mfd_remove_devices(tps65910->dev);
       kfree(tps65910);
       kfree(init_data);
       return ret;
--
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

#2 lore raw

Hi Marcus

Quoted 3 lines · Marcus Folkesson

Is there any potential issue when calling free_irq on a non-requested irq? If it is, there should be a !irq check in tps65910_irq_exit or tps65910_i2c_remove.

Good catch. Mohamed, could you please fix that one up ?

Cheers,
Samuel.

Signature · 2 lines
Intel Open Source Technology Centre
http://oss.intel.com/