Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753444Ab3IQQcK (ORCPT ); Tue, 17 Sep 2013 12:32:10 -0400 Received: from mail-yh0-f51.google.com ([209.85.213.51]:63675 "EHLO mail-yh0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752914Ab3IQQcJ (ORCPT ); Tue, 17 Sep 2013 12:32:09 -0400 Date: Tue, 17 Sep 2013 11:31:53 -0500 From: Kim Phillips To: linux-samsung-soc@vger.kernel.org, linux-i2c@vger.kernel.org Cc: Ben Dooks , Kukjin Kim , Wolfram Sang , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] i2c: s3c2410: fix clk_disable/clk_unprepare warnings Message-Id: <20130917113153.41b0305d6892170ba8e1ecf7@linaro.org> X-Mailer: Sylpheed 3.3.0 (GTK+ 2.24.17; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 4439 Lines: 78 commit d16933b33914a6dff38a4ecbe8edce44a17898e8 "i2c: s3c2410: Move location of clk_prepare_enable() call in probe function" refactored clk_enable and clk_disable calls yet neglected to remove the clk_disable_unprepare call in the module's remove(). It helps remove warnings on an arndale during unbind: echo 12c90000.i2c > /sys/bus/platform/devices/12c90000.i2c/driver/unbind ------------[ cut here ]------------ WARNING: CPU: 0 PID: 2548 at drivers/clk/clk.c:842 clk_disable+0x18/0x24() Modules linked in: CPU: 0 PID: 2548 Comm: bash Not tainted 3.11.0-next-20130916-00003-gf4bddbc #6 [] (unwind_backtrace+0x0/0xf8) from [] (show_stack+0x10/0x14) [] (show_stack+0x10/0x14) from [] (dump_stack+0x6c/0xac) [] (dump_stack+0x6c/0xac) from [] (warn_slowpath_common+0x64/0x88) [] (warn_slowpath_common+0x64/0x88) from [] (warn_slowpath_null+0x1c/0x24) [] (warn_slowpath_null+0x1c/0x24) from [] (clk_disable+0x18/0x24) [] (clk_disable+0x18/0x24) from [] (s3c24xx_i2c_remove+0x28/0x70) [] (s3c24xx_i2c_remove+0x28/0x70) from [] (platform_drv_remove+0x18/0x1c) [] (platform_drv_remove+0x18/0x1c) from [] (__device_release_driver+0x58/0xb4) [] (__device_release_driver+0x58/0xb4) from [] (device_release_driver+0x1c/0x28) [] (device_release_driver+0x1c/0x28) from [] (unbind_store+0x58/0x90) [] (unbind_store+0x58/0x90) from [] (drv_attr_store+0x20/0x2c) [] (drv_attr_store+0x20/0x2c) from [] (sysfs_write_file+0x168/0x198) [] (sysfs_write_file+0x168/0x198) from [] (vfs_write+0xb0/0x194) [] (vfs_write+0xb0/0x194) from [] (SyS_write+0x3c/0x70) [] (SyS_write+0x3c/0x70) from [] (ret_fast_syscall+0x0/0x30) ---[ end trace 4c9f9403066f57a6 ]--- ------------[ cut here ]------------ WARNING: CPU: 0 PID: 2548 at drivers/clk/clk.c:751 clk_unprepare+0x14/0x1c() Modules linked in: CPU: 0 PID: 2548 Comm: bash Tainted: G W 3.11.0-next-20130916-00003-gf4bddbc #6 [] (unwind_backtrace+0x0/0xf8) from [] (show_stack+0x10/0x14) [] (show_stack+0x10/0x14) from [] (dump_stack+0x6c/0xac) [] (dump_stack+0x6c/0xac) from [] (warn_slowpath_common+0x64/0x88) [] (warn_slowpath_common+0x64/0x88) from [] (warn_slowpath_null+0x1c/0x24) [] (warn_slowpath_null+0x1c/0x24) from [] (clk_unprepare+0x14/0x1c) [] (clk_unprepare+0x14/0x1c) from [] (s3c24xx_i2c_remove+0x30/0x70) [] (s3c24xx_i2c_remove+0x30/0x70) from [] (platform_drv_remove+0x18/0x1c) [] (platform_drv_remove+0x18/0x1c) from [] (__device_release_driver+0x58/0xb4) [] (__device_release_driver+0x58/0xb4) from [] (device_release_driver+0x1c/0x28) [] (device_release_driver+0x1c/0x28) from [] (unbind_store+0x58/0x90) [] (unbind_store+0x58/0x90) from [] (drv_attr_store+0x20/0x2c) [] (drv_attr_store+0x20/0x2c) from [] (sysfs_write_file+0x168/0x198) [] (sysfs_write_file+0x168/0x198) from [] (vfs_write+0xb0/0x194) [] (vfs_write+0xb0/0x194) from [] (SyS_write+0x3c/0x70) [] (SyS_write+0x3c/0x70) from [] (ret_fast_syscall+0x0/0x30) ---[ end trace 4c9f9403066f57a7 ]--- Cc: Ben Dooks Cc: Kukjin Kim Cc: Wolfram Sang Signed-off-by: Kim Phillips --- drivers/i2c/busses/i2c-s3c2410.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c index 3535f3c..3747b9b 100644 --- a/drivers/i2c/busses/i2c-s3c2410.c +++ b/drivers/i2c/busses/i2c-s3c2410.c @@ -1178,8 +1178,6 @@ static int s3c24xx_i2c_remove(struct platform_device *pdev) i2c_del_adapter(&i2c->adap); - clk_disable_unprepare(i2c->clk); - if (pdev->dev.of_node && IS_ERR(i2c->pctrl)) s3c24xx_i2c_dt_gpio_free(i2c); -- 1.8.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/