Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 17 Feb 2018 01:42:15 +0100
From:      Jan Beich <jbeich@FreeBSD.org>
To:        Hans Petter Selasky <hselasky@FreeBSD.org>
Cc:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r329371 - head/sys/compat/linuxkpi/common/include/asm
Message-ID:  <mv08-30rc-wny@FreeBSD.org>
In-Reply-To: <201802161520.w1GFKLiA049085@repo.freebsd.org> (Hans Petter Selasky's message of "Fri, 16 Feb 2018 15:20:21 %2B0000 (UTC)")
References:  <201802161520.w1GFKLiA049085@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hans Petter Selasky <hselasky@FreeBSD.org> writes:

> Author: hselasky
> Date: Fri Feb 16 15:20:21 2018
> New Revision: 329371
> URL: https://svnweb.freebsd.org/changeset/base/329371
>
> Log:
>   Allow the cmpxchg() macro in the LinuxKPI to work on pointers without
>   generating compiler warnings, -Wint-conversion .
[...]

To generate errors instead ?

$ make clean all -C /usr/ports/graphics/drm-next-kmod
[...]
drm_lock.c:72:10: error: flexible array member 'u8' in a union is not allowed
                prev = cmpxchg(lock, old, new);
                       ^
/usr/src/sys/compat/linuxkpi/common/include/asm/atomic.h:165:6: note: expanded from macro 'cmpxchg'
                u8 u8[];                                                \
                   ^
drm_lock.c:72:10: error: flexible array member 'u16' in a union is not allowed
/usr/src/sys/compat/linuxkpi/common/include/asm/atomic.h:166:7: note: expanded from macro 'cmpxchg'
                u16 u16[];                                              \
                    ^
drm_lock.c:72:10: error: flexible array member 'u32' in a union is not allowed
/usr/src/sys/compat/linuxkpi/common/include/asm/atomic.h:167:7: note: expanded from macro 'cmpxchg'
                u32 u32[];                                              \
                    ^
drm_lock.c:72:10: error: flexible array member 'u64' in a union is not allowed
/usr/src/sys/compat/linuxkpi/common/include/asm/atomic.h:168:7: note: expanded from macro 'cmpxchg'
                u64 u64[];                                              \
                    ^



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?mv08-30rc-wny>