From mboxrd@z Thu Jan 1 00:00:00 1970 From: Konrad Rzeszutek Wilk Subject: Re: [PATCH v3 13/23] XENVER_build_id: Provide ld-embedded build-ids (v10) Date: Tue, 16 Feb 2016 15:22:58 -0500 Message-ID: <20160216202258.GH17937@char.us.oracle.com> References: <1455300361-13092-1-git-send-email-konrad.wilk@oracle.com> <1455300361-13092-14-git-send-email-konrad.wilk@oracle.com> <56C381E9.7030002@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <56C381E9.7030002@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: Wei Liu , Ian Campbell , jinsong.liu@alibaba-inc.com, Stefano Stabellini , Ian Jackson , xen-devel@lists.xen.org, mpohlack@amazon.de, ross.lagerwall@citrix.com, Stefano Stabellini , Jan Beulich , xen-devel@lists.xenproject.org, Daniel De Graaf , Keir Fraser , sasha.levin@citrix.com List-Id: xen-devel@lists.xenproject.org On Tue, Feb 16, 2016 at 08:09:13PM +0000, Andrew Cooper wrote: > On 12/02/16 18:05, Konrad Rzeszutek Wilk wrote: > > Building the hypervisor with buildid and making it available via > hypercall really should be split into two different patches, especially > given the complexity in each. OK, will do. .. snip.. > > +/* Return value is the number of bytes written, or XEN_Exx on error. > > + * Calling with empty parameter returns the size of build_id. */ > > +#define XENVER_build_id 10 > > +struct xen_build_id { > > + uint32_t len; /* IN: size of buf[]. */ > > +#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L > > + unsigned char buf[]; > > +#elif defined(__GNUC__) > > + unsigned char buf[1]; /* OUT: Variable length buffer with build_id. */ > > +#endif > > +}; > > +typedef struct xen_build_id xen_build_id_t; > > I am still against trying to perpetuate this broken interface. Variable > length structures are a pain for everyone to use. How about introducing > a brand new hypercall with a separate length and data parameters? As in subop to sysctl? I am fine with that (which is what I think was in the first iteration of this patch had). Or it could go under the XSPLICE subops :-) Preferences? > > ~Andrew