NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

port-macppc/56205: macppc / powerpc64: sys/arch/macppc/stand/ofwboot/ofdev.c:106:13: error: cast from pointer to integer of different size



>Number:         56205
>Category:       port-macppc
>Synopsis:       macppc / powerpc64: sys/arch/macppc/stand/ofwboot/ofdev.c:106:13: error: cast from pointer to integer of different size
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-macppc-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon May 24 09:10:00 +0000 2021
>Originator:     Jan-Benedict Glaw
>Release:        HEAD (github mirror, as of b686e1ed10a42c901b5c9f08078aeddc8b9a51bf)
>Organization:
>Environment:
Linux spock 5.10.0-3-amd64 #1 SMP Debian 5.10.13-1 (2021-02-06) x86_64 GNU/Linux
>Description:
Hi!

I'm doing mass builds right now (Toolchain, NetBSD, Linux kernel, ...) and found an issue with the Open Firmware support. Host GCC is Debian's "gcc-snapshot":

/usr/lib/gcc-snapshot/bin/gcc --version
gcc (Debian 20210508-1) 12.0.0 20210508 (experimental) [master revision 292da5c58da:d8763feb89a:62d87a321b29f9febdacc6220367021d98db3057]
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO 
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


Build is done as:

./build.sh -P -U -m macppc -a powerpc64 tools
./build.sh -P -U -u -m macppc -a powerpc64 release

[bld rels 2021-05-24 05:58:00] #   compile  ofwboot/ofdev.o
[bld rels 2021-05-24 05:58:00] /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/obj/tooldir.Linux-5.10.0-3-amd64-x86_64/bin/powerpc64--netbsd-gcc -Os -ffreestanding  -msoft-float  -fno-unwind-tables -fno-asynchronous-unwind-tables -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith    -fdebug-prefix-map=\$DESTDIR= -fdebug-prefix-map=\$NETBSDSRCDIR=/usr/src -fdebug-prefix-map=\$X11SRCDIR=/usr/xsrc -fdebug-regex-map='/usr/src/(.*)/obj$=/usr/obj/\1' -fdebug-regex-map='/usr/src/(.*)/obj/(.*)=/usr/obj/\1/\2' -fdebug-regex-map='/usr/src/(.*)/obj\..*=/usr/obj/\1' -fdebug-regex-map='/usr/src/(.*)/obj\..*/(.*)=/usr/obj/\1/\2'   -std=gnu99   -Werror  -Wno-address-of-packed-member     -D_STANDALONE -DSUPPORT_DHCP -DSUPPORT_USTARFS -DHAVE_CHANGEDISK_HOOK --sysroot=/var/lib/laminar/run/netbsd-macppc-powerpc64/2/dest-macppc-powerpc64 -I. -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/Net
 BSD-src/sys/arch/macppc/stand/ofwboot/../../.. -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../.. -DRELOC=0xE00000 -DRELOC_FLATFILE=0x -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/quad -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/string -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/arch/powerpc64/string -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/arch/powerpc64/atomic -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/hash/sha3 -Wp,-iremap,/var/lib/laminar/run/netbsd-macppc-pow
 erpc64/2/dest-macppc-powerpc64: -Wp,-fno-canonical-system-headers -Wp,-iremap,/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src:/usr/src -Wp,-iremap,/usr/xsrc:/usr/xsrc  -c    /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c -o ofdev.o
[bld rels 2021-05-24 05:58:00] /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c: In function 'devclose':
[bld rels 2021-05-24 05:58:00] /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c:106:13: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast]
[bld rels 2021-05-24 05:58:00]   106 |  cells[0] = (uint32_t)op->dmabuf;
[bld rels 2021-05-24 05:58:00]       |             ^
[bld rels 2021-05-24 05:58:00] /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c: In function 'devopen':
[bld rels 2021-05-24 05:58:00] /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c:442:17: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast]
[bld rels 2021-05-24 05:58:00]   442 |  ofdev.dmabuf = (void *)cells[1];
[bld rels 2021-05-24 05:58:00]       |                 ^
[bld rels 2021-05-24 05:58:01] cc1: all warnings being treated as errors
[bld rels 2021-05-24 05:58:01] 
[bld rels 2021-05-24 05:58:01] *** Failed target:  ofdev.o
[bld rels 2021-05-24 05:58:01] *** Failed command: /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/obj/tooldir.Linux-5.10.0-3-amd64-x86_64/bin/powerpc64--netbsd-gcc -Os -ffreestanding -msoft-float -fno-unwind-tables -fno-asynchronous-unwind-tables -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -fdebug-prefix-map=\$DESTDIR= -fdebug-prefix-map=\$NETBSDSRCDIR=/usr/src -fdebug-prefix-map=\$X11SRCDIR=/usr/xsrc -fdebug-regex-map='/usr/src/(.*)/obj$=/usr/obj/\1' -fdebug-regex-map='/usr/src/(.*)/obj/(.*)=/usr/obj/\1/\2' -fdebug-regex-map='/usr/src/(.*)/obj\..*=/usr/obj/\1' -fdebug-regex-map='/usr/src/(.*)/obj\..*/(.*)=/usr/obj/\1/\2' -std=gnu99 -Werror -Wno-address-of-packed-member -D_STANDALONE -DSUPPORT_DHCP -DSUPPORT_USTARFS -DHAVE_CHANGEDISK_HOOK --sysroot=/var/lib/laminar/run/netbsd-macppc-powerpc64/2/dest-macppc-powerpc64 -I. -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot -I/var/lib/laminar/run/netbsd-macppc-powerpc64
 /2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../.. -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../.. -DRELOC=0xE00000 -DRELOC_FLATFILE=0x -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/quad -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/string -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/arch/powerpc64/string -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/arch/powerpc64/atomic -I/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/../../../../lib/libkern/../../../common/lib/libc/hash/sha3 -Wp,-iremap,/var/lib/laminar/run/netbsd-macp
 pc-powerpc64/2/dest-macppc-powerpc64: -Wp,-fno-canonical-system-headers -Wp,-iremap,/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src:/usr/src -Wp,-iremap,/usr/xsrc:/usr/xsrc -c /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot/ofdev.c -o ofdev.o
[bld rels 2021-05-24 05:58:01] *** Error code 1
[bld rels 2021-05-24 05:58:01] 
[bld rels 2021-05-24 05:58:01] Stop.
[bld rels 2021-05-24 05:58:01] nbmake[10]: stopped in /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot
[bld rels 2021-05-24 05:58:01] 
[bld rels 2021-05-24 05:58:01] *** Failed target:  dependall
[bld rels 2021-05-24 05:58:01] *** Failed command: cd "/var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/sys/arch/macppc/stand/ofwboot"; /var/lib/laminar/run/netbsd-macppc-powerpc64/2/NetBSD-src/obj/tooldir.Linux-5.10.0-3-amd64-x86_64/bin/nbmake realall
[bld rels 2021-05-24 05:58:01] *** Error code 1


Full build log is available at https://lug-owl.de/~jbglaw/laminar/netbsd-macppc-powerpc64-2

>How-To-Repeat:

>Fix:



Home | Main Index | Thread Index | Old Index