From: Russell King Date: Wed, 7 Jan 2009 15:20:26 +0000 (+0200) Subject: OMAP2/3 clock: remove clk->owner X-Git-Tag: v2.6.28-omap1~36 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=59ae1e06b177e462d75586d83380f18a7024e77b;p=linux-2.6-omap-h63xx.git OMAP2/3 clock: remove clk->owner clk->owner is always NULL, so its existence doesn't serve any useful function other than bloating the kernel by 992 bytes. Remove it. Signed-off-by: Russell King Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren --- diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c index 80eb558cee4..ab3d87910a1 100644 --- a/arch/arm/plat-omap/clock.c +++ b/arch/arm/plat-omap/clock.c @@ -191,15 +191,14 @@ struct clk * clk_get(struct device *dev, const char *id) mutex_lock(&clocks_mutex); list_for_each_entry(p, &clocks, node) { - if (p->id == idno && - strcmp(id, p->name) == 0 && try_module_get(p->owner)) { + if (p->id == idno && strcmp(id, p->name) == 0) { clk = p; goto found; } } list_for_each_entry(p, &clocks, node) { - if (strcmp(id, p->name) == 0 && try_module_get(p->owner)) { + if (strcmp(id, p->name) == 0) { clk = p; break; } @@ -295,8 +294,6 @@ EXPORT_SYMBOL(clk_get_rate); void clk_put(struct clk *clk) { - if (clk && !IS_ERR(clk)) - module_put(clk->owner); } EXPORT_SYMBOL(clk_put); diff --git a/arch/arm/plat-omap/include/mach/clock.h b/arch/arm/plat-omap/include/mach/clock.h index a0398322899..58450a12759 100644 --- a/arch/arm/plat-omap/include/mach/clock.h +++ b/arch/arm/plat-omap/include/mach/clock.h @@ -77,7 +77,6 @@ struct clk_child { struct clk { struct list_head node; - struct module *owner; const char *name; int id; struct clk *parent;