<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/Documentation/virt/kvm/devices, branch linux-5.16.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.16.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.16.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2022-04-13T18:03:01Z</updated>
<entry>
<title>KVM: arm64: Do not change the PMU event filter after a VCPU has run</title>
<updated>2022-04-13T18:03:01Z</updated>
<author>
<name>Marc Zyngier</name>
</author>
<published>2022-01-27T16:17:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b67d9c111b20653bd53c7d8bc07e4acaf61e2f0a'/>
<id>urn:sha1:b67d9c111b20653bd53c7d8bc07e4acaf61e2f0a</id>
<content type='text'>
[ Upstream commit 5177fe91e4cf78a659aada2c9cf712db4d788481 ]

Userspace can specify which events a guest is allowed to use with the
KVM_ARM_VCPU_PMU_V3_FILTER attribute. The list of allowed events can be
identified by a guest from reading the PMCEID{0,1}_EL0 registers.

Changing the PMU event filter after a VCPU has run can cause reads of the
registers performed before the filter is changed to return different values
than reads performed with the new event filter in place. The architecture
defines the two registers as read-only, and this behaviour contradicts
that.

Keep track when the first VCPU has run and deny changes to the PMU event
filter to prevent this from happening.

Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
[ Alexandru E: Added commit message, updated ioctl documentation ]
Signed-off-by: Alexandru Elisei &lt;alexandru.elisei@arm.com&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Link: https://lore.kernel.org/r/20220127161759.53553-2-alexandru.elisei@arm.com
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>selftests: KVM: Introduce system counter offset test</title>
<updated>2021-10-18T18:43:46Z</updated>
<author>
<name>Oliver Upton</name>
</author>
<published>2021-09-16T18:15:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3f9808cac06c8dd4f800101e04f84fe3180198b0'/>
<id>urn:sha1:3f9808cac06c8dd4f800101e04f84fe3180198b0</id>
<content type='text'>
Introduce a KVM selftest to verify that userspace manipulation of the
TSC (via the new vCPU attribute) results in the correct behavior within
the guest.

Reviewed-by: Andrew Jones &lt;drjones@redhat.com&gt;
Signed-off-by: Oliver Upton &lt;oupton@google.com&gt;
Message-Id: &lt;20210916181555.973085-6-oupton@google.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
</content>
</entry>
<entry>
<title>KVM: x86: Expose TSC offset controls to userspace</title>
<updated>2021-10-18T18:43:45Z</updated>
<author>
<name>Oliver Upton</name>
</author>
<published>2021-09-16T18:15:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=828ca89628bfcb1b8f27535025f69dd00eb55207'/>
<id>urn:sha1:828ca89628bfcb1b8f27535025f69dd00eb55207</id>
<content type='text'>
To date, VMM-directed TSC synchronization and migration has been a bit
messy. KVM has some baked-in heuristics around TSC writes to infer if
the VMM is attempting to synchronize. This is problematic, as it depends
on host userspace writing to the guest's TSC within 1 second of the last
write.

A much cleaner approach to configuring the guest's views of the TSC is to
simply migrate the TSC offset for every vCPU. Offsets are idempotent,
and thus not subject to change depending on when the VMM actually
reads/writes values from/to KVM. The VMM can then read the TSC once with
KVM_GET_CLOCK to capture a (realtime, host_tsc) pair at the instant when
the guest is paused.

Cc: David Matlack &lt;dmatlack@google.com&gt;
Cc: Sean Christopherson &lt;seanjc@google.com&gt;
Signed-off-by: Oliver Upton &lt;oupton@google.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Message-Id: &lt;20210916181538.968978-8-oupton@google.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
</content>
</entry>
<entry>
<title>kvm: rename KVM_MAX_VCPU_ID to KVM_MAX_VCPU_IDS</title>
<updated>2021-09-30T08:27:05Z</updated>
<author>
<name>Juergen Gross</name>
</author>
<published>2021-09-13T13:57:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a1c42ddedf35dbf5f25ea0982ed6e226eef7a78c'/>
<id>urn:sha1:a1c42ddedf35dbf5f25ea0982ed6e226eef7a78c</id>
<content type='text'>
KVM_MAX_VCPU_ID is not specifying the highest allowed vcpu-id, but the
number of allowed vcpu-ids. This has already led to confusion, so
rename KVM_MAX_VCPU_ID to KVM_MAX_VCPU_IDS to make its semantics more
clear

Suggested-by: Eduardo Habkost &lt;ehabkost@redhat.com&gt;
Signed-off-by: Juergen Gross &lt;jgross@suse.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Message-Id: &lt;20210913135745.13944-3-jgross@suse.com&gt;
Signed-off-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'kvm-arm64/vlpi-save-restore' into kvmarm-master/next</title>
<updated>2021-04-13T14:41:45Z</updated>
<author>
<name>Marc Zyngier</name>
</author>
<published>2021-04-13T14:41:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e629003215e03a8260326b5626fdd655618a79bd'/>
<id>urn:sha1:e629003215e03a8260326b5626fdd655618a79bd</id>
<content type='text'>
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
</content>
</entry>
<entry>
<title>docs: kvm: devices/arm-vgic-v3: enhance KVM_DEV_ARM_VGIC_CTRL_INIT doc</title>
<updated>2021-04-06T13:51:38Z</updated>
<author>
<name>Eric Auger</name>
</author>
<published>2021-04-05T16:39:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=298c41b8fa1e02c5a35e2263d138583220ab6094'/>
<id>urn:sha1:298c41b8fa1e02c5a35e2263d138583220ab6094</id>
<content type='text'>
kvm_arch_vcpu_precreate() returns -EBUSY if the vgic is
already initialized. So let's document that KVM_DEV_ARM_VGIC_CTRL_INIT
must be called after all vcpu creations.

Signed-off-by: Eric Auger &lt;eric.auger@redhat.com&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Link: https://lore.kernel.org/r/20210405163941.510258-6-eric.auger@redhat.com
</content>
</entry>
<entry>
<title>KVM: arm64: GICv4.1: Give a chance to save VLPI state</title>
<updated>2021-03-24T18:12:21Z</updated>
<author>
<name>Shenming Lu</name>
</author>
<published>2021-03-22T06:01:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8082d50f4817ff6a7e08f4b7e9b18e5f8bfa290d'/>
<id>urn:sha1:8082d50f4817ff6a7e08f4b7e9b18e5f8bfa290d</id>
<content type='text'>
Before GICv4.1, we don't have direct access to the VLPI state. So
we simply let it fail early when encountering any VLPI in saving.

But now we don't have to return -EACCES directly if on GICv4.1. Let’s
change the hard code and give a chance to save the VLPI state (and
preserve the UAPI).

Signed-off-by: Shenming Lu &lt;lushenming@huawei.com&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Link: https://lore.kernel.org/r/20210322060158.1584-7-lushenming@huawei.com
</content>
</entry>
<entry>
<title>KVM: arm64: Fix some documentation build warnings</title>
<updated>2020-10-02T08:12:25Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2020-10-02T05:49:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=030bdf3698b7c3af190dd1fe714f0545f23441d0'/>
<id>urn:sha1:030bdf3698b7c3af190dd1fe714f0545f23441d0</id>
<content type='text'>
As warned with make htmldocs:

	.../Documentation/virt/kvm/devices/vcpu.rst:70: WARNING: Malformed table.
	Text in column margin in table line 2.

	=======  ======================================================
	-ENODEV: PMUv3 not supported or GIC not initialized
	-ENXIO:  PMUv3 not properly configured or in-kernel irqchip not
	         configured as required prior to calling this attribute
	-EBUSY:  PMUv3 already initialized
	-EINVAL: Invalid filter range
	=======  ======================================================

The ':' character for two lines are above the size of the column.
Besides that, other tables at the file doesn't use ':', so
just drop them.

While here, also fix this warning also introduced at the same patch:

	.../Documentation/virt/kvm/devices/vcpu.rst:88: WARNING: Block quote ends without a blank line; unexpected unindent.

By marking the C code as a literal block.

Fixes: 8be86a5eec04 ("KVM: arm64: Document PMU filtering API")
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab+huawei@kernel.org&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Acked-by: Paolo Bonzini &lt;pbonzini@redhat.com&gt;
Link: https://lore.kernel.org/r/b5385dd0213f1f070667925bf7a807bf5270ba78.1601616399.git.mchehab+huawei@kernel.org
</content>
</entry>
<entry>
<title>KVM: arm64: Match PMU error code descriptions with error conditions</title>
<updated>2020-09-29T13:26:38Z</updated>
<author>
<name>Alexandru Elisei</name>
</author>
<published>2020-09-24T12:37:31Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=51dd2eb98c72c1ff4cdb1526fff9a259a563c257'/>
<id>urn:sha1:51dd2eb98c72c1ff4cdb1526fff9a259a563c257</id>
<content type='text'>
Update the description of the PMU KVM_{GET, SET}_DEVICE_ATTR error codes
to be a better match for the code that returns them.

Signed-off-by: Alexandru Elisei &lt;alexandru.elisei@arm.com&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Reviewed-by: Andrew Jones &lt;drjones@redhat.com&gt;
Link: https://lore.kernel.org/r/20200924123731.268177-3-alexandru.elisei@arm.com
</content>
</entry>
<entry>
<title>KVM: arm64: Add undocumented return values for PMU device control group</title>
<updated>2020-09-29T13:26:38Z</updated>
<author>
<name>Alexandru Elisei</name>
</author>
<published>2020-09-24T12:37:30Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=af130d0adc8e48c73030c0d71a59ce1f7809a8fa'/>
<id>urn:sha1:af130d0adc8e48c73030c0d71a59ce1f7809a8fa</id>
<content type='text'>
KVM_ARM_VCPU_PMU_V3_IRQ returns -EFAULT if get_user() fails when reading
the interrupt number from kvm_device_attr.addr.

KVM_ARM_VCPU_PMU_V3_INIT returns the error value from kvm_vgic_set_owner().
kvm_arm_pmu_v3_init() checks that the vgic has been initialized and the
interrupt number is valid, but kvm_vgic_set_owner() can still return the
error code -EEXIST if another device has already claimed the interrupt.

Signed-off-by: Alexandru Elisei &lt;alexandru.elisei@arm.com&gt;
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Reviewed-by: Andrew Jones &lt;drjones@redhat.com&gt;
Link: https://lore.kernel.org/r/20200924123731.268177-2-alexandru.elisei@arm.com
</content>
</entry>
</feed>
