[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [Qemu-devel] [PATCH 3/4] qemu-config: Add -drive fd and opaque options





On 10/05/2012 02:51 PM, Eric Blake wrote:
On 10/05/2012 12:44 PM, Corey Bryant wrote:
Yes, this makes more sense.  I'd like to mirror the add-fd QMP command
as much as possible:

{ 'command': 'add-fd', 'data': {'*fdset-id': 'int', '*opaque': 'str'},
   'returns': 'AddfdInfo' }

So maybe we can make it:

-add-fd fd=24,fdset-id=1,opaque="rdonly" -add-fd
fd=25,fdset-id=1,opaque="rdwr"

Sounds better.  Note that while fdset-id is optional in QMP, I think it
needs to be mandatory on the CLI (you're telling qemu to use an
inherited fd, but unless you know what set that fd belongs to, you can't
then refer to that fd elsewhere on the command line, and unlike the QMP
command, there is no venue for QMP to tell you what set was autocreated).


I agree the fdset ID should be mandatory on the command line so we can link up other commands like '-drive file=/dev/fdset/nnn' where nnn is the fdset ID.

Bike-shedding: I think the command line can be slightly shorter with:

-add-fd fd=24,set=1,opaque=...


Sure, I have no problem with shortening it.

--
Regards,
Corey Bryant

with no real loss in information (that is, s/fdset-id/set/), since our
command lines are already quite long.  But going longhand to match QMP
doesn't hurt my feelings (libvirt will be automating this all anyway, so
I won't really be typing it by hand).



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]