]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
switch-3.c: Fix llp64 warnings
authorJonathan Yong <10walls@gmail.com>
Wed, 2 Apr 2025 11:18:21 +0000 (11:18 +0000)
committerJonathan Yong <10walls@gmail.com>
Wed, 2 Apr 2025 11:22:24 +0000 (11:22 +0000)
mtrr_ioctl() uses long and casts it to a pointer. Fix warnings
for llp64 platforms.

Signed-off-by: Jonathan Yong <10walls@gmail.com>
gcc/testsuite/ChangeLog:

* gcc.dg/analyzer/torture/switch-3.c: Fix llp64 warnings.

gcc/testsuite/gcc.dg/analyzer/torture/switch-3.c

index 57b8acdb29290b09083c45602baeefc179e49b84..b40be664d3892e0a11836277fbf8b4f60c6a13e4 100644 (file)
@@ -68,7 +68,7 @@ extern void check_init_u32 (__u32 v);
 /* Adapted/reduced from arch/x86/kernel/cpu/mtrr/if.c: mtrr_ioctl,
    which is GPL-2.0  */
 
-long mtrr_ioctl(unsigned int cmd, unsigned long __arg) {
+long mtrr_ioctl(unsigned int cmd, __UINTPTR_TYPE__ __arg) {
   int err = 0;
   struct mtrr_sentry sentry;
   struct mtrr_gentry gentry;