From nobody Sun Dec 14 06:16:54 2025 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7F3CB17E9; Wed, 22 May 2024 00:18:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.92.199 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716337116; cv=none; b=RUhg9dqVtkVcF+squ2m/jOolFwbKtuBXsaEGiB/XLgFCCoqWgf6DUpApvSbs0j3mJhq2V8VqOg5uYh+1K3RAgE3yaWnqnZ3cvpaMijNSqkQq3OFa4pACwNrtDVcWych/KRmJ2/FcNBr5MncY/q5I5k9+Mp1Ujp3Ju/uTsausLrA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716337116; c=relaxed/simple; bh=4+ySHrVqNAVjzmKO0VNksE6sM4Tx/NojuQOCdJda0EE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=tjeaHgXaRPmpDLdebsSl837Lcx9xgYyvnNriO6jSmVL3tgdbwgacVnXQP96f1f1RbMa33tb4pCNhxRghlca6S4RoKD9PZhZDAr7ucpEazsD+Xd5qJ2hOwZnIP86rjDxfnYDTQ6qvwd/BsiaqzOj/iKratyU+QSSFcV0dVO58QAM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=desiato.srs.infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=hnxOqT9d; arc=none smtp.client-ip=90.155.92.199 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=desiato.srs.infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="hnxOqT9d" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description; bh=3iG35o3GASCZuBv/55TMrv8RjQ1ZC8tBTVusKcrNnms=; b=hnxOqT9d6IyP4YNoxAgcMutYfu S9HwtO2+Hq4NHDYg4U2bsaQ9Z5wKTleg+PEoHO9144hw71wf60uP8hcKthQxCSDgu/JzxtufalgZg +yCtx3slTk8slSJTTQAE/45/6sa0Lcwc4h0MBY/0PlNujOIvdqwAFhsXySsACxjR13aCO85Akj0p4 x87qQQWZsdEwnrUsS90PGgg40UOL3IqEHs+CS8sZH0kwT1UfJu1N7OIM+tD0LRgct022d//FFHXUF HM9qIEd/K4iRqKec8y5PLe3zgeyKMQP9feRJ/4mpTaVnZXf0JKa4fwWcBVvu5y/VdBfK+sPX562rw CLSXH8BA==; Received: from [2001:8b0:10b:1::ebe] (helo=i7.infradead.org) by desiato.infradead.org with esmtpsa (Exim 4.97.1 #2 (Red Hat Linux)) id 1s9ZgS-000000080jH-3p2P; Wed, 22 May 2024 00:18:23 +0000 Received: from dwoodhou by i7.infradead.org with local (Exim 4.97.1 #2 (Red Hat Linux)) id 1s9ZgR-00000002b4Q-2hfk; Wed, 22 May 2024 01:18:19 +0100 From: David Woodhouse To: kvm@vger.kernel.org Cc: Paolo Bonzini , Jonathan Corbet , Sean Christopherson , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" , Paul Durrant , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Daniel Bristot de Oliveira , Valentin Schneider , Shuah Khan , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, jalliste@amazon.co.uk, sveith@amazon.de, zide.chen@intel.com, Dongli Zhang , Chenyi Qiang Subject: [RFC PATCH v3 04/21] UAPI: x86: Move pvclock-abi to UAPI for x86 platforms Date: Wed, 22 May 2024 01:16:59 +0100 Message-ID: <20240522001817.619072-5-dwmw2@infradead.org> X-Mailer: git-send-email 2.44.0 In-Reply-To: <20240522001817.619072-1-dwmw2@infradead.org> References: <20240522001817.619072-1-dwmw2@infradead.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: David Woodhouse X-SRS-Rewrite: SMTP reverse-path rewritten from by desiato.infradead.org. See http://www.infradead.org/rpr.html Content-Type: text/plain; charset="utf-8" From: Jack Allister KVM provides a new interface for performing a fixup/correction of the KVM clock against the reference TSC. The KVM_[GS]ET_CLOCK_GUEST API requires a pvclock_vcpu_time_info, as such the caller must know about this definition. Move the definition to the UAPI folder so that it is exported to usermode and also change the type definitions to use the standard for UAPI exports. Signed-off-by: Jack Allister Signed-off-by: David Woodhouse Reviewed-by: Paul Durrant --- arch/x86/include/{ =3D> uapi}/asm/pvclock-abi.h | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) rename arch/x86/include/{ =3D> uapi}/asm/pvclock-abi.h (83%) diff --git a/arch/x86/include/asm/pvclock-abi.h b/arch/x86/include/uapi/asm= /pvclock-abi.h similarity index 83% rename from arch/x86/include/asm/pvclock-abi.h rename to arch/x86/include/uapi/asm/pvclock-abi.h index 1436226efe3e..48cc53f62dd6 100644 --- a/arch/x86/include/asm/pvclock-abi.h +++ b/arch/x86/include/uapi/asm/pvclock-abi.h @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: GPL-2.0 */ +/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */ #ifndef _ASM_X86_PVCLOCK_ABI_H #define _ASM_X86_PVCLOCK_ABI_H #ifndef __ASSEMBLY__ @@ -24,20 +24,20 @@ */ =20 struct pvclock_vcpu_time_info { - u32 version; - u32 pad0; - u64 tsc_timestamp; - u64 system_time; - u32 tsc_to_system_mul; - s8 tsc_shift; - u8 flags; - u8 pad[2]; + __u32 version; + __u32 pad0; + __u64 tsc_timestamp; + __u64 system_time; + __u32 tsc_to_system_mul; + __s8 tsc_shift; + __u8 flags; + __u8 pad[2]; } __attribute__((__packed__)); /* 32 bytes */ =20 struct pvclock_wall_clock { - u32 version; - u32 sec; - u32 nsec; + __u32 version; + __u32 sec; + __u32 nsec; } __attribute__((__packed__)); =20 #define PVCLOCK_TSC_STABLE_BIT (1 << 0) --=20 2.44.0