diff options
-rw-r--r-- | drivers/mfd/fsl-imx25-tsadc.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/mfd/fsl-imx25-tsadc.c b/drivers/mfd/fsl-imx25-tsadc.c index 14189efd70d0..dbb85caaafed 100644 --- a/drivers/mfd/fsl-imx25-tsadc.c +++ b/drivers/mfd/fsl-imx25-tsadc.c | |||
@@ -179,6 +179,19 @@ static int mx25_tsadc_probe(struct platform_device *pdev) | |||
179 | return devm_of_platform_populate(dev); | 179 | return devm_of_platform_populate(dev); |
180 | } | 180 | } |
181 | 181 | ||
182 | static int mx25_tsadc_remove(struct platform_device *pdev) | ||
183 | { | ||
184 | struct mx25_tsadc *tsadc = platform_get_drvdata(pdev); | ||
185 | int irq = platform_get_irq(pdev, 0); | ||
186 | |||
187 | if (irq) { | ||
188 | irq_set_chained_handler_and_data(irq, NULL, NULL); | ||
189 | irq_domain_remove(tsadc->domain); | ||
190 | } | ||
191 | |||
192 | return 0; | ||
193 | } | ||
194 | |||
182 | static const struct of_device_id mx25_tsadc_ids[] = { | 195 | static const struct of_device_id mx25_tsadc_ids[] = { |
183 | { .compatible = "fsl,imx25-tsadc" }, | 196 | { .compatible = "fsl,imx25-tsadc" }, |
184 | { /* Sentinel */ } | 197 | { /* Sentinel */ } |
@@ -191,6 +204,7 @@ static struct platform_driver mx25_tsadc_driver = { | |||
191 | .of_match_table = of_match_ptr(mx25_tsadc_ids), | 204 | .of_match_table = of_match_ptr(mx25_tsadc_ids), |
192 | }, | 205 | }, |
193 | .probe = mx25_tsadc_probe, | 206 | .probe = mx25_tsadc_probe, |
207 | .remove = mx25_tsadc_remove, | ||
194 | }; | 208 | }; |
195 | module_platform_driver(mx25_tsadc_driver); | 209 | module_platform_driver(mx25_tsadc_driver); |
196 | 210 | ||