Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935983AbZDIQsA (ORCPT ); Thu, 9 Apr 2009 12:48:00 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S936545AbZDIQqq (ORCPT ); Thu, 9 Apr 2009 12:46:46 -0400 Received: from victor.provo.novell.com ([137.65.250.26]:54041 "EHLO victor.provo.novell.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936540AbZDIQqo (ORCPT ); Thu, 9 Apr 2009 12:46:44 -0400 Message-ID: <49DE26EE.9030402@novell.com> Date: Thu, 09 Apr 2009 12:48:46 -0400 From: Gregory Haskins User-Agent: Thunderbird 2.0.0.19 (X11/20081227) MIME-Version: 1.0 To: avi@redhat.com CC: linux-kernel@vger.kernel.org, agraf@suse.de, pmullaney@novell.com, pmorreale@novell.com, anthony@codemonkey.ws, rusty@rustcorp.com.au, netdev@vger.kernel.org, kvm@vger.kernel.org, bhutchings@solarflare.com, andi@firstfloor.org, gregkh@suse.de, herber@gondor.apana.org.au, chrisw@sous-sol.org, shemminger@vyatta.com Subject: Re: [RFC PATCH v2 00/19] virtual-bus References: <20090409155200.32740.19358.stgit@dev.haskins.net> In-Reply-To: <20090409155200.32740.19358.stgit@dev.haskins.net> X-Enigmail-Version: 0.95.7 OpenPGP: id=D8195319 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig107B4FFA0C0392E5505599D7" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2616 Lines: 65 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig107B4FFA0C0392E5505599D7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Avi, Gregory Haskins wrote: > > Todo: > *) Develop some kind of hypercall registration mechanism for KVM so tha= t > we can use that as an integration point instead of directly hooking > kvm hypercalls > =20 What would you like to see here? I now remember why I removed the original patch I had for registration...it requires some kind of discovery mechanism on its own. Note that this is hard, but I figured it would make the overall series simpler if I didn't go this route and instead just integrated with a statically allocated vector. That being said, I have no problem adding this back in but figure we should discuss the approach so I don't go down a rat-hole ;) So, one thing we could do is use a string-identifier to discover hypercall resources. In this model, we would have one additional hypercall registered with kvm (in addition to the mmu-ops, etc) called KVM_HC_DYNHC or something like that. The support for DYNHC could be indicated in the cpuid (much like I do with the RESET, DYNIRQ, and VBUS support today. When hypercall provides register, the could provide a string such as "vbus", and they would be allocated a hypercall id.=20 Likewise, the HC_DYNHC interface would allow a guest to query the cpuid for the DYNHC feature, and then query the HC_DYNHC vector for a string to hc# translation. If the provider is not present, we return -1 for the hc#, otherwise we return the one that was allocated. I know how you feel about string-ids in general, but I am not quite sure how to design this otherwise without it looking eerily similar to what I already have (which is registering a new HC vector in kvm_para.h) Thoughts? -Greg --------------enig107B4FFA0C0392E5505599D7 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iEYEARECAAYFAkneJu4ACgkQlOSOBdgZUxnKlQCfUC3aBrggFJnxvaRiKGjavnqB ZHIAmgKAWrK7O20p7s149z/K4vjDMQPt =laVP -----END PGP SIGNATURE----- --------------enig107B4FFA0C0392E5505599D7-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/