Skip to content
Commit 014704e6 authored by Dan Carpenter's avatar Dan Carpenter Committed by Michael Ellerman
Browse files

powerpc: Fix signedness bug in update_flash_db()



The "count < sizeof(struct os_area_db)" comparison is type promoted to
size_t so negative values of "count" are treated as very high values
and we accidentally return success instead of a negative error code.

This doesn't really change runtime much but it fixes a static checker
warning.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Acked-by: default avatarGeoff Levand <geoff@infradead.org>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 6233b6da
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