From patchwork Wed May 4 03:24:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oliver Upton X-Patchwork-Id: 12837100 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 40885C433EF for ; Wed, 4 May 2022 03:27:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:From:Subject:References: Mime-Version:Message-Id:In-Reply-To:Date:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=sI/2FyJCMnb8spp+sRB7/dc9AIio5PsPkezm0/q1gkc=; b=LdyeGnFA1U3r8qTs3+UvYGc4SK JktOh8Oq12Bx+Im7QsjpDr6jdUiG5IVSGH+Qcn9w20Ci1hCkC1/PlREYorZGbF3FN7RLYOwhLDmO8 ms+VNKrsoUBiP9K2hM5+PADL1WLQgBExhr8+0U3O3ibWZHZhCxCsJvPoPNKQoTUnuDgx0yzQ49B8R 6UF+zvTQ1wjf+Pdcm8KjohchufNZJUvJV3/+8mtMCE0VCJlBZpTWJ02m/7OKTgiobrNMR3K+heH1T 69RfQ0XnI8SWnwWibdkF3l7zfmvjrhNfkfzRfrdxirZFW4mQDYKao+4iWZimoOWnq779Ocu3hkjuv QEtE3p+w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nm5e0-008YpP-8D; Wed, 04 May 2022 03:25:40 +0000 Received: from mail-pg1-x549.google.com ([2607:f8b0:4864:20::549]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nm5dO-008YMp-DZ for linux-arm-kernel@lists.infradead.org; Wed, 04 May 2022 03:25:03 +0000 Received: by mail-pg1-x549.google.com with SMTP id q143-20020a632a95000000b003c1c3490dfbso84640pgq.20 for ; Tue, 03 May 2022 20:25:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=zKCKCgAwM5oT8CgO5VNyRlj8I6pySWAhtN3tpf4n6dA=; b=ZM4FeKDUCZJiRyb6P789sMyqQSdZxP9XlE+XolrTRJung6jURrvaZ4TkCOnYGXplWq pivLdmaf4E5Z3zW+JY2SABmk/EOjm8hMWmuvKJVfiiGdB7KLHJDAJtHrlmN86QnZTqaz l0GNTroDwFS/uemQ9HeUoMAESGig2H42S+rLP9tOzEabemDBnqW9mEDfxrIqb6gDCu4Z 0P0BsGmF0zmkiOpJVOM8fR6uaDViEBbGGd7tcr/zne9m8oLreGewDVc/ADcEmTvP3EO5 hSXxOqRot+NCfGhNbQk0PT1eMb8gEXcXn1nt7AWnFAzDhdTznxulALBdDtim9UytX31t 6YQQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=zKCKCgAwM5oT8CgO5VNyRlj8I6pySWAhtN3tpf4n6dA=; b=ffqOwkleNDDREIc7WUiA8CGfox/S4eXkkUyxxj8LV6bArKyXhGTs4BqGWnVhfjgZIU XvLlKCY1u58AeSnUkh0t2epw4sgvOozP13CvTr6uj1hy8UTS6Dh3CLMRJfBrGXasoEBG xWGUmdQ0DnFELDs7KOiWKqZoR2b1cnDyz4hc/466ycUPdloiqyFJbFtGkYvEzlTQk2kr a/D94ozYopOUkB9ovQDUL6gGLgEV55a8WEoL1+L7L5Wh85S2glAvRMUs0nfiLCcYppGw bJb25cfMZh3djAzjVwGnHRQq0CRISTKyVkwNp2YSAJAtG2Y5OcahIFAE7a/MHZS4jr6I Hwcw== X-Gm-Message-State: AOAM533l4uT7wpDumgG2zR/J0poD9m2b1vYpad+GKpIlvhRDVQ1Fw7lO iPwSaVkYYwNFG6UVY+EBoRBkpp5IMMs= X-Google-Smtp-Source: ABdhPJzP/+HQx4zfHUjvoSoNur8GO2K6JD7rMAYer4k1x860wsfHvr/21vl0vtL9uuPVV77+Bqvb3zMQemE= X-Received: from oupton3.c.googlers.com ([fda3:e722:ac3:cc00:24:72f4:c0a8:21eb]) (user=oupton job=sendgmr) by 2002:a05:6a00:1312:b0:4e1:58c4:ddfd with SMTP id j18-20020a056a00131200b004e158c4ddfdmr19149872pfu.65.1651634700423; Tue, 03 May 2022 20:25:00 -0700 (PDT) Date: Wed, 4 May 2022 03:24:38 +0000 In-Reply-To: <20220504032446.4133305-1-oupton@google.com> Message-Id: <20220504032446.4133305-5-oupton@google.com> Mime-Version: 1.0 References: <20220504032446.4133305-1-oupton@google.com> X-Mailer: git-send-email 2.36.0.464.gb9c8b46e94-goog Subject: [PATCH v6 04/12] KVM: arm64: Rename the KVM_REQ_SLEEP handler From: Oliver Upton To: kvmarm@lists.cs.columbia.edu Cc: kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, maz@kernel.org, james.morse@arm.com, alexandru.elisei@arm.com, suzuki.poulose@arm.com, reijiw@google.com, ricarkol@google.com, Oliver Upton , Andrew Jones X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220503_202502_511824_983EB315 X-CRM114-Status: GOOD ( 12.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The naming of the kvm_req_sleep function is confusing: the function itself sleeps the vCPU, it does not request such an event. Rename the function to make its purpose more clear. No functional change intended. Signed-off-by: Oliver Upton Reviewed-by: Andrew Jones --- arch/arm64/kvm/arm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/kvm/arm.c b/arch/arm64/kvm/arm.c index 29e107457c4d..77b8b870c0fc 100644 --- a/arch/arm64/kvm/arm.c +++ b/arch/arm64/kvm/arm.c @@ -594,7 +594,7 @@ void kvm_arm_resume_guest(struct kvm *kvm) } } -static void vcpu_req_sleep(struct kvm_vcpu *vcpu) +static void kvm_vcpu_sleep(struct kvm_vcpu *vcpu) { struct rcuwait *wait = kvm_arch_vcpu_get_wait(vcpu); @@ -652,7 +652,7 @@ static void check_vcpu_requests(struct kvm_vcpu *vcpu) { if (kvm_request_pending(vcpu)) { if (kvm_check_request(KVM_REQ_SLEEP, vcpu)) - vcpu_req_sleep(vcpu); + kvm_vcpu_sleep(vcpu); if (kvm_check_request(KVM_REQ_VCPU_RESET, vcpu)) kvm_reset_vcpu(vcpu);