From: Dan Magenheimer Subject: [RFC] Correct/fast timestamping in apps under Xen [3 of 4]: Incarnation number and landlocking Date: Fri, 2 Oct 2009 10:51:20 -0700 (PDT) Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "Xen-Devel (E-mail)" Cc: kurt.hackel@oracle.com, Ian Pratt , Keir Fraser List-Id: xen-devel@lists.xenproject.org =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Premise 3: Xen is able to track the "incarnation" number for a guest. This number will increase whenever a guest is restored or migrated (and possibly more frequently). Optionally, an administrator can explicitly mark a guest as "landlocked", disallowing save/restore/migration for that guest. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Incarnation number is intended to be a monotonically increasing 64-bit number that never wraps around. It will certainly increment when a guest is saved and restored, and when a guest migrates. Other events might be useful for an app to track, such as vcpu-to-pcpu switches, C3 power events, and ?? "Landlocking" (term just made up, suggest a better one if you have one) enforces the fact that many guests are never saved and restored and never migrate. If a system administrator is willing to guarantee that (and the guarantee may be necessary in many other circumstances anyway, such as PCI passthrough), AND if the guest is lauched on a server with reliable TSC, many TSC problems go away so rdtsc CAN be used directly. I'm thinking that a VM config option can be specified and Xen (or tools) would enforce it.