All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
@ 2013-02-14 12:23 Magnus Damm
  2013-02-14 12:26 ` Laurent Pinchart
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Magnus Damm @ 2013-02-14 12:23 UTC (permalink / raw)
  To: linux-sh

From: Magnus Damm <damm@opensource.se>

Fix sizeof() usage in sh-pfc/core.c to allocate space
for the full data structure instead of a pointer.

Signed-off-by: Magnus Damm <damm@opensource.se>
---

 Written against -next in renesas.git

 drivers/pinctrl/sh-pfc/core.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- 0001/drivers/pinctrl/sh-pfc/core.c
+++ work/drivers/pinctrl/sh-pfc/core.c	2013-02-14 21:04:20.000000000 +0900
@@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_
 	if (info = NULL)
 		return -ENODEV;
 
-	pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
+	pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
 	if (pfc = NULL)
 		return -ENOMEM;
 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
@ 2013-02-14 12:26 ` Laurent Pinchart
  2013-02-14 12:27 ` Magnus Damm
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Laurent Pinchart @ 2013-02-14 12:26 UTC (permalink / raw)
  To: linux-sh

Hi Magnus,

Thanks for the patch.

On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
> From: Magnus Damm <damm@opensource.se>
> 
> Fix sizeof() usage in sh-pfc/core.c to allocate space
> for the full data structure instead of a pointer.

Oops :-)

This is v3.9 material. Simon, could you please take this and push it upstream 
for v3.9 ?

> Signed-off-by: Magnus Damm <damm@opensource.se>
> ---
> 
>  Written against -next in renesas.git
> 
>  drivers/pinctrl/sh-pfc/core.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- 0001/drivers/pinctrl/sh-pfc/core.c
> +++ work/drivers/pinctrl/sh-pfc/core.c	2013-02-14 21:04:20.000000000 +0900
> @@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_
>  	if (info = NULL)
>  		return -ENODEV;
> 
> -	pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
> +	pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
>  	if (pfc = NULL)
>  		return -ENOMEM;
-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
  2013-02-14 12:26 ` Laurent Pinchart
@ 2013-02-14 12:27 ` Magnus Damm
  2013-02-14 12:27 ` Laurent Pinchart
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Magnus Damm @ 2013-02-14 12:27 UTC (permalink / raw)
  To: linux-sh

Hi Laurent,

On Thu, Feb 14, 2013 at 9:26 PM, Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
> Hi Magnus,
>
> Thanks for the patch.
>
> On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
>> From: Magnus Damm <damm@opensource.se>
>>
>> Fix sizeof() usage in sh-pfc/core.c to allocate space
>> for the full data structure instead of a pointer.
>
> Oops :-)

=)

> This is v3.9 material. Simon, could you please take this and push it upstream
> for v3.9 ?

Yes, that would be great!

/ magnus

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
  2013-02-14 12:26 ` Laurent Pinchart
  2013-02-14 12:27 ` Magnus Damm
@ 2013-02-14 12:27 ` Laurent Pinchart
  2013-02-14 15:56 ` Simon Horman
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Laurent Pinchart @ 2013-02-14 12:27 UTC (permalink / raw)
  To: linux-sh

On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
> From: Magnus Damm <damm@opensource.se>
> 
> Fix sizeof() usage in sh-pfc/core.c to allocate space
> for the full data structure instead of a pointer.
> 
> Signed-off-by: Magnus Damm <damm@opensource.se>

Forgot to add my

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
> 
>  Written against -next in renesas.git
> 
>  drivers/pinctrl/sh-pfc/core.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- 0001/drivers/pinctrl/sh-pfc/core.c
> +++ work/drivers/pinctrl/sh-pfc/core.c	2013-02-14 21:04:20.000000000 +0900
> @@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_
>  	if (info = NULL)
>  		return -ENODEV;
> 
> -	pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
> +	pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
>  	if (pfc = NULL)
>  		return -ENOMEM;
-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
                   ` (2 preceding siblings ...)
  2013-02-14 12:27 ` Laurent Pinchart
@ 2013-02-14 15:56 ` Simon Horman
  2013-02-15  1:47 ` Magnus Damm
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 10+ messages in thread
From: Simon Horman @ 2013-02-14 15:56 UTC (permalink / raw)
  To: linux-sh

On Thu, Feb 14, 2013 at 01:26:42PM +0100, Laurent Pinchart wrote:
> Hi Magnus,
> 
> Thanks for the patch.
> 
> On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
> > From: Magnus Damm <damm@opensource.se>
> > 
> > Fix sizeof() usage in sh-pfc/core.c to allocate space
> > for the full data structure instead of a pointer.
> 
> Oops :-)
> 
> This is v3.9 material. Simon, could you please take this and push it upstream 
> for v3.9 ?

Sure, will do.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
                   ` (3 preceding siblings ...)
  2013-02-14 15:56 ` Simon Horman
@ 2013-02-15  1:47 ` Magnus Damm
  2013-02-15 19:46 ` Linus Walleij
  2013-02-16  6:14 ` Simon Horman
  6 siblings, 0 replies; 10+ messages in thread
From: Magnus Damm @ 2013-02-15  1:47 UTC (permalink / raw)
  To: linux-sh

Hi Simon,

On Fri, Feb 15, 2013 at 12:56 AM, Simon Horman <horms@verge.net.au> wrote:
> On Thu, Feb 14, 2013 at 01:26:42PM +0100, Laurent Pinchart wrote:
>> Hi Magnus,
>>
>> Thanks for the patch.
>>
>> On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
>> > From: Magnus Damm <damm@opensource.se>
>> >
>> > Fix sizeof() usage in sh-pfc/core.c to allocate space
>> > for the full data structure instead of a pointer.
>>
>> Oops :-)
>>
>> This is v3.9 material. Simon, could you please take this and push it upstream
>> for v3.9 ?
>
> Sure, will do.

Thanks.

/ magnus

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
                   ` (4 preceding siblings ...)
  2013-02-15  1:47 ` Magnus Damm
@ 2013-02-15 19:46 ` Linus Walleij
  2013-02-16  6:14 ` Simon Horman
  6 siblings, 0 replies; 10+ messages in thread
From: Linus Walleij @ 2013-02-15 19:46 UTC (permalink / raw)
  To: linux-sh

On Thu, Feb 14, 2013 at 1:23 PM, Magnus Damm <magnus.damm@gmail.com> wrote:

> From: Magnus Damm <damm@opensource.se>
>
> Fix sizeof() usage in sh-pfc/core.c to allocate space
> for the full data structure instead of a pointer.
>
> Signed-off-by: Magnus Damm <damm@opensource.se>

Acked-by: Linus Walleij <linus.walleij@linaro.org>

Thanks!
Linus Walleij

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
                   ` (5 preceding siblings ...)
  2013-02-15 19:46 ` Linus Walleij
@ 2013-02-16  6:14 ` Simon Horman
  6 siblings, 0 replies; 10+ messages in thread
From: Simon Horman @ 2013-02-16  6:14 UTC (permalink / raw)
  To: linux-sh

On Thu, Feb 14, 2013 at 01:27:51PM +0100, Laurent Pinchart wrote:
> On Thursday 14 February 2013 21:23:47 Magnus Damm wrote:
> > From: Magnus Damm <damm@opensource.se>
> > 
> > Fix sizeof() usage in sh-pfc/core.c to allocate space
> > for the full data structure instead of a pointer.
> > 
> > Signed-off-by: Magnus Damm <damm@opensource.se>
> 
> Forgot to add my
> 
> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

[snip]

On Fri, Feb 15, 2013 at 08:46:18PM +0100, Linus Walleij wrote:
> On Thu, Feb 14, 2013 at 1:23 PM, Magnus Damm <magnus.damm@gmail.com> wrote:
> 
> > From: Magnus Damm <damm@opensource.se>
> >
> > Fix sizeof() usage in sh-pfc/core.c to allocate space
> > for the full data structure instead of a pointer.
> >
> > Signed-off-by: Magnus Damm <damm@opensource.se>
> 
> Acked-by: Linus Walleij <linus.walleij@linaro.org>


Thanks. I have added the Acked-by lines and sent a pull-request
to arm-soc to have it included in 3.9.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
  2013-02-16  2:25 GIT PULL] Renesas ARM-based SoC pinmux for v3.9 #2 Simon Horman
@ 2013-02-16  2:25   ` Simon Horman
  0 siblings, 0 replies; 10+ messages in thread
From: Simon Horman @ 2013-02-16  2:25 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Fix sizeof() usage in sh-pfc/core.c to allocate space
for the full data structure instead of a pointer.

Signed-off-by: Magnus Damm <damm@opensource.se>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 drivers/pinctrl/sh-pfc/core.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pinctrl/sh-pfc/core.c b/drivers/pinctrl/sh-pfc/core.c
index d323c24f..970ddff 100644
--- a/drivers/pinctrl/sh-pfc/core.c
+++ b/drivers/pinctrl/sh-pfc/core.c
@@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_device *pdev)
 	if (info = NULL)
 		return -ENODEV;
 
-	pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
+	pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
 	if (pfc = NULL)
 		return -ENOMEM;
 
-- 
1.7.10.4


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix
@ 2013-02-16  2:25   ` Simon Horman
  0 siblings, 0 replies; 10+ messages in thread
From: Simon Horman @ 2013-02-16  2:25 UTC (permalink / raw)
  To: linux-arm-kernel

From: Magnus Damm <damm@opensource.se>

Fix sizeof() usage in sh-pfc/core.c to allocate space
for the full data structure instead of a pointer.

Signed-off-by: Magnus Damm <damm@opensource.se>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 drivers/pinctrl/sh-pfc/core.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pinctrl/sh-pfc/core.c b/drivers/pinctrl/sh-pfc/core.c
index d323c24f..970ddff 100644
--- a/drivers/pinctrl/sh-pfc/core.c
+++ b/drivers/pinctrl/sh-pfc/core.c
@@ -495,7 +495,7 @@ static int sh_pfc_probe(struct platform_device *pdev)
 	if (info == NULL)
 		return -ENODEV;
 
-	pfc = devm_kzalloc(&pdev->dev, sizeof(pfc), GFP_KERNEL);
+	pfc = devm_kzalloc(&pdev->dev, sizeof(*pfc), GFP_KERNEL);
 	if (pfc == NULL)
 		return -ENOMEM;
 
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2013-02-16  6:14 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-14 12:23 [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Magnus Damm
2013-02-14 12:26 ` Laurent Pinchart
2013-02-14 12:27 ` Magnus Damm
2013-02-14 12:27 ` Laurent Pinchart
2013-02-14 15:56 ` Simon Horman
2013-02-15  1:47 ` Magnus Damm
2013-02-15 19:46 ` Linus Walleij
2013-02-16  6:14 ` Simon Horman
2013-02-16  2:25 GIT PULL] Renesas ARM-based SoC pinmux for v3.9 #2 Simon Horman
2013-02-16  2:25 ` [PATCH] sh-pfc: sh_pfc_probe() sizeof() fix Simon Horman
2013-02-16  2:25   ` Simon Horman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.