Re: [PATCH] drivers: Initialize ret to fix build warning in memory_probe_store

From: Liu Yuan
Date: Sat Mar 26 2011 - 03:49:51 EST


Cc: Nathan Fontenot <nfont@xxxxxxxxxxxxxx>

On Wed, Mar 23, 2011 at 8:45 PM, Liu Yuan <namei.unix@xxxxxxxxx> wrote:
> From: Liu Yuan <tailai.ly@xxxxxxxxxx>
>
> This fix a build warning in drivers/base/memory.c.
>
> Cc: Greg Kroah-Hartman <gregkh@xxxxxxx>
> Signed-off-by: Liu Yuan <tailai.ly@xxxxxxxxxx>
> ---
> Âdrivers/base/memory.c | Â Â2 +-
> Â1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/base/memory.c b/drivers/base/memory.c
> index 3da6a43..f2ac71f 100644
> --- a/drivers/base/memory.c
> +++ b/drivers/base/memory.c
> @@ -387,7 +387,7 @@ memory_probe_store(struct class *class, struct class_attribute *attr,
> Â{
> Â Â Â Âu64 phys_addr;
> Â Â Â Âint nid;
> - Â Â Â int i, ret;
> + Â Â Â int i, ret = 0;
>
> Â Â Â Âphys_addr = simple_strtoull(buf, NULL, 0);
>
> --
> 1.7.0.4
>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/