lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 12 Dec 2018 10:50:42 +0100
From:   Daniel Borkmann <daniel@...earbox.net>
To:     Stanislav Fomichev <sdf@...gle.com>, netdev@...r.kernel.org
Cc:     davem@...emloft.net, ast@...nel.org
Subject: Re: [PATCH v2 bpf-next] selftests/bpf: use __bpf_constant_htons in
 test_prog.c

On 12/12/2018 04:20 AM, Stanislav Fomichev wrote:
> For some reason, my older GCC (< 4.8) isn't smart enough to optimize the
> !__builtin_constant_p() branch in bpf_htons, I see:
>   error: implicit declaration of function '__builtin_bswap16'
> 
> Let's use __bpf_constant_htons as suggested by Daniel Borkmann.
> 
> I tried to use simple htons, but it produces the following:
>   test_progs.c:54:17: error: braced-group within expression allowed only
>   inside a function
>     .eth.h_proto = htons(ETH_P_IP),
> 
> Signed-off-by: Stanislav Fomichev <sdf@...gle.com>

Applied, thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ