diff options
author | James Clark <james.clark@arm.com> | 2023-11-01 11:52:06 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-01-20 11:50:11 +0100 |
commit | 5e67191818fe9b3d65925749bd9b28bc6c6d08f8 (patch) | |
tree | 29e8267ec2a33973b7d28a9325ada9d287c7f14b /arch/cris/arch-v10/kernel/debugport.c | |
parent | d08e756e253b12943b43c11d30e91368879d968b (diff) | |
download | linux-stable-5e67191818fe9b3d65925749bd9b28bc6c6d08f8.tar.gz linux-stable-5e67191818fe9b3d65925749bd9b28bc6c6d08f8.tar.bz2 linux-stable-5e67191818fe9b3d65925749bd9b28bc6c6d08f8.zip |
coresight: etm4x: Fix width of CCITMIN field
commit cc0271a339cc70cae914c3ec20edc2a8058407da upstream.
CCITMIN is a 12 bit field and doesn't fit in a u8, so extend it to u16.
This probably wasn't an issue previously because values higher than 255
never occurred.
But since commit 4aff040bcc8d ("coresight: etm: Override TRCIDR3.CCITMIN
on errata affected cpus"), a comparison with 256 was done to enable the
errata, generating the following W=1 build error:
coresight-etm4x-core.c:1188:24: error: result of comparison of
constant 256 with expression of type 'u8' (aka 'unsigned char') is
always false [-Werror,-Wtautological-constant-out-of-range-compare]
if (drvdata->ccitmin == 256)
Cc: stable@vger.kernel.org
Fixes: 2e1cdfe184b5 ("coresight-etm4x: Adding CoreSight ETM4x driver")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202310302043.as36UFED-lkp@intel.com/
Reviewed-by: Mike Leach <mike.leach@linaro.org>
Signed-off-by: James Clark <james.clark@arm.com>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Link: https://lore.kernel.org/r/20231101115206.70810-1-james.clark@arm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/cris/arch-v10/kernel/debugport.c')
0 files changed, 0 insertions, 0 deletions