Kernel-Log – Was 2.6.32 bringt (5): Architektur und Virtualisierung
Die nächste Kernel-Version bringt Unterstützung für Intels Moorestown-Plattform, deren ACPI-Alternative SFI und die früher als "LaGrande" bezeichnete Trusted Execution Technology. Das neue KSM reduziert auf Wunsch den Speicherverbrauch, indem es gleiche Speicherinhalte von virtuellen Maschinen zusammenlegt. Mit Timechart lässt sich in Zukunft besser visualisieren, was System und Kernel eigentlich treiben.
- Thorsten Leemhuis
Da Linus Torvalds diese Woche unterwegs ist, gab es in den vergangen Tagen keine Änderungen im Hauptentwicklungszweig. Zahlreiche Entwickler haben den Linux-Vater aber bereits in LKML-Mails um die Aufnahme von Fehlerkorrekturen gebeten. Je mehr sich davon ansammeln, desto größter wird die Wahrscheinlichkeit, dass Torvalds nach seiner Rückkehr doch noch eine weitere Vorabversion von 2.6.32 veröffentlicht – bei der Freigabe des RC8 hatte Torvalds noch gehofft, dass das die letzte Vorabversion sein könnte.
Der fünfte und vorletzte Teil der Serie "Was Linux 2.6.32 bringt" beschäftigt sich mit den Änderungen an und um architekturspezifischen Code, Speichermanagement, Virtualisierung und Tracing. Die vier vorangegangenen Teile der Serie hatten sich mit den Neuerungen im Netzwerksubsystem, bei für Grafik-Hardware, im Bereich Storage und Dateisysteme sowie bei anderen Treibern beschäftigt.
X86-Systeme
Neu zum Kernel gestoßen ist Unterstützung für Intels früher als LaGrande Technology bezeichnete Trusted Execution Technology (TXT). Vor dem Ausführen des Kernels können TXT-Systeme zusammen mit den Komponenten des Projekts Trusted Boot (tboot) sicherstellen, dass der Kernel nicht von einem Angreifer modifiziert wurde. Details zu der Technik finden sich in der Kernel-Dokumentation und einem Artikel auf LWN.net.
Der Linux-Kernel lässt sich beim Kompilieren nun speziell für Atom-CPUs optimieren. Die Kernel-Hacker haben außerdem die Unterstützung für Intels Simple Firmware Interface (SFI) integriert. Dabei handelt es sich um eine von Intel entwickelte ACPI-Alternative, die bei der für Smartphones, Mobile Internet Devices (MIDs) und Embedded-Umgebungen gedachten Moorestown-Plattform zum Einsatz kommen soll. Moorestown soll nächstes Jahr kommen und auch unter Linux laufen. Details zu SFI finden sich in einem Vortrag, den ACPI-Subsystem-Verwalter und Intel-Mitarbeiter Len Brown auf dem Linux Symposium 2009 gehalten hat.
Zum Kernel stießen zudem weitere Teile zur Unterstützung von Moorestown – sie bauen auf einer zuvor von Thomas Gleixner eingebrachten Überarbeitung einiger Teile der x86-Unterstützung auf, durch die sich spezielle x86-Plattformen wie Moorestown besser abstrahieren lassen.
Virtualisiert
KVM unterstützt jetzt den "unrestricted guest"-Modus von Intels nächster Generation von Desktop- und Notebook-Prozessoren (Westmere), die Anfang 2010 unter Produktnamen wie Core i3 oder Core i5 in den Handel kommen sollen. Der Haupt-Patch von KVM-Entwickler Avi Kivity erläutert einige weitere Verbesserungen für KVM – darunter bessere Möglichkeiten zum Tracing und die Eventfd-basierten Mechanismen zum Verbinden von User- und Kernel-Software mit Gastsystemen über irqfd und ioeventfd.
Dass Paravirtualisierung an Bedeutung verliert, deutet eine von VMWare-Entwicklern eingebrachte Änderung an, die das Entfernen des früher von VMWare propagierten Virtual Machine Interface (VMI) bei Linux 2.6.37 ankündigt. Der Grund für diesen zuvor ausführlich diskutierten Schritt: Die Virtualisierungstechniken moderner CPUs seien so gut, dass die über VMI genutzte Paravirtualisierung zumeist keinen sonderlichen Performance-Vorteil bringe.
Memory-Management
Neu dabei ist auch das im Umfeld der KVM-Entwickler entstandene KSM. Das Kürzel steht für "Kernel Shared Memory" oder "Kernel SamePage Merging" und bezeichnet ein Framework, das den Speicher mehrerer Userland-Prozesse nach identischen Bereichen absucht; findet es welche, führt es sie zusammen und reduziert durch Freigabe der nun unnützen Kopien den Speicherverbrauch. Das ist etwa bei der Virtualisierung mit KVM interessant, wenn mehrere ähnliche Gastbetriebssysteme mit gleichen Software-Bibliotheken und Programmen auf einem Rechner laufen und dadurch größere Teile der im Arbeitsspeicher der Gäste gespeicherten Daten identisch sind.
Der Artikel zum Linux Symposiums 2009 und die dort verlinkte Textfassung eines OLS-2009-Vortrags erläutern die Technik näher und erklären, wie KSM sicherstellt, dass kein Chaos entsteht, wenn ein Prozess einen gemeinsam genutzten Speicherabschnitt verändert. Das PDF-Dokument erwähnt auch, wie das CERN mit Hilfe von KSM die Hardware-Anforderungen beim Auswerten der Daten des Teilchenbeschleunigers LHC (Large Hadron Collider) reduzieren konnte.
Durch das neue und von Intel-Entwickler Andi Kleen eingebrachte HWPOISON unterstützt der Linux-Kernel 2.6.32 außerdem einige der Techniken zur Behandlung und Umgehung von Speicherfehlern, die die Anfang 2010 erwarteten Server-Prozessoren aus Intels Nehalem-EX-Reihe bieten sollen. Details dazu finden sich im Commit-Kommentar, der Kernel-Dokumentation und einem LWN.net-Artikel.
Tracing
Die noch jungen Performance Counters wurden in Performance Events umbenannt, weil diese Bezeichnung besser zu dem in den vergangenen Monaten stark weiterentwickelten Code passt. Wie stark sich die Kernel-Infrastruktur zur Performance- und Laufzeit-Analyse sich wandelt, zeigen auch die umfangreichen Patches für die Performance Counter/Events (1, 2), das Tracing-Subsystem oder Oprofile , die die jeweils wichtigsten Neuerungen der Subsysteme kurz erwähnen. Etwa der nun ohne Sperren auskommende Ring-Buffer, den der Tracing-Code stark nutzt – Hintergründe hierzu liefert abermals LWN.net.
Neu ist auch das Subprogramm "perf sched" zur komfortableren Analyse des Prozess-Schedulers. Ebenfalls frisch dabei ist die Unterstützung für das maßgeblich von Arjan van de Ven entwickelte Timechart-Tool, mit dem sich zuvor mit "perf record" aufgezeichneter Traces zur einfacheren Analyse als SVG visualisieren lassen – van de Ven erklärt das ganze in seinem Blog detaillierter und zeigt dort verschiedene Einsatzmöglichkeiten.
Die kleinen Perlen
Viele weiteren nicht ganz so wichtige Neuerungen finden sich in der folgenden Liste mit den englischen Commit-Überschriften der jeweiligen Änderung. Die Einträge verlinken genau wie viele der Verweise im vorangegangenen Text auf das Webfrontend des von Linus Torvald betreuten Git-Zweigs mit den Kernel-Quellen auf Kernel.org. Im Webfrontend liefern normalerweise der Commit-Kommentar und der Patch selbst zahlreiche weitere Informationen zur jeweiligen Änderungen.
Architektur
ARM
- Add i.MX25 support
- Add support for Eukrea's CPUIMX27
- Add support for Eukrea's MBIMX27
- ARM: 5570/1: at91: Support for at91sam9g10: core chip board support
- ARM: 5572/1: at91: Support for at91sam9g45 series: core chip board support
- ARM: 5580/2: ARM TCM (Tightly-Coupled Memory) support v3
- ARM: 5590/1: Add basic support for ST Nomadik 8815 SoC and evaluation board
- ARM: 5629/1: Add support for Eukrea's CPU9260 CPU9G20
- ARM: 5630/1: Add support for Eukrea's CPUAT91
- ARM: 5641/1: bcmring: add Kconfig and Makefile entries in arch/arm
- ARM: 5667/3: U300 SSP/SPI board setup and test
- ARM: BAST: CPUFREQ: Add board support
- ARM: implement highpte
- ARM: Kirkwood: Marvell OpenRD-Base board support
- ARM: orion5x: Add LaCie NAS 2Big Network support
- ARM: OSIRIS: CPUFREQ: Add CPU frequency scaling support
- ARM: pxa: balloon3 (http://balloonboard.org/) base machine support
- ARM: S3C2410: CPUFREQ: Add core support.
- ARM: S3C2412: CPUFREQ: Add core support.
- ARM: S3C2440: CPUFREQ: Add core support.
- ARM: S3C24XX: CPUFREQ: Add core support.
- ARM: S3C6410: airgoo hmt board support
- ARM: S3C: CPUFREQ: Add debugfs support for cpufreq
- ARM: S3C: CPUFREQ: Add documentation for system
- ARM: S5PC100: Board and configuration file
- ARM: S5PC100: Clock and PLL support
- ARM: S5PC100: CPU initialization
- ARM: S5PC100: Kconfigs and Makefiles
- ep93xx video driver platform support
- Freescale i.MX25 PDK (3ds) board support
- MAINTAINERS: move ARM lists to infradead
- mx27: add support for phytec pca100 (phyCARD-s) board
- MXC: add basic MXC91231 support
- MXC: add iomux pins configuration support for MXC91231
- nommu: Add MMU-less support for Integrator platforms
- nommu: Add MMU-less support for the RealView boards
- nommu: ptrace support
- OMAP2: add board file for Nokia N800 and N810
- OMAP3: Zoom2: Add TWL4030 support
Power
- mpc5200: support for the MAN mpc5200 based board mucmc52
- PCI: document PCIe fundamental reset interfaces
- PCI/powerpc: support PCIe fundamental reset
- powerpc/40x: Add support for the ESTeem 195E (PPC405EP) SBC
- powerpc/44x: Add Eiger AMCC (AppliedMicro) PPC460SX evaluation board support.
- powerpc/83xx: Add support for MPC8377E-WLAN boards
- powerpc/85xx: Add support for P2020RDB board
- powerpc: Enable GCOV
- powerpc: Fix some late PowerMac G5 with PCIe ATI graphics
- powerpc: introduce and document sdhci,wp-inverted property for eSDHC
- powerpc/powermac: Thermal control turns system off too eagerly
- powerpc: Remaining 64-bit Book3E support
x86
- ACPI, x86: expose some IO-APIC routines when CONFIG_ACPI=n
- intel_txt: Force IOMMU on for Intel TXT launch
- Revert "x86, timers: Check for pending timers after (device) interrupts"
- x86: Add early platform detection
- x86: Add hardware_subarch ID for Moorestown
- x86: Add Moorestown early detection
- x86: Add Phoenix/MSC BIOSes to lowmem corruption list
- x86: Add reboot quirk for 3 series Mac mini
- x86/amd-iommu: replace "AMD IOMMU" by "AMD-Vi"
- x86/amd-iommu: Workaround for erratum 63
- x86, EDAC: Provide function to return NodeId of a CPU
- x86, intel_txt: Intel TXT reboot/halt shutdown support
- x86, intel_txt: Intel TXT Sx shutdown support
- x86, mce: fix reporting of Thermal Monitoring mechanism enabled
- x86, mce: Support specifying context for software mce injection
- x86, mce: Support specifying raise mode for software MCE injection
- x86: mce: Update X86_MCE description in x86/Kconfig
- x86, msr: Export the register-setting MSR functions via /dev/*/msr
- x86/oprofile: Enable multiplexing only if the model supports it
- x86, pat/mtrr: Rendezvous all the cpus for MTRR/PAT init
- x86, perf_counter, bts: Add BTS support to perfcounters
- x86: Remove STACKPROTECTOR_ALL
- x86, timers: Check for pending timers after (device) interrupts
- x86,percpu: use embedding for 64bit NUMA and page for 32bit NUMA
- x86: Provide an alternative() based cmpxchg64()
Others
- core generic GPIO support for Freescale Coldfire processors.
- davinci: Adding DM365 SOC Support
- davinci: Add support for DA850/OMAP-L138 EVM board
- davinci: da8xx: Add base DA830/OMAP-L137 SoC support
- davinci: da8xx: Add support for DA830/OMAP-L137 EVM board
- IA64: implement ticket locks for Itanium
- m32r: bzip2/lzma kernel compression support
- MAINTAINERS: add entry for TI DaVinci machine support
- microblaze: Add architectural support for USB EHCI host controllers
- microblaze: Add checking mechanism for MSR instruction
- MIPS: BCM63xx: Add integrated ethernet mac support.
- MIPS: BCM63xx: Add PCMCIA Cardbus support.
- MIPS: BCM63xx: Add serial driver for bcm63xx integrated UART.
- MIPS: BCM63xx: Add support for the Broadcom BCM63xx family of SOCs.
- MIPS: Loongson: Add GCC 4.4 support for Loongson2E
- MIPS: Loongson: Add oprofile support
- OMAP2/3/4 core: create omap_device layer
- OMAP2/3/4: create omap_hwmod layer
- OMAP: PM counter infrastructure.
- S390: 64-bit register support for 31-bit processes
- S390: add call home support
- S390: Enable guest page hinting by default.
- score: add maintainers for score architecture
- score: Add support for Sunplus S+core architecture
- sh: Add CEU support for EcoVec24
- sh: Add EcoVec (SH7724) board support
- sh: add FSI driver support for ms7724se
- sh: Add ftrace syscall tracing support
- sh: Add initial support for SH7757 CPU subtype
- sh: Add support DMA Engine to SH7722
- sh: Add support DMA Engine to SH7780
- sh: bzip2/lzma zImage support.
- sh: Function graph tracer support
- sh: kfr2r09 board support - mach-type and defconfig
- sparc: add basic support for 'perf'
- sparc: Add CONFIG_DMA_API_DEBUG support
- sparc,leon: CONFIG_SPARC_LEON option and leon specific files.
- sparc,leon: Introduce the sparc-leon CPU type.
- sparc: Niagara1 perf event support.
- sparc: Support all ultra3 and ultra4 derivatives.
Memory Management (MM)
- cgroups: update documentation of cgroups tasks and procs files
- Documentation/memory.txt: remove some very outdated recommendations
- hugetlb: add MAP_HUGETLB example
- hugetlb: clean up and update huge pages documentation
- HWPOISON: Add basic support for poisoned pages in fault handler v3
- HWPOISON: Add new SIGBUS error codes for hardware poison signals
- HWPOISON: Add page flag for poisoned pages
- HWPOISON: Add poison check to page fault handling
- HWPOISON: Add support for poison swap entries v2
- HWPOISON: x86: Add VM_FAULT_HWPOISON handling to x86 page fault handler v2
- kmemcheck: update documentation
- ksm: add mmu_notifier set_pte_at_notify()
- ksm: add some documentation
- ksm: change default values to better fit into mainline kernel
- ksm: more on default values
- ksm: sysfs and defaults
- ksm: the mm interface to ksm
- mm: allow memory hotplug and hibernation in the same kernel
- mm: fix NUMA accounting in numastat.txt
- mm: fix sparsemem configuration
- mm: oom analysis: add buffer cache information to show_free_areas()
- mm: oom analysis: add per-zone statistics to show_free_areas()
- mm: oom analysis: add shmem vmstat
- mm: vmstat: add isolate pages
- nommu: add support for Memory Protection Units (MPU)
- oom: make oom_score to per-process value
- pagemap clear_refs: modify to specify anon or mapped vma clearing
- pagemap: document KPF_KSM and show it in page-types
- pagemap: export KPF_HWPOISON
- page-types: add feature for walking process address space
- page-types: add hwpoison/unpoison feature
- page-types: introduce checked_open()
- page-types: introduce kpageflags_flags()
- page-types: make standalone pagemap/kpageflags read routines
- page-types: make voffset local variables
- proc: document `guest' column in /proc/stat
- slub: add option to disable higher order debugging slabs
- tracing, documentation: Add a document on the kmem tracepoints
- truncate: new helpers
- truncate: use new helpers
- vm: document that setting vfs_cache_pressure to 0 isn't a good idea
Tracing
- Add a tracepoint for block request remapping
- drm/i915: Add tracepoints
- ext4: Add a tracepoint for ext4_alloc_da_blocks()
- ftrace: document function and function graph implementation
- hrtimer: Add tracepoint for hrtimers
- itimers: Add tracepoints for itimer
- oprofile: Implement performance counter multiplexing
- perf: Add a SVG helper library file
- perf: Add a timestamp to fork events
- perf: Add timechart help text and add timechart to "perf help"
- perf_counter: powerpc: Add callchain support
- perf_counter, sched: Add sched_stat_runtime tracepoint
- perf report: Add raw displaying of per-thread counters
- perf report: Fix and improve the displaying of per-thread event counters
- perf sched: Account for lost events, increase default buffering
- perf sched: Add --input=file option to builtin-sched.c
- perf sched: Add involuntarily sleeping task in work atoms
- perf sched: Add 'perf sched latency' and 'perf sched replay'
- perf sched: Add 'perf sched map' scheduling event map printout
- perf sched: Add 'perf sched trace', improve documentation
- perf sched: Add runtime stats
- perf sched: Add sched latency profiling
- perf sched: Add support for sched:sched_stat_runtime events
- perf sched: Display time in milliseconds, reorganize output
- perf sched: Implement the 'perf sched record' subcommand
- perf sched: Implement the scheduling workload replay engine
- perf sched: Import schedbench.c
- perf sched: Make it easier to plug in new sub profilers
- perf sched: Output runtime and context switch totals
- perf sched: Print PIDs too
- perf: Tidy up after the big rename
- perf timechart: Add a power-only mode
- perf timechart: Add "perf timechart record"
- perf timechart: Show the duration of scheduler delays in the SVG
- perf timechart: Show the name of the waker/wakee in timechart
- perf tools: Add an option to multiplex counters in a single channel
- perf tools: Add missing parameters documentation
- perf tools: Add perf trace
- perf tools: Add trace event debugfs IO handler
- perf tools: Add trace event information parser
- perf tools: Allow the specification of all tracepoints at once
- perf tools: Complete support for dynamic strings
- perf tools: Factorize the thread code in a dedicated file
- perf tools: Implement counter output multiplexing
- perf util: Make the timechart SVG width dynamic
- perf util: SVG performance improvements
- powerpc/sputrace: Use the generic event tracer
- ring-buffer: add design document
- ring-buffer: make lockless
- sched: Add wait, sleep and iowait accounting tracepoints
- sched: Provide iowait counters
- timers: Add tracepoints for timer_list timers
- tracing: Add individual syscalls tracepoint id support
- tracing: add latency format to function_graph tracer
- tracing: add lock depth to entries
- tracing: Add more namespace area to 'perf list' output
- tracing: Add perf counter support for syscalls tracing
- tracing: Add syscall tracepoints
- tracing: Add trace events for each syscall entry/exit
- tracing: Add vim script to enable folding for function_graph traces
- tracing: create generic trace parser
- tracing, documentation: add a document describing how to do some performance analysis with tracepoints
- tracing/events: Add module tracepoints
- tracing/events: Add trace_event boot option
- tracing/filters: add filter Documentation
- tracing/filters: improve subsystem filter
- tracing: make testing syscall events a separate configuration
- tracing, page-allocator: add a postprocessing script for page-allocator-related ftrace events
- tracing: pass around ring buffer instead of tracer
- tracing, perf: Convert the power tracer into an event tracer
- tracing: Remove markers
- tracing: Remove mentioning of legacy latency_trace file from documentation
- tracing: Rename FTRACE_SYSCALLS for tracepoints
- tracing: Support for syscall events raw records in perfcounters
- tracing/syscalls: Add fields format for exit events
- tracing/syscalls: Add filtering support
- tracing: trace parser support for function and graph
- tracing: trace parser support for set_event
- x86, perf_counter, bts: Add BTS support to perfcounters
Virtualisierung
- Documentation: Update KVM list email address
- KVM: Add Directed EOI support to APIC emulation
- KVM: Add MCE support
- KVM: add module parameters documentation
- KVM: add support for change_pte mmu notifiers
- KVM: Add trace points in irqchip code
- KVM: Cache pdptrs
- KVM: Document basic API
- KVM: Document KVM_CAP_IRQCHIP
- KVM: Implement MSRs used by Hyper-V
- KVM: introduce module parameter for ignoring unknown MSRs accesses
- KVM: MMU: enable gbpages by increasing nr of pagesizes
- KVM: MMU: shadow support for 1gb pages
- KVM: Move common KVM Kconfig items to new file virt/kvm/Kconfig
- KVM: PIT support for HPET legacy mode
- KVM: powerpc: convert marker probes to event trace
- KVM: report 1GB page support to userspace
- KVM: SVM: enable nested svm by default
- KVM: SVM: Improve nested interrupt injection
- KVM: x86 emulator: Add missing EFLAGS bit definitions
- KVM: x86 emulator: add syscall emulation
- KVM: x86 emulator: Add sysenter emulation
- KVM: x86 emulator: Add sysexit emulation
- virtio: add virtio IDs file
- xen: make -fstack-protector work under Xen
Weitere Hintergründe und Informationen rund um die Entwicklungen im Linux-Kernel und dessen Umfeld finden sich in den vorangegangenen Ausgaben des Kernel-Log. (thl) (thl)