From: Gerlando Falauto Date: Wed, 23 Jan 2013 13:50:59 +0000 (+0100) Subject: arm: plat-orion: fix printing of "MPP config unavailable on this hardware" X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=830f8b91;p=linux-beck.git arm: plat-orion: fix printing of "MPP config unavailable on this hardware" refactored printing of the kernel warning: "orion_mpp_conf: requested MPP%u config unavailable on this hardware\n" which is not to be printed in case of variant_mask = 0 (unknown variant). This check should be performed using a logical AND (&&) as opposed to a bitwise AND (&). Otherwise, test would fail (and message would not be printed) if variant_mask != 1 Signed-off-by: Gerlando Falauto Cc: Andrew Lunn Cc: Olof Johansson Cc: Nicolas Pitre Cc: Holger Brunck Acked-by: Andrew Lunn Signed-off-by: Jason Cooper --- diff --git a/arch/arm/plat-orion/mpp.c b/arch/arm/plat-orion/mpp.c index e686fe76a96b..7310bcfb299f 100644 --- a/arch/arm/plat-orion/mpp.c +++ b/arch/arm/plat-orion/mpp.c @@ -49,7 +49,7 @@ void __init orion_mpp_conf(unsigned int *mpp_list, unsigned int variant_mask, "number (%u)\n", num); continue; } - if (variant_mask & !(*mpp_list & variant_mask)) { + if (variant_mask && !(*mpp_list & variant_mask)) { printk(KERN_WARNING "orion_mpp_conf: requested MPP%u config " "unavailable on this hardware\n", num);