On Thu, Jan 10, 2013 at 01:25:48PM +0100, Stefan Hajnoczi wrote: > On Thu, Dec 27, 2012 at 11:06:58AM +0100, Luigi Rizzo wrote: > > diff -urp qemu-1.3.0-orig/hw/e1000.c qemu-1.3.0/hw/e1000.c > > --- qemu-1.3.0-orig/hw/e1000.c 2012-12-03 20:37:05.000000000 +0100 > > +++ qemu-1.3.0/hw/e1000.c 2012-12-27 09:47:16.000000000 +0100 > > @@ -35,6 +35,8 @@ > > > > #include "e1000_hw.h" > > > > +static int mit_on = 1; /* interrupt mitigation enable */ > > If you want to make this optional then please put it inside E1000State > so it can be toggled per NIC.
what is the simplest way to add NIC-specific options ? I have added one line to e1000_properties, as below static Property e1000_properties[] = { DEFINE_NIC_PROPERTIES(E1000State, conf), + DEFINE_PROP_UINT32("mit_on, E1000State, mit_on, 0), DEFINE_PROP_END_OF_LIST(), }; and this way i can do recognise this on the command line qemu ... -device e1000,mit_on=1 ... but i do not know how to set the property for the NIC i am using. Specifically, i normally run qemu with "-net nic,model=1000" (leaving the nic unconnected to the host network, so i can test the tx path without being constrained by the backend's speed) Any suggestion ? thanks luigi