Skip to content
Commit dd7d2b05 authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Paul Gortmaker
Browse files

ubifs: Fix ino_t format warnings in orphan_delete()



commit 155fc6ba upstream.

On alpha and s390x:

    fs/ubifs/debug.h:158:11: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘ino_t {aka unsigned int}’ [-Wformat=]
    ...
    fs/ubifs/orphan.c:132:3: note: in expansion of macro ‘dbg_gen’
       dbg_gen("deleted twice ino %lu", orph->inum);
    ...
    fs/ubifs/orphan.c:140:3: note: in expansion of macro ‘dbg_gen’
       dbg_gen("delete later ino %lu", orph->inum);

__kernel_ino_t is "unsigned long" on most architectures, but not on
alpha and s390x, where it is "unsigned int".  Hence when printing an
ino_t, it should always be cast to "unsigned long" first.

Fix this by re-adding the recently removed casts.

Fixes: 8009ce95 ("ubifs: Don't leak orphans on memory during commit")
Signed-off-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
Signed-off-by: default avatarPaul Gortmaker <paul.gortmaker@windriver.com>
parent cc4f717a
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment