From: Konrad Rzeszutek Wilk Subject: Re: Xen-4.5 HVMOP ABI issues Date: Thu, 4 Dec 2014 22:19:26 -0400 Message-ID: <20141205021926.GC19424@andromeda.dapyr.net> References: <54785E46.4080107@citrix.com> <5478819F020000780004B70D@mail.emea.novell.com> <54787ED8.2010508@citrix.com> <5478A056020000780004B7CE@mail.emea.novell.com> <547898E7.30400@citrix.com> <5480748B020000780004CBFC@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <5480748B020000780004CBFC@mail.emea.novell.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: Jan Beulich Cc: Andrew Cooper , Xen-develList , Tim Deegan , IanCampbell List-Id: xen-devel@lists.xenproject.org On Thu, Dec 04, 2014 at 01:49:47PM +0000, Jan Beulich wrote: > >>> On 28.11.14 at 16:46, wrote: > > On 28/11/14 15:18, Jan Beulich wrote: > >>>>> On 28.11.14 at 14:55, wrote: > >>> The problem is with continuations which reuse the upper bits of the > >>> input register, not with this HVMOP_op_mask specifically; the > >>> HVMOP_op_mask simply adds to an existing problem. This is something > >>> which needs considering urgently because, as you identify above, we have > >>> already suffered an accidental ABI breakage with the mem-op widening. > >> Since we can't retroactively fix the mem-op widening, I still don't see > >> what's urgent here: As long as we don't change any of these masks, > >> nothing bad is going to happen. Of course one thing to consider with > >> this aspect in mind is whether to change the hvm-op or gnttab-op > >> masks again _before_ 4.5 goes out, based on whether we feel they're > >> wide enough for the (un)foreseeable future. > > > > By urgent, I mean exactly this, while we have the ability to tweak the > > masks. > > With no-one else voicing an opinion: > > For hvmop, the mask currently is 8 bits and we've got 22 ops defined. > > For gnttabop, the mask currently is 12 bits and we've got 12 ops defined. > > For the latter, we're fine even without further consideration. For the > former, the two operations actively using the continuation encoding > are tools-only ones. Since we're fine to alter the tools only interfaces, > and since it was intended for the tools-only HVM-ops to be split off > to a separate hypercall (e.g. hvmctl) anyway, the range restriction > would then no longer be a problem. Plus, in the worst case we could > always introduce yet another hypercall if we ran out of numbers. > > Consequently what I'd like to propose (and I guess I'll craft a patch > as soon as I finished this mail) is that we add comments to these > masks (also the memop one) to make clear that they mustn't change. > Additionally for forward compatibility I'd also like to add checks for > the upper bits to be zero for any of the sub-ops that don't actually > use them to encode continuation information. Konrad, would you > consider doing so acceptable for 4.5? Yes. > > Jan > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel