From: Alex Elder Date: Wed, 2 Dec 2020 14:15:02 +0000 (-0600) Subject: net: ipa: fix build-time bug in ipa_hardware_config_qsb() X-Git-Tag: accepted/tizen/unified/20230118.172025~8321^2~132 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9693e08f2814e37fce6941b140294eeb8e785375;p=platform%2Fkernel%2Flinux-rpi.git net: ipa: fix build-time bug in ipa_hardware_config_qsb() Jon Hunter reported observing a build bug in the IPA driver: https://lore.kernel.org/netdev/5b5d9d40-94d5-5dad-b861-fd9bef8260e2@nvidia.com The problem is that the QMB0 max read value set for IPA v4.5 (16) is too large to fit in the 4-bit field. The actual value we want is 0, which requests that the hardware use the maximum it is capable of. Reported-by: Jon Hunter Tested-by: Jon Hunter Signed-off-by: Alex Elder Link: https://lore.kernel.org/r/20201202141502.21265-1-elder@linaro.org Signed-off-by: Jakub Kicinski --- diff --git a/drivers/net/ipa/ipa_main.c b/drivers/net/ipa/ipa_main.c index d076845..84bb8ae 100644 --- a/drivers/net/ipa/ipa_main.c +++ b/drivers/net/ipa/ipa_main.c @@ -288,7 +288,7 @@ static void ipa_hardware_config_qsb(struct ipa *ipa) max1 = 0; /* PCIe not present */ break; case IPA_VERSION_4_5: - max0 = 16; + max0 = 0; /* No limit (hardware maximum) */ break; } val = u32_encode_bits(max0, GEN_QMB_0_MAX_READS_FMASK);