Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Thu, Jul 30, 2009 at 02:52:46PM -0700, Alok Kataria wrote: > > > > > > I'm not really comfortable applying the tsc-merge patches themselves > > > since its not something I can easily spot check. Is it possible to > > > recode these to apply to the pre-merge tsc files (and demonstrate a > > > low risk of regression)? If so - and someone want to do that, it, then > > > it would be an easier push for lenny. > > > > > > > Oh I forgot to mention its is done for the pre-merge tsc files too, for > > ubuntu 8.04. > > > > > Please let me know if you run into any issues. > > Hi Dann, > > Please let me know if there would be any problem picking up these > patches from Ubuntu ? I have provided the links in my earlier mail. > > Let me know if you would need any help from me. Thanks Alok. I think I've got the port done, but will need some help testing changes. I'll post some builds sometime soon, just busy on other things atm. -- dann frazier -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
> > > > I'm not really comfortable applying the tsc-merge patches themselves > > since its not something I can easily spot check. Is it possible to > > recode these to apply to the pre-merge tsc files (and demonstrate a > > low risk of regression)? If so - and someone want to do that, it, then > > it would be an easier push for lenny. > > > > Oh I forgot to mention its is done for the pre-merge tsc files too, for > ubuntu 8.04. > > Please let me know if you run into any issues. Hi Dann, Please let me know if there would be any problem picking up these patches from Ubuntu ? I have provided the links in my earlier mail. Let me know if you would need any help from me. Thanks, Alok -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
> fyi, I took a shot at backporting these changes. Unfortunately our > source is from before the 32/64 tsc.c merge, and a couple of these > patches can't easily apply (even with the intrepid patches). > Specifically, these are the changesets I had issues with: > > commit 83db682 > x86: Hypervisor detection and get tsc_freq from hypervisor > commit 0532dac > x86: Skip verification by the watchdog for TSC clocksource > > I'm not really comfortable applying the tsc-merge patches themselves > since its not something I can easily spot check. Is it possible to > recode these to apply to the pre-merge tsc files (and demonstrate a > low risk of regression)? If so - and someone want to do that, it, then > it would be an easier push for lenny. > Oh I forgot to mention its is done for the pre-merge tsc files too, for ubuntu 8.04. https://bugs.launchpad.net/ubuntu/+source/linux/+bug/319945 The corresponding commits from hardy tree are : fd59eae709565d0c294f84bc2bf3c942a561c474 UBUNTU: x86: Hypervisor detection and get tsc_freq from hypervisor 2bdc8b310329b904a1c8b4505e47a5be15989dbc UBUNTU: x86: Skip verification by the watchdog for TSC clocksource. Also Ubuntu 8.04 required to patch the Xen kernel for some compile issues. commit acc45377a3a9938404bcc27586bd7ab4a2add062 UBUNTU: Xen: Fix FTBS after Vmware TSC updates. Maybe you would require to add this one too for lenny. Hope this helps. Please let me know if you run into any issues. Thanks, Alok -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Fri, Jul 17, 2009 at 01:25:54PM -0600, dann frazier wrote: > On Thu, Jul 16, 2009 at 11:53:38AM -0700, Alok Kataria wrote: > > > > On Wed, 2009-07-15 at 23:13 -0700, dann frazier wrote: > > > On Wed, Jul 15, 2009 at 10:09:59PM +0200, Moritz Muehlenhoff wrote: > > > > On Tue, Jul 14, 2009 at 10:17:24AM -0700, Alok Kataria wrote: > > > > > Pingany news on when these patches will be picked ? > > > > > Please let me know if you have any questions regarding these patches. > > > > > > > > We can have to schedule these patches for the next time we bump the > > > > ABI of the kernel (usually triggered by security fixes requiring > > > > one). > > > > > > > > Or is there already a planned bump, Dann? > > > > > > There's not one, but we could create a branch to queue ABI-breaking > > > fixes. > > > > If we do that, would there be an ETA on when I can expect these patches > > in the kernel ? Does it still have to wait for a security fix requiring > > ABI bump ? > > Nah - ABI bumps can come for non-security reasons too. But, since it > can be a pain for users (and our installer folks), we try to do queue > non-critical ABI breakers and do them together. fyi, I took a shot at backporting these changes. Unfortunately our source is from before the 32/64 tsc.c merge, and a couple of these patches can't easily apply (even with the intrepid patches). Specifically, these are the changesets I had issues with: commit 83db682 x86: Hypervisor detection and get tsc_freq from hypervisor commit 0532dac x86: Skip verification by the watchdog for TSC clocksource I'm not really comfortable applying the tsc-merge patches themselves since its not something I can easily spot check. Is it possible to recode these to apply to the pre-merge tsc files (and demonstrate a low risk of regression)? If so - and someone want to do that, it, then it would be an easier push for lenny. -- dann frazier -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Thu, Jul 16, 2009 at 11:53:38AM -0700, Alok Kataria wrote: > > On Wed, 2009-07-15 at 23:13 -0700, dann frazier wrote: > > On Wed, Jul 15, 2009 at 10:09:59PM +0200, Moritz Muehlenhoff wrote: > > > On Tue, Jul 14, 2009 at 10:17:24AM -0700, Alok Kataria wrote: > > > > Pingany news on when these patches will be picked ? > > > > Please let me know if you have any questions regarding these patches. > > > > > > We can have to schedule these patches for the next time we bump the > > > ABI of the kernel (usually triggered by security fixes requiring > > > one). > > > > > > Or is there already a planned bump, Dann? > > > > There's not one, but we could create a branch to queue ABI-breaking > > fixes. > > If we do that, would there be an ETA on when I can expect these patches > in the kernel ? Does it still have to wait for a security fix requiring > ABI bump ? Nah - ABI bumps can come for non-security reasons too. But, since it can be a pain for users (and our installer folks), we try to do queue non-critical ABI breakers and do them together. -- dann frazier -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Wed, 2009-07-15 at 23:13 -0700, dann frazier wrote: > On Wed, Jul 15, 2009 at 10:09:59PM +0200, Moritz Muehlenhoff wrote: > > On Tue, Jul 14, 2009 at 10:17:24AM -0700, Alok Kataria wrote: > > > Pingany news on when these patches will be picked ? > > > Please let me know if you have any questions regarding these patches. > > > > We can have to schedule these patches for the next time we bump the > > ABI of the kernel (usually triggered by security fixes requiring > > one). > > > > Or is there already a planned bump, Dann? > > There's not one, but we could create a branch to queue ABI-breaking > fixes. If we do that, would there be an ETA on when I can expect these patches in the kernel ? Does it still have to wait for a security fix requiring ABI bump ? Thanks, Alok -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Wed, Jul 15, 2009 at 10:09:59PM +0200, Moritz Muehlenhoff wrote: > On Tue, Jul 14, 2009 at 10:17:24AM -0700, Alok Kataria wrote: > > Pingany news on when these patches will be picked ? > > Please let me know if you have any questions regarding these patches. > > We can have to schedule these patches for the next time we bump the > ABI of the kernel (usually triggered by security fixes requiring > one). > > Or is there already a planned bump, Dann? There's not one, but we could create a branch to queue ABI-breaking fixes. -- dann frazier -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
On Tue, Jul 14, 2009 at 10:17:24AM -0700, Alok Kataria wrote: > Pingany news on when these patches will be picked ? > Please let me know if you have any questions regarding these patches. We can have to schedule these patches for the next time we bump the ABI of the kernel (usually triggered by security fixes requiring one). Or is there already a planned bump, Dann? Cheers, Moritz -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
Pingany news on when these patches will be picked ? Please let me know if you have any questions regarding these patches. Thanks. -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Bug#524542: Patches to fix bugs related to TSC clocksource on VMware
Package: linux-2.6 Version: 2.6.26-13 This is regarding some patches which improve timekeeping for Linux when running under VMware. Without these patches we may see incorrect timekeeping with Debian's lenny kernel when running as guest under VMware. VMware hypervisor exports a consistent TSC to the guest for timekeeping purposes, but still due to some kernel assumptions which don't hold true in virtualization environments, the kernel can mark the TSC unstable and hence unusable for timekeeping purposes. Without these patches TSC cannot be used as a reliable clocksource under VMware. The problems with TSC assumptions in the kernel are as follows. 1) TSC calibration : TSC calibration maybe error prone in virtualized environment, and since an error in TSC frequency may accumulate during the kernels runtime, its important to keep the error to the minimum. The best way to get the TSC frequency is to ask the hypervisor for that. 2) With the NO-HZ kernel, there is no guarantee that the acpi_pm timer will be sampled at least every 4.68 seconds (the wrap interval), because the vcpu, in extreme circumstances, may not have a chance to run in that time. Thus, the acpi_pm timer is not suitable to be used as a clocksource watchdog when running on a hypervisor. 3) Virtual TSCs can be kept nearly in sync, but because the virtual TSC offset is set by software, it's not perfect. So, the TSC synchronization test at bootup can fail. (Really, it can fail on native as well, and that's why the tests for backwards TSC were added to read_tsc()/vread_tsc()). We need a way to skip this check when on VMware. These patches add some VMware detection code which we use to get around these TSC assumptions which fail under VMware's hypervisor. Please note that these patches are not VMI ( paravirt) specific, and change the default kernel for 32 and 64bit, but the modifications come into affect only when we are running under VMware. Just the init and detection code is run for native case. This will also change the kABI, as it adds a field to the cpuinfo_x86 structure. The mainline commit id's are commit b2bcc7b299f37037b4a78dc1538e5d6508ae8110 x86: add a synthetic TSC_RELIABLE feature bit commit 49ab56ac6e1b907b7dadb72a4012460359feaf0e x86: add X86_FEATURE_HYPERVISOR feature bit commit 88b094fb8d4fe43b7025ea8d487059e8813e02cd x86: Hypervisor detection and get tsc_freq from hypervisor commit eca0cd028bdf0f6aaceb0d023e9c7501079a7dda x86: Add a synthetic TSC_RELIABLE feature bit. commit 395628ef4ea12ff0748099f145363b5e33c69acb x86: Skip verification by the watchdog for TSC clocksource. commit 6bdbfe99916398dbb28d83833cc04757110f2738 x86: VMware: Fix vmware_get_tsc code commit fd8cd7e1919fc1c27fe2fdccd2a1cd32f791ef0f x86: vmware: look for DMI string in the product serial key These patches have been included in the Ubuntu intrepid kernel as well which is 2.6.27, so if its easier you may cherry pick those patches from that tree. The only reason it might be easier is because IMO it would require less or no effort to backport it to Lenny from Intrepid rather than from mainline where these patches were applied in the 2.6.29 cycle. Thanks, Alok -- To UNSUBSCRIBE, email to debian-kernel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org