From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Vrabel Subject: Re: [PATCH 2/3] public/io/netif.h: document control ring and toeplitz hashing Date: Mon, 4 Jan 2016 11:18:06 +0000 Message-ID: <568A54EE.4010605@citrix.com> References: <1450865195-12883-1-git-send-email-paul.durrant@citrix.com> <1450865195-12883-3-git-send-email-paul.durrant@citrix.com> <567AA148.4070207@citrix.com> <9AAE0902D5BC7E449B7C8E4E778ABCD02F711A79@AMSPEX01CL01.citrite.net> <568A4FB8.7070100@citrix.com> <9AAE0902D5BC7E449B7C8E4E778ABCD02F712179@AMSPEX01CL01.citrite.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aG39S-0000Sp-O2 for xen-devel@lists.xenproject.org; Mon, 04 Jan 2016 11:18:14 +0000 In-Reply-To: <9AAE0902D5BC7E449B7C8E4E778ABCD02F712179@AMSPEX01CL01.citrite.net> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Paul Durrant , "xen-devel@lists.xenproject.org" Cc: "Keir (Xen.org)" , "Tim (Xen.org)" , Ian Campbell , Jan Beulich , Ian Jackson List-Id: xen-devel@lists.xenproject.org On 04/01/16 11:14, Paul Durrant wrote: >>>> You should use the standard ring format and infrastructure. >>> >>> Is there one for variable message size rings? I didn't find one. I >>> don't want to use the fixed size balanced ring macros for control >>> messages as fixed size messages really aren't appropriate in this case. >> >> Perhaps union the request/response message types with a uint8_t >> pad[1024] and use this as the request/response type? >> > > The problem is that this places a 1k limit on the message size, > which > is not there in the scheme I'm proposing. I'd rather not bake that limit > in if I don't have to. >>>>> + * | req[1024] | ^^^^^^^^^ Surely this limits your size to 1024 bytes? Also if you need bigger messages you can grant those areas separately and pass a grant ref through the ring, or you can chunk the message to fit in several requests/responses. David