linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Marc Zyngier <maz@kernel.org>
To: Fuad Tabba <tabba@google.com>
Cc: kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
	oliver.upton@linux.dev, will@kernel.org, joey.gouly@arm.com,
	suzuki.poulose@arm.com, yuzenghui@huawei.com,
	catalin.marinas@arm.com
Subject: Re: [PATCH v1 1/4] KVM: arm64: Switch reg and val parameter ordering in vcpu_write_sys_reg()
Date: Tue, 28 Oct 2025 10:38:49 +0000	[thread overview]
Message-ID: <86zf9bux8m.wl-maz@kernel.org> (raw)
In-Reply-To: <20251027113943.1282568-2-tabba@google.com>

On Mon, 27 Oct 2025 11:39:40 +0000,
Fuad Tabba <tabba@google.com> wrote:
> 
> The vcpu_write_sys_reg() function previously used the signature:
> void vcpu_write_sys_reg(struct kvm_vcpu *vcpu, u64 val, enum vcpu_sysreg reg);
> 
> This was inconsistent with related functions and macros such as
> __vcpu_assign_sys_reg() and __vcpu_rmw_sys_reg(), both of which
> have the register parameter before the value.
> '(vcpu, reg, ...)' ordering.

On the other hand, write_sys_reg() is exactly in the same order as
vcpu_write_sys_reg(). I think that's the model to follow.

The __vcpu_*_sys_reg() helpers are internal things, really, and if
something has to change, I'd rather change those.

Thanks,

	M.

-- 
Without deviation from the norm, progress is not possible.


  reply	other threads:[~2025-10-28 10:39 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-27 11:39 [PATCH v1 0/4] KVM: arm64: Prevent sysreg helper parameter transposition Fuad Tabba
2025-10-27 11:39 ` [PATCH v1 1/4] KVM: arm64: Switch reg and val parameter ordering in vcpu_write_sys_reg() Fuad Tabba
2025-10-28 10:38   ` Marc Zyngier [this message]
2025-10-28 10:40     ` Fuad Tabba
2025-10-27 11:39 ` [PATCH v1 2/4] KVM: arm64: Add compile-time type check for register in __vcpu_assign_sys_reg() Fuad Tabba
2025-10-28 10:51   ` Marc Zyngier
2025-10-28 10:58     ` Fuad Tabba
2025-10-28 17:05     ` Fuad Tabba
2025-10-30  9:53     ` Fuad Tabba
2025-10-27 11:39 ` [PATCH v1 3/4] KVM: arm64: Add compile-time type check to vcpu_write_sys_reg() Fuad Tabba
2025-10-27 11:39 ` [PATCH v1 4/4] KVM: arm64: Add compile-time type check for register in __vcpu_rmw_sys_reg() Fuad Tabba

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=86zf9bux8m.wl-maz@kernel.org \
    --to=maz@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=joey.gouly@arm.com \
    --cc=kvmarm@lists.linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=oliver.upton@linux.dev \
    --cc=suzuki.poulose@arm.com \
    --cc=tabba@google.com \
    --cc=will@kernel.org \
    --cc=yuzenghui@huawei.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;
as well as URLs for NNTP newsgroup(s).