From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rusty Russell Subject: Re: [RFC 0/5] Making KVM_GET_ONE_REG/KVM_SET_ONE_REG generic. Date: Mon, 03 Sep 2012 22:03:26 +0930 Message-ID: <87wr0b2smh.fsf@rustcorp.com.au> References: <877gsia8rm.fsf@rustcorp.com.au> <87mx1dsfuc.fsf@rustcorp.com.au> <5041D3AE.6090804@redhat.com> <873931539z.fsf@rustcorp.com.au> <5044765A.30702@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Rusty Russell , Peter Maydell , Christoffer Dall , Alexander Graf , kvmarm@lists.cs.columbia.edu, kvm-devel To: Avi Kivity Return-path: Received: from ozlabs.org ([203.10.76.45]:39706 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755627Ab2ICMl1 (ORCPT ); Mon, 3 Sep 2012 08:41:27 -0400 In-Reply-To: <5044765A.30702@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Avi Kivity writes: > On 09/01/2012 03:35 PM, Rusty Russell wrote: >> Passing an address in a struct is pretty bad, since it involves >> compatibility wrappers. > > Right, some s390 thing. Err, no, i386 on x86-64, or ppc32 on ppc64, or arm on arm64.... Any time you put a pointer in a structure which is exposed to userspace, you have to deal with this. >> I don't think that is what makes the API hard >> to use. > > What is it then? I forgot what the original complaints/complainers were. I have no idea, since I didn't hear the complaints. But any non-fixed size array has issues in C; there's not much we can do about it. x86 manages this fine for msrs, and I didn't have a problem using it for my test programs. That's the limit of my experience, however. Cheers, Rusty.