From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754280AbbFVGxJ (ORCPT ); Mon, 22 Jun 2015 02:53:09 -0400 Received: from a.ns.miles-group.at ([95.130.255.143]:65275 "EHLO radon.swed.at" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752521AbbFVGw7 (ORCPT ); Mon, 22 Jun 2015 02:52:59 -0400 Message-ID: <5587B0C7.8090507@nod.at> Date: Mon, 22 Jun 2015 08:52:55 +0200 From: Richard Weinberger User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Alexei Starovoitov , Nicolai Stange CC: "David S. Miller" , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, daniel@iogearbox.net Subject: Re: [PATCH] lib: test_bpf: purge CPP register redefinitions References: <87twu0df3k.fsf@gmail.com> <20150622060523.GA16156@Alexeis-MacBook-Pro.local> In-Reply-To: <20150622060523.GA16156@Alexeis-MacBook-Pro.local> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Am 22.06.2015 um 08:05 schrieb Alexei Starovoitov: > to get rid of warning you proposing to do 1k line renames?! > Just add: > +#undef R8 > +#undef R9 > +#undef R10 > #define R0 BPF_REG_0 This would be also just another hack. > Though I think the better fix woud be to clean up: > arch/x86/include/uapi/asm/ptrace-abi.h > What's the point of: > #define R8 72 > from 'uapi' point of view? To query cpu registers using ptrace(2). > Look like kernel details that shouldn't be exposed in uapi. These are not kernel details. Actually the problem is the other way around. UML is Linux ported to it's own userspace ABI. Hence, the arch/um and arch/x86/um use uapi header files. Maybe we can rework UML's header files such that no uapi header pollutes the kernel namespace. That said, lib/test_bpf.c should still not use defines like R8 as such symbols are very generic. Thanks, //richard -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in Please read the FAQ at http://www.tux.org/lkml/