On Fri, Feb 12, 2016 at 7:57 AM, Jan Beulich <jbeul...@suse.com> wrote:

> >>> On 12.02.16 at 13:50, <tleng...@novetta.com> wrote:
> > On Feb 12, 2016 03:41, "Jan Beulich" <jbeul...@suse.com> wrote:
> >> In which case ASSERT(is_hvm_vcpu(curr)) would be the common
> >> way to document this (at once avoiding the open coding of
> >> is_hvm_vcpu()).
> >>
> >
> > I don't think we need an assert here. The function is fine for pv guests
> as
> > well up to that point. Filling in the rest of the registers for pv guests
> > can be done when pv events are implemented. Maybe a comment saying so is
> > warranted.
>
> I disagree: Either you mean to support PV in the function, in which
> case all fields should be filled, or you don't, in which case the
> ASSERT() would at once document that PV is intended to not be
> supported right now. With the conditional as in your patch any
> future reader may either think "bug" or get confused as to the
> actual intentions here.
>

Alright, sounds good to me.

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

Reply via email to