linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drivers: of: removing assignment of 0 to static variable
@ 2015-10-27  3:42 Saurabh Sengar
  2015-10-30 18:30 ` Rob Herring
  0 siblings, 1 reply; 2+ messages in thread
From: Saurabh Sengar @ 2015-10-27  3:42 UTC (permalink / raw)
  To: robh+dt, frowand.list, grant.likely, devicetree, linux-kernel
  Cc: Saurabh Sengar

no need to initialise static variable with 0, hence correcting it.

Signed-off-by: Saurabh Sengar <saurabh.truth@gmail.com>
---
 drivers/of/fdt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index 6e82bc42..63699dd 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -184,7 +184,7 @@ static void * unflatten_dt_node(const void *blob,
 	struct property *pp, **prev_pp = NULL;
 	const char *pathp;
 	unsigned int l, allocl;
-	static int depth = 0;
+	static int depth;
 	int old_depth;
 	int offset;
 	int has_name = 0;
-- 
1.9.1


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

* Re: [PATCH] drivers: of: removing assignment of 0 to static variable
  2015-10-27  3:42 [PATCH] drivers: of: removing assignment of 0 to static variable Saurabh Sengar
@ 2015-10-30 18:30 ` Rob Herring
  0 siblings, 0 replies; 2+ messages in thread
From: Rob Herring @ 2015-10-30 18:30 UTC (permalink / raw)
  To: Saurabh Sengar; +Cc: Frank Rowand, Grant Likely, devicetree, linux-kernel

On Mon, Oct 26, 2015 at 10:42 PM, Saurabh Sengar
<saurabh.truth@gmail.com> wrote:
> no need to initialise static variable with 0, hence correcting it.
>
> Signed-off-by: Saurabh Sengar <saurabh.truth@gmail.com>

Applied. Thanks.

Rob

> ---
>  drivers/of/fdt.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
> index 6e82bc42..63699dd 100644
> --- a/drivers/of/fdt.c
> +++ b/drivers/of/fdt.c
> @@ -184,7 +184,7 @@ static void * unflatten_dt_node(const void *blob,
>         struct property *pp, **prev_pp = NULL;
>         const char *pathp;
>         unsigned int l, allocl;
> -       static int depth = 0;
> +       static int depth;
>         int old_depth;
>         int offset;
>         int has_name = 0;
> --
> 1.9.1
>

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

end of thread, other threads:[~2015-10-30 18:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-27  3:42 [PATCH] drivers: of: removing assignment of 0 to static variable Saurabh Sengar
2015-10-30 18:30 ` Rob Herring

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).