From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnaldo Carvalho de Melo Subject: Re: [PATCH] libbpf: Fix up generation of bpf_helper_defs.h Date: Wed, 27 Nov 2019 22:17:46 -0300 Message-ID: <58CA150B-D006-48DF-A279-077BA2FFD6EC@kernel.org> References: <87imn6y4n9.fsf@toke.dk> <20191126183451.GC29071@kernel.org> <87d0dexyij.fsf@toke.dk> <20191126190450.GD29071@kernel.org> <20191126221018.GA22719@kernel.org> <20191126221733.GB22719@kernel.org> <20191126231030.GE3145429@mini-arch.hsd1.ca.comcast.net> <20191126155228.0e6ed54c@cakuba.netronome.com> <20191127013901.GE29071@kernel.org> <2993CDB0-8D4D-4A0C-9DB2-8FDD1A0538AB@kernel.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: Sender: netdev-owner@vger.kernel.org To: Alexei Starovoitov , Arnaldo Carvalho de Melo Cc: Jakub Kicinski , Stanislav Fomichev , Andrii Nakryiko , =?ISO-8859-1?Q?Toke_H=F8iland-J=F8rgensen?= , Andrii Nakryiko , Adrian Hunter , Alexei Starovoitov , Daniel Borkmann , Jiri Olsa , Martin KaFai Lau , Namhyung Kim , bpf , Networking , linux-perf-users@vger.kernel.org, Linux Kernel Mailing List , Quentin Monnet List-Id: linux-perf-users.vger.kernel.org On November 27, 2019 9:59:15 PM GMT-03:00, Alexei Starovoitov wrote: >On Wed, Nov 27, 2019 at 4:50 PM Arnaldo Carvalho de Melo > wrote: >> >> Take it as one, I think it's what should have been in the cset it is >fixing, that way no breakage would have happened=2E > >Ok=2E I trimmed commit log and applied here: >https://git=2Ekernel=2Eorg/pub/scm/linux/kernel/git/bpf/bpf=2Egit/commit/= ?id=3D1fd450f99272791df8ea8e1b0f5657678e118e90 > >What about your other fix and my suggestion there? >(__u64) cast instead of PRI ? >We do this already in two places: >libbpf=2Ec: shdr_idx, (__u64)sym->st_value); >libbpf=2Ec: (__u64)sym=2Est_value, GELF_ST_TYPE(sym=2Est_info= ), I'm using the smartphone now, but I thought you first suggested using a ca= st to long, if you mean using %llu + cast to __u64, then should be was ugly= as using PRI, IOW, should work on both 64 bit and 32 bit=2E :-) - Arnaldo