From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33833) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zr2rZ-0007BJ-7v for qemu-devel@nongnu.org; Tue, 27 Oct 2015 07:56:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zr2rW-0004Cy-1G for qemu-devel@nongnu.org; Tue, 27 Oct 2015 07:56:25 -0400 Received: from mout.kundenserver.de ([212.227.126.131]:53358) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zr2rV-0004Cs-RQ for qemu-devel@nongnu.org; Tue, 27 Oct 2015 07:56:21 -0400 References: <1444151509-5047-1-git-send-email-laurent@vivier.eu> <562EEAD4.7070706@vivier.eu> <562F564A.5040902@vivier.eu> <562F64C9.3050100@vivier.eu> From: Laurent Vivier Message-ID: <562F6663.8050505@vivier.eu> Date: Tue, 27 Oct 2015 12:56:19 +0100 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] [PATCH] linux-user: manage SOCK_PACKET socket type. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Riku Voipio , QEMU Developers Le 27/10/2015 12:52, Peter Maydell a écrit : > On 27 October 2015 at 11:49, Laurent Vivier wrote: >> >> >> Le 27/10/2015 12:39, Peter Maydell a écrit : >>> On 27 October 2015 at 11:35, Peter Maydell wrote: >>>> Still thinking about the other part of your patch, because >>>> "does this start with 'eth'" is not very pretty... >> >> I agree with you, but I didn't find better. >> >>> ...can we use the TargetFdTrans machinery from your signalfd >>> patch to associate custom sockaddr conversion functions with >>> a file descriptor if it's created via socket(PF_PACKET, SOCK_PACKET, ...)? >> >> It was my first idea, but it didn't fit well: this machinery is to >> translate data (recv/send), not the parameters, but as you say we can >> add some functions in the structure. I'll have a look at this. > > Yes, now we have a generic "special case magic for an fd" we can > start to use it for a wider set of things. > > You might want to separate the "fix the protocol value in socket() > calls" change into a different patch from the "fix the sockaddr > conversion" change (since the former is easy to review now) -- > up to you. Lets go for two patches... Laurent