[U-Boot] [PATCH 2/2] ext4: Fix unused variable warnings

Simon Glass sjg at chromium.org
Thu Oct 4 02:32:04 CEST 2012


Hi,

On Wed, Oct 3, 2012 at 12:53 PM, Simon Glass <sjg at chromium.org> wrote:
> This patch fixes the following warnings with my gcc 4.6:
>
> ext4fs.c:932:6: error: variable 'delayed_skipfirst' set but not used [-Werror=unused-but-set-variable]
> ext4_common.c:381:8: error: variable 'ptr' set but not used [-Werror=unused-but-set-variable]
> ext4_common.c:1170:8: error: variable 'status' set but not used [-Werror=unused-but-set-variable]
>
> I'm not exactly sure whether this is the best fix, but it did look like
> each variable is actually needed.
>
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
>  common/cmd_ext4.c      |    2 +-
>  fs/ext4/ext4_common.c  |    7 ++++---
>  fs/ext4/ext4_journal.c |    4 ++--
>  fs/ext4/ext4fs.c       |    1 +
>  4 files changed, 8 insertions(+), 6 deletions(-)
>

Actually I think this problem was due to a broken toolchain, which
helps explain why I couldn't work out what the compiler was
complaining about. I think we should ignore this patch unless others
also see it. Sorry for the distraction.

Regards,
Simon


More information about the U-Boot mailing list