From: Randy Dunlap <rdunlap@infradead.org>
To: Jiaming Zhang <r772577952@gmail.com>
Cc: corbet@lwn.net, kvm@vger.kernel.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, pbonzini@redhat.com,
seanjc@google.com
Subject: Re: [PATCH v2] Documentation: KVM: Add reference specs for PIT and LAPIC ioctls
Date: Fri, 5 Sep 2025 12:17:28 -0700 [thread overview]
Message-ID: <bccc8f53-9efa-4844-af5d-9abfe4446d06@infradead.org> (raw)
In-Reply-To: <20250905174736.260694-1-r772577952@gmail.com>
On 9/5/25 10:47 AM, Jiaming Zhang wrote:
> ---
>
> The behavior of KVM_SET_PIT2 and KVM_SET_LAPIC conforms to their
> respective hardware specifications. Add references to the Intel 8254
> PIT datasheet and the Software Developer's Manual (SDM) to ensure
> users can rely on the official datasheets for behavioral details.
>
> Signed-off-by: Jiaming Zhang <r772577952@gmail.com>
Thanks. LGTM.
Reviewed-by: Randy Dunlap <rdunlap@infradead.org>
> ---
> Documentation/virt/kvm/api.rst | 12 ++++++++++++
> 1 file changed, 12 insertions(+)
>
> diff --git a/Documentation/virt/kvm/api.rst b/Documentation/virt/kvm/api.rst
> index 6aa40ee05a4a..f55e1b7562db 100644
> --- a/Documentation/virt/kvm/api.rst
> +++ b/Documentation/virt/kvm/api.rst
> @@ -2083,6 +2083,11 @@ The format of the APIC ID register (bytes 32-35 of struct kvm_lapic_state's
> regs field) depends on the state of the KVM_CAP_X2APIC_API capability.
> See the note in KVM_GET_LAPIC.
>
> +.. Tip::
> + ``KVM_SET_LAPIC`` ioctl strictly adheres to Intel® 64 and IA-32 Architectures
> + Software Developer's Manual (SDM). Refer to volume 3A of the `Intel SDM
> + <https://www.intel.com/content/www/us/en/developer/articles/technical/intel-sdm.html>`_.
> +
>
> 4.59 KVM_IOEVENTFD
> ------------------
> @@ -3075,6 +3080,13 @@ This IOCTL replaces the obsolete KVM_GET_PIT.
> Sets the state of the in-kernel PIT model. Only valid after KVM_CREATE_PIT2.
> See KVM_GET_PIT2 for details on struct kvm_pit_state2.
>
> +.. Tip::
> +
> + ``KVM_SET_PIT2`` ioctl strictly adheres to the spec of Intel 8254 PIT.
> + For example, a ``count`` value of 0 in ``struct kvm_pit_channel_state`` is
> + interpreted as 65536, which is the maximum count value. Refer to `Intel 8254
> + programmable interval timer <https://www.scs.stanford.edu/10wi-cs140/pintos/specs/8254.pdf>`_.
> +
> This IOCTL replaces the obsolete KVM_SET_PIT.
>
>
--
~Randy
next prev parent reply other threads:[~2025-09-05 19:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-25 5:39 [Discussion] Undocumented behavior of KVM_SET_PIT2 with count=0 Jiaming Zhang
2025-08-26 17:50 ` Sean Christopherson
2025-08-27 2:31 ` Jiaming Zhang
2025-09-05 7:51 ` [PATCH] Documentation: KVM: Add reference specs for PIT and LAPIC ioctls Jiaming Zhang
2025-09-05 16:51 ` Randy Dunlap
2025-09-05 17:47 ` [PATCH v2] " Jiaming Zhang
2025-09-05 19:17 ` Randy Dunlap [this message]
2025-09-16 0:25 ` Sean Christopherson
2025-09-16 20:02 ` Sean Christopherson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bccc8f53-9efa-4844-af5d-9abfe4446d06@infradead.org \
--to=rdunlap@infradead.org \
--cc=corbet@lwn.net \
--cc=kvm@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pbonzini@redhat.com \
--cc=r772577952@gmail.com \
--cc=seanjc@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®