* [PATCH] OMAP: I2C: add devexit to the remove code
@ 2011-12-20 7:25 Shubhrajyoti D
[not found] ` <1324365959-4143-1-git-send-email-shubhrajyoti-l0cyMroinI0@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Shubhrajyoti D @ 2011-12-20 7:25 UTC (permalink / raw)
To: linux-omap; +Cc: linux-i2c, linux-arm-kernel, ben-linux, Shubhrajyoti D
The omap_i2c_remove function may not be needed after
device exit so the memory could be freed.
Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
---
drivers/i2c/busses/i2c-omap.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index fa23faa..2efdc6b 100644
--- a/drivers/i2c/busses/i2c-omap.c
+++ b/drivers/i2c/busses/i2c-omap.c
@@ -1111,8 +1111,7 @@ err_release_region:
return r;
}
-static int
-omap_i2c_remove(struct platform_device *pdev)
+static int __devexit omap_i2c_remove(struct platform_device *pdev)
{
struct omap_i2c_dev *dev = platform_get_drvdata(pdev);
struct resource *mem;
@@ -1161,7 +1160,7 @@ static struct dev_pm_ops omap_i2c_pm_ops = {
static struct platform_driver omap_i2c_driver = {
.probe = omap_i2c_probe,
- .remove = omap_i2c_remove,
+ .remove = __devexit_p(omap_i2c_remove),
.driver = {
.name = "omap_i2c",
.owner = THIS_MODULE,
--
1.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] OMAP: I2C: add devexit to the remove code
[not found] ` <1324365959-4143-1-git-send-email-shubhrajyoti-l0cyMroinI0@public.gmane.org>
@ 2012-01-06 16:28 ` Ben Dooks
[not found] ` <20120106162820.GB8441-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Ben Dooks @ 2012-01-06 16:28 UTC (permalink / raw)
To: Shubhrajyoti D
Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-i2c-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
ben-linux-elnMNo+KYs3YtjvyW6yDsg
On Tue, Dec 20, 2011 at 12:55:59PM +0530, Shubhrajyoti D wrote:
> The omap_i2c_remove function may not be needed after
> device exit so the memory could be freed.
>
> Signed-off-by: Shubhrajyoti D <shubhrajyoti-l0cyMroinI0@public.gmane.org>
Will add this later.
> ---
> drivers/i2c/busses/i2c-omap.c | 5 ++---
> 1 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
> index fa23faa..2efdc6b 100644
> --- a/drivers/i2c/busses/i2c-omap.c
> +++ b/drivers/i2c/busses/i2c-omap.c
> @@ -1111,8 +1111,7 @@ err_release_region:
> return r;
> }
>
> -static int
> -omap_i2c_remove(struct platform_device *pdev)
> +static int __devexit omap_i2c_remove(struct platform_device *pdev)
> {
> struct omap_i2c_dev *dev = platform_get_drvdata(pdev);
> struct resource *mem;
> @@ -1161,7 +1160,7 @@ static struct dev_pm_ops omap_i2c_pm_ops = {
>
> static struct platform_driver omap_i2c_driver = {
> .probe = omap_i2c_probe,
> - .remove = omap_i2c_remove,
> + .remove = __devexit_p(omap_i2c_remove),
> .driver = {
> .name = "omap_i2c",
> .owner = THIS_MODULE,
> --
> 1.7.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Ben Dooks, ben-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org, http://www.fluff.org/ben/
Large Hadron Colada: A large Pina Colada that makes the universe disappear.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] OMAP: I2C: add devexit to the remove code
[not found] ` <20120106162820.GB8441-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org>
@ 2012-01-10 6:40 ` Datta, Shubhrajyoti
0 siblings, 0 replies; 3+ messages in thread
From: Datta, Shubhrajyoti @ 2012-01-10 6:40 UTC (permalink / raw)
To: Ben Dooks
Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA,
linux-i2c-u79uwXL29TY76Z2rM5mHXA,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
ben-linux-elnMNo+KYs3YtjvyW6yDsg
On Fri, Jan 6, 2012 at 9:58 PM, Ben Dooks <ben-i2c-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org> wrote:
> On Tue, Dec 20, 2011 at 12:55:59PM +0530, Shubhrajyoti D wrote:
>> The omap_i2c_remove function may not be needed after
>> device exit so the memory could be freed.
>>
>> Signed-off-by: Shubhrajyoti D <shubhrajyoti-l0cyMroinI0@public.gmane.org>
>
> Will add this later.
OK thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-01-10 6:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-20 7:25 [PATCH] OMAP: I2C: add devexit to the remove code Shubhrajyoti D
[not found] ` <1324365959-4143-1-git-send-email-shubhrajyoti-l0cyMroinI0@public.gmane.org>
2012-01-06 16:28 ` Ben Dooks
[not found] ` <20120106162820.GB8441-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org>
2012-01-10 6:40 ` Datta, Shubhrajyoti
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).