diff mbox

i2c: designware: remove HAVE_CLK build dependecy

Message ID f3ebead75d45623e4b649c7a8d0112584ffd1788.1388392279.git.baruch@tkos.co.il
State Accepted
Headers show

Commit Message

Baruch Siach Dec. 30, 2013, 8:31 a.m. UTC
Since 93abe8e4 (clk: add non CONFIG_HAVE_CLK routines) code using clk.h need
not depend on HAVE_CLK. Also, remove a redundant clk.h include from core driver
file.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
---
 drivers/i2c/busses/Kconfig               | 1 -
 drivers/i2c/busses/i2c-designware-core.c | 1 -
 2 files changed, 2 deletions(-)

Comments

Wolfram Sang Jan. 4, 2014, 10:48 p.m. UTC | #1
On Mon, Dec 30, 2013 at 10:31:19AM +0200, Baruch Siach wrote:
> Since 93abe8e4 (clk: add non CONFIG_HAVE_CLK routines) code using clk.h need
> not depend on HAVE_CLK. Also, remove a redundant clk.h include from core driver
> file.
> 
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>

Is the patch description correct? The core driver simply does not need
clk.h and thus the dependency. No redundancy here, or?
Baruch Siach Jan. 5, 2014, 5:04 a.m. UTC | #2
Hi Wolfram,

On Sat, Jan 04, 2014 at 11:48:46PM +0100, Wolfram Sang wrote:
> On Mon, Dec 30, 2013 at 10:31:19AM +0200, Baruch Siach wrote:
> > Since 93abe8e4 (clk: add non CONFIG_HAVE_CLK routines) code using clk.h need
> > not depend on HAVE_CLK. Also, remove a redundant clk.h include from core driver
> > file.
> > 
> > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> 
> Is the patch description correct? The core driver simply does not need
> clk.h and thus the dependency. No redundancy here, or?

The platform code (i2c-designware-platform.c) uses the clk API, but the 
Kconfig dependency on HAVE_CLK is not needed anymore. The core code 
(i2c-designware-core.c) doesn't use clk. Originally the driver was in a single 
file, including the clk handling. This code has been moved to the platform 
file, so the core file doesn't need the clk.h include.

Logically, these are two separate issues. But I'm not sure it is worth 
splitting into two patches. What do you think?

baruch
Baruch Siach Jan. 13, 2014, 12:18 p.m. UTC | #3
Hi Wolfram,

Ping?

On Sun, Jan 05, 2014 at 07:04:10AM +0200, Baruch Siach wrote:
> On Sat, Jan 04, 2014 at 11:48:46PM +0100, Wolfram Sang wrote:
> > On Mon, Dec 30, 2013 at 10:31:19AM +0200, Baruch Siach wrote:
> > > Since 93abe8e4 (clk: add non CONFIG_HAVE_CLK routines) code using clk.h need
> > > not depend on HAVE_CLK. Also, remove a redundant clk.h include from core driver
> > > file.
> > > 
> > > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> > 
> > Is the patch description correct? The core driver simply does not need
> > clk.h and thus the dependency. No redundancy here, or?
> 
> The platform code (i2c-designware-platform.c) uses the clk API, but the 
> Kconfig dependency on HAVE_CLK is not needed anymore. The core code 
> (i2c-designware-core.c) doesn't use clk. Originally the driver was in a single 
> file, including the clk handling. This code has been moved to the platform 
> file, so the core file doesn't need the clk.h include.
> 
> Logically, these are two separate issues. But I'm not sure it is worth 
> splitting into two patches. What do you think?

baruch
Wolfram Sang Jan. 13, 2014, 12:39 p.m. UTC | #4
> The platform code (i2c-designware-platform.c) uses the clk API, but the 
> Kconfig dependency on HAVE_CLK is not needed anymore. The core code 
> (i2c-designware-core.c) doesn't use clk. Originally the driver was in a single 
> file, including the clk handling. This code has been moved to the platform 
> file, so the core file doesn't need the clk.h include.

Ah, now I got it. Updated the commit msg slightly to make clear about
the platform driver vs core difference and applied to for-next, thanks!
diff mbox

Patch

diff --git a/drivers/i2c/busses/Kconfig b/drivers/i2c/busses/Kconfig
index 3b26129..2b6056a 100644
--- a/drivers/i2c/busses/Kconfig
+++ b/drivers/i2c/busses/Kconfig
@@ -412,7 +412,6 @@  config I2C_DESIGNWARE_CORE
 
 config I2C_DESIGNWARE_PLATFORM
 	tristate "Synopsys DesignWare Platform"
-	depends on HAVE_CLK
 	select I2C_DESIGNWARE_CORE
 	help
 	  If you say yes to this option, support will be included for the
diff --git a/drivers/i2c/busses/i2c-designware-core.c b/drivers/i2c/busses/i2c-designware-core.c
index e89e3e2..14c4b30 100644
--- a/drivers/i2c/busses/i2c-designware-core.c
+++ b/drivers/i2c/busses/i2c-designware-core.c
@@ -26,7 +26,6 @@ 
  *
  */
 #include <linux/export.h>
-#include <linux/clk.h>
 #include <linux/errno.h>
 #include <linux/err.h>
 #include <linux/i2c.h>