From: Ian Jackson Subject: Re: [PATCH v3 2/3] XENVER_build_id: Provide ld-embedded build-ids (v8) Date: Wed, 17 Feb 2016 11:37:24 +0000 Message-ID: <22212.23412.397272.403726@mariner.uk.xensource.com> References: <1452219920-14043-1-git-send-email-konrad.wilk@oracle.com> <1452219920-14043-3-git-send-email-konrad.wilk@oracle.com> 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 1aW0QC-0000xL-Vb for xen-devel@lists.xenproject.org; Wed, 17 Feb 2016 11:37:29 +0000 In-Reply-To: <1452219920-14043-3-git-send-email-konrad.wilk@oracle.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: Konrad Rzeszutek Wilk Cc: wei.liu2@citrix.com, ian.campbell@citrix.com, andrew.cooper3@citrix.com, mpohlack@amazon.de, JBeulich@suse.com, xen-devel@lists.xenproject.org, dgdegra@tycho.nsa.gov List-Id: xen-devel@lists.xenproject.org Konrad Rzeszutek Wilk writes ("[PATCH v3 2/3] XENVER_build_id: Provide ld-embedded build-ids (v8)"): > The mechanism to get this is via the XENVER hypercall and > we add a new sub-command to retrieve the binary build-id > called XENVER_build_id. The sub-hypercall parameter > allows an arbitrary size (the buffer and len is provided > to the hypervisor). A NULL parameter will probe the hypervisor > for the length of the build-id. > > One can also retrieve the value of the build-id by doing > 'readelf -h xen-syms'. > > For EFI builds we re-use the same build-id that the xen-syms > was built with. > > Note that there are no changes to the XSM files (dummy.c > and hooks.c) as the privileged subops fall in the default case. > > The version of ld that first implemented --build-id is v2.18. > Hence we check for that or later version - if older version > found we do not build the hypervisor with the build-id > (and the return code is -ENODATA for that case). I think this commit message is missing some important explanation for poor ignorant souls like me. Something like: It is possible to have ld record an arbitrary identifier in an ELF, which can then be read out with `readelf'. We also want to provide a way for guests to retrieve the same identifier. [ xxx do we? Maybe hosting providers would want to hide which of their hosts had been updated ] We construct the build-id out of [ ???? ] There is ???? no impact on users who want reproducible builds [or] ??? users who want reproducible builds are expected to use the facilities documented in ??? comments in Config.mk [or something] Ian.