Re: [PATCH 3/3] KVM: PPC: Book3S HV: Add H_SET_MODE hcall handling

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

 



Alex,

> > +static int kvmppc_h_set_mode(struct kvm_vcpu *vcpu, unsigned long mflags,
> > +			     unsigned long resource, unsigned long value1,
> > +			     unsigned long value2)
> > +{
> > +	switch (resource) {
> > +	case H_SET_MODE_RESOURCE_SET_CIABR:
> > +		if (!kvmppc_power8_compatible(vcpu))
> > +			return H_P2;
> > +		if (value2)
> > +			return H_P4;
> > +		if (mflags)
> > +			return H_UNSUPPORTED_FLAG_START;
> > +		if ((value1 & 0x3) == 0x3)
> 
> What is this?

It's what it says in PAPR (I wish that was public!!!).  Joking aside... 

If you refer to the 2.07 HW arch (not PAPR), the bottom two bits of the
CIABR tell you what mode to match in.  0x3 means match in hypervisor,
which we obviously don't want the guest to be able to do.

I'll add some #defines to make it a clearer and repost.

Mikey

--
To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [KVM Development]     [KVM ARM]     [KVM ia64]     [Linux Virtualization]     [Linux USB Devel]     [Linux Video]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux