[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [v4][PATCH 04/19] xen/passthrough: extend hypercall to support rdm reservation policy
>>> On 06.07.15 at 12:56, <tiejun.chen@xxxxxxxxx> wrote: >>>> Yes, this demonstrates my point. Each of these is a single-bit boolean >>>> value that takes up a single bit -- either on or off. But here you have >>>> three values -- NO_DRM, RELAXED, and STRICT, that take up two bits. If >>> >>> Is this fine to you? >>> >>> #define _XEN_DOMCTL_DEV_NO_RDM 0 >>> #define XEN_DOMCTL_DEV_NO_RDM (1U<<_XEN_DOMCTL_DEV_NO_RDM) >>> #define _XEN_DOMCTL_DEV_RDM_RELAXED 1 >>> #define XEN_DOMCTL_DEV_RDM_RELAXED (1U<<_XEN_DOMCTL_DEV_RDM_RELAXED) >>> #define _XEN_DOMCTL_DEV_RDM_STRICT 2 >>> #define XEN_DOMCTL_DEV_RDM_STRICT (1U<<_XEN_DOMCTL_DEV_RDM_STRICT) >> >> AIUI these aren't individual flags, but kind of an enumeration. I.e. >> you should keep the original definitions and add - as suggested by >> George - a mask (two bits wide right now). >> > > Okay but George also thought NO_RDM may be pointless since we can just > ignore this flag field simply for DT device, and he also thought one bit > may be fine enough to cover two cases, strict and relaxed. So maybe > finally, here is, > > #define XEN_DOMCTL_DEV_RDM_RELAXED 1 > #define XEN_DOMCTL_DEV_RDM_FLAGS_MASK (0x1) Except that then you don't need a mask. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |