KernelNewbies
  • Comments
  • Immutable Page
  • Menu
    • Navigation
    • RecentChanges
    • FindPage
    • Local Site Map
    • Help
    • HelpContents
    • HelpOnMoinWikiSyntax
    • Display
    • Attachments
    • Info
    • Raw Text
    • Print View
    • Edit
    • Load
    • Save
  • Login

Kernel Hacking

  • Frontpage

  • Kernel Hacking

  • Kernel Documentation

  • Kernel Glossary

  • FAQ

  • Found a bug?

  • Kernel Changelog

  • Upstream Merge Guide

Projects

  • KernelJanitors

  • KernelMentors

  • KernelProjects

Community

  • Why a community?

  • Regional Kernelnewbies

  • Personal Pages

  • Upcoming Events

References

  • Mailing Lists

  • Related Sites

  • Programming Links

Wiki

  • Recent Changes

  • Site Editors

  • Side Bar

  • Tips for Editors

  • Hosted by WikiWall

Navigation

  • RecentChanges
  • FindPage
  • HelpContents

Upload page content

You can upload content for the page named below. If you change the page name, you can also upload content for another page. If the page name is empty, we derive the page name from the file name.

File to load page content from
Page name
Comment

KernelNewbies:
  • KernelProjects
  • remove-paravirt-enabled

Removing paravirt_enabled

Use of paravirt_enabled() should be avoided at all costs in the kernel, we will be removing it. This page documents its current uses and plan of attack of how to replace them. We break things down into things with a solution already brewed and patches posted or soon to be posted and with pending items. Review the last discussion on this here .

Contents

  1. Removing paravirt_enabled
  2. Replacement completed on its way upstream one way or another
  3. Replacement being brewed

Replacement completed on its way upstream one way or another

  • arch/x86/kernel/cpu/microcode/core.c: patch posted by Boris Ostrovsky x86, microcode: Remove unnecessary paravirt_enabled check

  • arch/x86/mm/dump_pagetables.c: patch posted by Boris Petkov x86/ptdump: Remove paravirt_enabled()

  • arch/x86/kernel/head.c reserve_ebda_region(): patch posted by Luis x86/init: make ebda depend on PC subarch - uses PC subarch

  • arch/x86/kernel/apm_32.c: patch posted by Luis apm32: remove paravirt_enabled() use relies on relevant boot params being zero, follow up patch just in case for lguest by Luis and another one to clear bss on Xen by Boris Ostrovsky (independent of Luis' series)

  • arch/x86/kernel/tboot.c: patch posted by Luis x86/tboot: remove paravirt_enabledAs with apm, relies on the respective boot params being zero

  • arch/x86/kernel/cpu/intel.c: f00f_workaround, patch posted by Luis x86/cpu/intel: replace paravirt_enabled for f00f work around - although Andy notes it should be safe to run this on guests, for now we can just use the subarch to be safe

  • arch/x86/kernel/rtc.c: patch posted by Luis x86/rtc: replace paravirt_enabled check with subarch check - folds no CMOS RTC paravirt flag to a generic x86 flag

  • drivers/pnp/pnpbios/core.c: patch posted by Luis pnpbios: replace paravirt_enabled() check with subarch checks - uses subarch

Replacement being brewed

  • arch/x86/entry/entry_32.S: Andy notes that: "this is actually trying to check whether pv_cpu_ops.iret == native_iret. I sincerely hope that no additional support is *ever* added to x86 Linux for systems on which this is not the case."Andy noted perhaps we can rearrange the code a bit to look more like the 64-bit version, and referred to commit 7209a75d2009dbf7745e2fd354abf25c3deb3ca3 as a reference. Andy noted he'd work on this.
  • MoinMoin Powered
  • Python Powered
  • GPL licensed
  • Valid HTML 4.01