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

Re: [Xen-devel] [PATCH V4 24/24] xl: update configuration when we unplug a device



On Tue, 2014-05-06 at 17:12 +0100, Wei Liu wrote:

> > > +    do {                                                                \
> > > +        libxl_domain_config d_config;                                   \
> > > +        libxl_device_ ## devtype *p = NULL, *x;                         \
> > > +        int num;                                                        \
> > > +        int j, k;                                                       \
> > > +                                                                        \
> > > +        libxl_domain_config_init(&d_config);                            \
> > > +        load_domain_config((domid), &d_config);                         \
> > > +                                                                        \
> > > +        k = 0;                                                          \
> > > +        for (j = 0; j < d_config.cnt; j++) {                            \
> > > +            x = d_config.ptr + j;                                       \
> > > +            if (compare(x, &(dev)))                                     \
> > 
> > Are you concerned with the possibility that two entries in the array
> > might match dev? Wouldn't that equate to e.g. two xvda devices? Should
> > we not reject such things elsewhere?
> > 
> 
> Yes. And it's not just concern, I've seen this already!
> The current xl block-attach doesn't complain if you add same CD images
> twice.

Urk. That sounds like a bug, probably in libxl_device_disk_add rather
than xl. Perhaps that is one yak too many for now though.

Ian.


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.