linux-next: build failure after merge of the i2c tree

2013-11-17 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (arm
multi_v7_defconfig) failed like this:

drivers/i2c/busses/i2c-bcm-kona.c: In function 'bcm_kona_send_i2c_cmd':
drivers/i2c/busses/i2c-bcm-kona.c:268:2: error: implicit declaration of 
function 'INIT_COMPLETION' [-Werror=implicit-function-declaration]

Caused by commit 93d17247118c ("i2c: bcm-kona: Introduce Broadcom I2C
Driver") interacting with commit 62026aedaace ("sched: remove
INIT_COMPLETION") from Linus` tree.

I have applied the following merge fix patch and can carry it as
necessary (please inform Linus of this when you ask him to merge your
tree).

From: Stephen Rothwell 
Date: Mon, 18 Nov 2013 10:26:37 +1100
Subject: [PATCH] i2c: bcm-kona: fix for INIT_COMPLETION -> reinit_completion
 API change

Signed-off-by: Stephen Rothwell 
---
 drivers/i2c/busses/i2c-bcm-kona.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/i2c/busses/i2c-bcm-kona.c 
b/drivers/i2c/busses/i2c-bcm-kona.c
index 7b7b7622b0d1..865e5dd9e655 100644
--- a/drivers/i2c/busses/i2c-bcm-kona.c
+++ b/drivers/i2c/busses/i2c-bcm-kona.c
@@ -265,7 +265,7 @@ static int bcm_kona_send_i2c_cmd(struct bcm_kona_i2c_dev 
*dev,
writel(IER_I2C_INT_EN_MASK, dev->base + IER_OFFSET);
 
/* Mark as incomplete before sending the command */
-   INIT_COMPLETION(dev->done);
+   reinit_completion(&dev->done);
 
/* Send the command */
bcm_kona_i2c_send_cmd_to_ctrl(dev, cmd);
@@ -295,7 +295,7 @@ static int bcm_kona_i2c_read_fifo_single(struct 
bcm_kona_i2c_dev *dev,
unsigned long time_left = msecs_to_jiffies(I2C_TIMEOUT);
 
/* Mark as incomplete before starting the RX FIFO */
-   INIT_COMPLETION(dev->done);
+   reinit_completion(&dev->done);
 
/* Unmask the read complete interrupt */
writel(IER_READ_COMPLETE_INT_MASK, dev->base + IER_OFFSET);
@@ -372,7 +372,7 @@ static int bcm_kona_i2c_write_byte(struct bcm_kona_i2c_dev 
*dev, uint8_t data,
writel(IER_I2C_INT_EN_MASK, dev->base + IER_OFFSET);
 
/* Mark as incomplete before sending the data */
-   INIT_COMPLETION(dev->done);
+   reinit_completion(&dev->done);
 
/* Send one byte of data */
writel(data, dev->base + DAT_OFFSET);
@@ -407,7 +407,7 @@ static int bcm_kona_i2c_write_fifo_single(struct 
bcm_kona_i2c_dev *dev,
unsigned int fifo_status;
 
/* Mark as incomplete before sending data to the TX FIFO */
-   INIT_COMPLETION(dev->done);
+   reinit_completion(&dev->done);
 
/* Unmask the fifo empty and nak interrupt */
writel(IER_FIFO_INT_EN_MASK | IER_NOACK_EN_MASK,
-- 
1.8.4.3

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpvBBH7I8Q0i.pgp
Description: PGP signature


linux-next: build failure after merge of the i2c tree

2014-11-24 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (powerpc
allyesconfig) failed like this:

drivers/i2c/busses/i2c-rk3x.c: In function 'rk3x_i2c_clk_notifier_cb':
drivers/i2c/busses/i2c-rk3x.c:634:7: error: 'PRE_RATE_CHANGE' undeclared (first 
use in this function)
  case PRE_RATE_CHANGE:
   ^
drivers/i2c/busses/i2c-rk3x.c:634:7: note: each undeclared identifier is 
reported only once for each function it appears in
drivers/i2c/busses/i2c-rk3x.c:635:31: error: dereferencing pointer to 
incomplete type
   if (rk3x_i2c_calc_divs(ndata->new_rate, i2c->scl_frequency,
   ^
drivers/i2c/busses/i2c-rk3x.c:641:12: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate > ndata->old_rate)
^
drivers/i2c/busses/i2c-rk3x.c:641:30: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate > ndata->old_rate)
  ^
drivers/i2c/busses/i2c-rk3x.c:642:33: error: dereferencing pointer to 
incomplete type
rk3x_i2c_adapt_div(i2c, ndata->new_rate);
 ^
drivers/i2c/busses/i2c-rk3x.c:645:7: error: 'POST_RATE_CHANGE' undeclared 
(first use in this function)
  case POST_RATE_CHANGE:
   ^
drivers/i2c/busses/i2c-rk3x.c:647:12: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate < ndata->old_rate)
^
drivers/i2c/busses/i2c-rk3x.c:647:30: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate < ndata->old_rate)
  ^
drivers/i2c/busses/i2c-rk3x.c:648:33: error: dereferencing pointer to 
incomplete type
rk3x_i2c_adapt_div(i2c, ndata->new_rate);
 ^
drivers/i2c/busses/i2c-rk3x.c:650:7: error: 'ABORT_RATE_CHANGE' undeclared 
(first use in this function)
  case ABORT_RATE_CHANGE:
   ^
drivers/i2c/busses/i2c-rk3x.c:652:12: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate > ndata->old_rate)
^
drivers/i2c/busses/i2c-rk3x.c:652:30: error: dereferencing pointer to 
incomplete type
   if (ndata->new_rate > ndata->old_rate)
  ^
drivers/i2c/busses/i2c-rk3x.c:653:33: error: dereferencing pointer to 
incomplete type
rk3x_i2c_adapt_div(i2c, ndata->old_rate);
 ^
drivers/i2c/busses/i2c-rk3x.c: In function 'rk3x_i2c_probe':
drivers/i2c/busses/i2c-rk3x.c:941:2: error: implicit declaration of function 
'clk_notifier_register' [-Werror=implicit-function-declaration]
  ret = clk_notifier_register(i2c->clk, &i2c->clk_rate_nb);
  ^
drivers/i2c/busses/i2c-rk3x.c:961:2: error: implicit declaration of function 
'clk_notifier_unregister' [-Werror=implicit-function-declaration]
  clk_notifier_unregister(i2c->clk, &i2c->clk_rate_nb);
  ^

Caused by commit 5a6f1566f6a0 ("i2c: rk3x: handle dynamic clock rate
changes correctly").

I have reverted that commit for today.
-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpbigb70VFBc.pgp
Description: OpenPGP digital signature


linux-next: build failure after merge of the i2c tree

2015-01-15 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (x86_64
allmodconfig) failed like this:

drivers/i2c/i2c-core.c: In function 'i2c_unregister_device':
drivers/i2c/i2c-core.c:1016:3: error: implicit declaration of function 
'of_node_clear_flag' [-Werror=implicit-function-declaration]
   of_node_clear_flag(client->dev.of_node, OF_POPULATED);
   ^
drivers/i2c/i2c-core.c:1016:43: error: 'OF_POPULATED' undeclared (first use in 
this function)
   of_node_clear_flag(client->dev.of_node, OF_POPULATED);
   ^

Caused by commit d5285c36e6d2 ("i2c: Mark instantiated device nodes
with OF_POPULATE").

I have used the version of the i2c tree from next-20150115 for today.
-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au



pgpWtLdtVphvP.pgp
Description: OpenPGP digital signature


linux-next: build failure after merge of the i2c tree

2015-08-24 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (x86_64 allmodconfig)
failed like this:

ERROR: "of_irq_get_byname" [drivers/i2c/i2c-core.ko] undefined!

Caused by commit

  efb6a10b761e ("i2c: allow specifying separate wakeup interrupt in device 
tree")

I have used the i2c tree from next-20150824 for today.

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


linux-next: build failure after merge of the i2c tree

2015-12-15 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (powerpc
ppc44x_defconfig) failed like this:

drivers/i2c/busses/i2c-ibm_iic.c:102:15: error: redefinition of 'struct 
i2c_timings'
 static struct i2c_timings {
   ^
In file included from drivers/i2c/busses/i2c-ibm_iic.c:42:0:
include/linux/i2c.h:424:8: note: originally defined here
 struct i2c_timings {
^

Caused by commit

  e1dba01ca620 ("i2c: add generic routine to parse DT for timing information")

I have applied the following patch for today:

From: Stephen Rothwell 
Date: Wed, 16 Dec 2015 15:34:10 +1100
Subject: [PATCH] ii2c: rename i2c_timings struct due to clash with generic 
version

Fixes: e1dba01ca620 ("i2c: add generic routine to parse DT for timing 
information")
Signed-off-by: Stephen Rothwell 
---
 drivers/i2c/busses/i2c-ibm_iic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/i2c/busses/i2c-ibm_iic.c b/drivers/i2c/busses/i2c-ibm_iic.c
index ab492301581a..51154fada1df 100644
--- a/drivers/i2c/busses/i2c-ibm_iic.c
+++ b/drivers/i2c/busses/i2c-ibm_iic.c
@@ -99,7 +99,7 @@ static void dump_iic_regs(const char* header, struct 
ibm_iic_private* dev)
 #endif
 
 /* Bus timings (in ns) for bit-banging */
-static struct i2c_timings {
+static struct ibm_i2c_timings {
unsigned int hd_sta;
unsigned int su_sto;
unsigned int low;
@@ -241,7 +241,7 @@ static int iic_dc_wait(volatile struct iic_regs __iomem 
*iic, u8 mask)
 static int iic_smbus_quick(struct ibm_iic_private* dev, const struct i2c_msg* 
p)
 {
volatile struct iic_regs __iomem *iic = dev->vaddr;
-   const struct i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];
+   const struct ibm_i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];
u8 mask, v, sda;
int i, res;
 
-- 
2.6.2

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


linux-next: build failure after merge of the i2c tree

2017-06-25 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (x86_64 allmodconfig)
failed like this:

drivers/i2c/busses/i2c-zx2967.c: In function 'zx2967_i2c_writesb':
drivers/i2c/busses/i2c-zx2967.c:87:2: error: implicit declaration of function 
'writesb' [-Werror=implicit-function-declaration]
  writesb(i2c->reg_base + reg, data, len);
  ^
drivers/i2c/busses/i2c-zx2967.c: In function 'zx2967_i2c_readsb':
drivers/i2c/busses/i2c-zx2967.c:93:2: error: implicit declaration of function 
'readsb' [-Werror=implicit-function-declaration]
  readsb(i2c->reg_base + reg, data, len);
  ^

Caused by commit

  9615a01f71ca ("i2c: zx2967: add i2c controller driver for ZTE's zx2967 
family")

Forgotten some include file, presumably.  And COMPILE_TEST may have
been a bit hopeful :-)

I have used the i2c tree from next-20170623 for today.

-- 
Cheers,
Stephen Rothwell


linux-next: build failure after merge of the i2c tree

2017-11-27 Thread Stephen Rothwell
Hi Wolfram,

After merging the i2c tree, today's linux-next build (powerpc
ppc64_defconfig) failed like this:

drivers/i2c/i2c-core-base.c: In function 'get_scl_gpio_value':
drivers/i2c/i2c-core-base.c:137:9: error: implicit declaration of function 
'gpiod_get_value_cansleep' [-Werror=implicit-function-declaration]
  return gpiod_get_value_cansleep(adap->bus_recovery_info->scl_gpiod);
 ^
drivers/i2c/i2c-core-base.c: In function 'set_scl_gpio_value':
drivers/i2c/i2c-core-base.c:142:2: error: implicit declaration of function 
'gpiod_set_value_cansleep' [-Werror=implicit-function-declaration]
  gpiod_set_value_cansleep(adap->bus_recovery_info->scl_gpiod, val);
  ^

Caused by commit

  3991c5c80bea ("i2c: Switch to using gpiod interface for gpio bus recovery")

It is declared in include/linux/gpio/consumer.h which is not directly
included by drivers/i2c/i2c-core-base.c ...

I have used the i2c tree from next-20171127 for today.

-- 
Cheers,
Stephen Rothwell


Re: linux-next: build failure after merge of the i2c tree

2014-11-24 Thread Wolfram Sang
> Caused by commit 5a6f1566f6a0 ("i2c: rk3x: handle dynamic clock rate
> changes correctly").

Yes, missing Kconfig dependency on COMMON_CLK. I'll add and push the fix
today. Thanks!




signature.asc
Description: Digital signature


Re: linux-next: build failure after merge of the i2c tree

2015-01-15 Thread Pantelis Antoniou
Hi Stephen,

> On Jan 16, 2015, at 04:22 , Stephen Rothwell  wrote:
> 
> Hi Wolfram,
> 
> After merging the i2c tree, today's linux-next build (x86_64
> allmodconfig) failed like this:
> 
> drivers/i2c/i2c-core.c: In function 'i2c_unregister_device':
> drivers/i2c/i2c-core.c:1016:3: error: implicit declaration of function 
> 'of_node_clear_flag' [-Werror=implicit-function-declaration]
>   of_node_clear_flag(client->dev.of_node, OF_POPULATED);
>   ^
> drivers/i2c/i2c-core.c:1016:43: error: 'OF_POPULATED' undeclared (first use 
> in this function)
>   of_node_clear_flag(client->dev.of_node, OF_POPULATED);
>   ^
> 
> Caused by commit d5285c36e6d2 ("i2c: Mark instantiated device nodes
> with OF_POPULATE").
> 
> I have used the version of the i2c tree from next-20150115 for today.

A patch that fixes it has already been posted.

> -- 
> Cheers,
> Stephen Rothwells...@canb.auug.org.au
> 

Regards

— Pantelis

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: linux-next: build failure after merge of the i2c tree

2015-08-25 Thread Dmitry Torokhov
On Mon, Aug 24, 2015 at 5:51 PM, Stephen Rothwell  wrote:
> Hi Wolfram,
>
> After merging the i2c tree, today's linux-next build (x86_64 allmodconfig)
> failed like this:
>
> ERROR: "of_irq_get_byname" [drivers/i2c/i2c-core.ko] undefined!
>
> Caused by commit
>
>   efb6a10b761e ("i2c: allow specifying separate wakeup interrupt in device 
> tree")
>
> I have used the i2c tree from next-20150824 for today.

Ugh, of_get_irq_byname is not exported; I'll send a patch.

Thanks.

-- 
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: linux-next: build failure after merge of the i2c tree

2016-01-04 Thread Stephen Rothwell
Hi all,

On Wed, 16 Dec 2015 15:48:13 +1100 Stephen Rothwell  
wrote:
>
> After merging the i2c tree, today's linux-next build (powerpc
> ppc44x_defconfig) failed like this:
> 
> drivers/i2c/busses/i2c-ibm_iic.c:102:15: error: redefinition of 'struct 
> i2c_timings'
>  static struct i2c_timings {
>^
> In file included from drivers/i2c/busses/i2c-ibm_iic.c:42:0:
> include/linux/i2c.h:424:8: note: originally defined here
>  struct i2c_timings {
> ^
> 
> Caused by commit
> 
>   e1dba01ca620 ("i2c: add generic routine to parse DT for timing information")
> 
> I have applied the following patch for today:
> 
> From: Stephen Rothwell 
> Date: Wed, 16 Dec 2015 15:34:10 +1100
> Subject: [PATCH] ii2c: rename i2c_timings struct due to clash with generic 
> version
> 
> Fixes: e1dba01ca620 ("i2c: add generic routine to parse DT for timing 
> information")
> Signed-off-by: Stephen Rothwell 
> ---
>  drivers/i2c/busses/i2c-ibm_iic.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/i2c/busses/i2c-ibm_iic.c 
> b/drivers/i2c/busses/i2c-ibm_iic.c
> index ab492301581a..51154fada1df 100644
> --- a/drivers/i2c/busses/i2c-ibm_iic.c
> +++ b/drivers/i2c/busses/i2c-ibm_iic.c
> @@ -99,7 +99,7 @@ static void dump_iic_regs(const char* header, struct 
> ibm_iic_private* dev)
>  #endif
>  
>  /* Bus timings (in ns) for bit-banging */
> -static struct i2c_timings {
> +static struct ibm_i2c_timings {
>   unsigned int hd_sta;
>   unsigned int su_sto;
>   unsigned int low;
> @@ -241,7 +241,7 @@ static int iic_dc_wait(volatile struct iic_regs __iomem 
> *iic, u8 mask)
>  static int iic_smbus_quick(struct ibm_iic_private* dev, const struct 
> i2c_msg* p)
>  {
>   volatile struct iic_regs __iomem *iic = dev->vaddr;
> - const struct i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];
> + const struct ibm_i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];
>   u8 mask, v, sda;
>   int i, res;
>  
> -- 
> 2.6.2

Ping?

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: linux-next: build failure after merge of the i2c tree

2016-01-04 Thread Wolfram Sang
Stephen,

> > After merging the i2c tree, today's linux-next build (powerpc
> > ppc44x_defconfig) failed like this:

Oops, yes.

> >  /* Bus timings (in ns) for bit-banging */
> > -static struct i2c_timings {
> > +static struct ibm_i2c_timings {

I changed it to ibm_iic_timings for consistency reasons...

> > volatile struct iic_regs __iomem *iic = dev->vaddr;
> > -   const struct i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];
> > +   const struct ibm_i2c_timings* t = &timings[dev->fast_mode ? 1 : 0];

... and fixed the placement of the * operator ...

> > u8 mask, v, sda;
> > int i, res;
> >  
> > -- 
> > 2.6.2
> 
> Ping?

... and applied to for-next, thanks! The patch got lost because the
i2c-list was not on CC and thus patchwork couldn't catch it.



signature.asc
Description: Digital signature


Re: linux-next: build failure after merge of the i2c tree

2017-06-25 Thread Shawn Guo
Hi Stephen,

On Mon, Jun 26, 2017 at 11:09:07AM +1000, Stephen Rothwell wrote:
> Hi Wolfram,
> 
> After merging the i2c tree, today's linux-next build (x86_64 allmodconfig)
> failed like this:
> 
> drivers/i2c/busses/i2c-zx2967.c: In function 'zx2967_i2c_writesb':
> drivers/i2c/busses/i2c-zx2967.c:87:2: error: implicit declaration of function 
> 'writesb' [-Werror=implicit-function-declaration]
>   writesb(i2c->reg_base + reg, data, len);
>   ^
> drivers/i2c/busses/i2c-zx2967.c: In function 'zx2967_i2c_readsb':
> drivers/i2c/busses/i2c-zx2967.c:93:2: error: implicit declaration of function 
> 'readsb' [-Werror=implicit-function-declaration]
>   readsb(i2c->reg_base + reg, data, len);
>   ^
> 
> Caused by commit
> 
>   9615a01f71ca ("i2c: zx2967: add i2c controller driver for ZTE's zx2967 
> family")
> 
> Forgotten some include file, presumably.  And COMPILE_TEST may have
> been a bit hopeful :-)

Thanks for reporting it.  I have sent a fix [1] for it yesterday, which
hopefully will be applied soon.

Shawn

[1] https://patchwork.ozlabs.org/patch/780357/


Re: linux-next: build failure after merge of the i2c tree

2017-11-28 Thread Wolfram Sang
Hi Stephen,

> It is declared in include/linux/gpio/consumer.h which is not directly
> included by drivers/i2c/i2c-core-base.c ...
> 
> I have used the i2c tree from next-20171127 for today.

Yes, thank you for the report! buildbot now reported this same problem
and Phil has already sent fixes which I just pushed out.

I think I should give such refactoring series an extra round of buildbot
by having them in a seperate branch for a while before I merge them into
for-next...

Thanks,

   Wolfram



signature.asc
Description: PGP signature