Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 85197 - since 2.6.11 the kernel is not preemptive
Summary: since 2.6.11 the kernel is not preemptive
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: Gentoo Kernel Bug Wranglers and Kernel Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-14 04:05 UTC by Roie Kerstein
Modified: 2005-03-14 14:24 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
my kernel configuration (.config,23.99 KB, text/plain)
2005-03-14 04:06 UTC, Roie Kerstein
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Roie Kerstein 2005-03-14 04:05:32 UTC
Since 2.6.11 the kernel hangs randomly for short periods of time, even on light load. Only under no load at all it works fluently.
I marked [*] preemptive kernel and [*] preempt the big kernel lock.

Reproducible: Always
Steps to Reproduce:
1.
2.
3.




emerge --info 
 
Portage 2.0.51.19 (default-linux/x86/2004.3, gcc-3.4.3, 
glibc-2.3.4.20050125-r0, 2.6.11-gentoo-r3 i686) 
================================================================= 
System uname: 2.6.11-gentoo-r3 i686 Intel(R) Pentium(R) 4 CPU 1.80GHz 
Gentoo Base System version 1.6.9 
Python:              dev-lang/python-2.3.4-r1 [2.3.4 (#2, Feb 11 2005, 
02:11:03)] 
dev-lang/python:     2.3.4-r1 
sys-devel/autoconf:  2.59-r6, 2.13 
sys-devel/automake:  1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4 
sys-devel/binutils:  2.15.92.0.2-r2 
sys-devel/libtool:   1.5.10-r4 
virtual/os-headers:  2.6.8.1-r2 
ACCEPT_KEYWORDS="x86 ~x86" 
AUTOCLEAN="yes" 
CFLAGS="-O3 -march=pentium4 -pipe -fomit-frame-pointer" 
CHOST="i686-pc-linux-gnu" 
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/qmail/control" 
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" 
CXXFLAGS="-O3 -march=pentium4 -pipe -fomit-frame-pointer" 
DISTDIR="/usr/portage/distfiles" 
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms" 
GENTOO_MIRRORS="http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ 
ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ 
ftp://gentoo.mirrors.tds.net/gentoo http://gentoo.mirrors.tds.net/gentoo 
http://mirror.clarkson.edu/pub/distributions/gentoo/" 
MAKEOPTS="-j2" 
PKGDIR="/usr/portage/packages" 
PORTAGE_TMPDIR="/var/tmp" 
PORTDIR="/usr/portage" 
PORTDIR_OVERLAY="/usr/local/portage" 
SYNC="rsync://rsync.gentoo.org/gentoo-portage" 
USE="x86 X X509 acpi alsa apm arts artswrappersuid avi bash-completion berkdb 
bidi bitmap-fonts bzlib cddb cdparanoia cdr crypt ctype cups curl dga 
divx4linux doc dpms emboss encode foomaticdb ftp gdbm gif gnome gpm gstreamer 
gtk2 gtkhtml hal i8x0 icq imagemagick imlib jpeg jpeg2k kde kdeenablefinal 
libg++ libwww mad mikmod mono mozilla moznocompose moznoirc moznomail mp3 mpeg 
msn ncurses nls nomotif nowin nptl offensive opengl pam pdflib perl pic png 
python qt readline real sdl slang spell sse sse2 ssl svga tcpd tetex threads 
truetype truetype-fonts type1-fonts unicode xine xml xml2 xv xvid zlib 
video_cards_i915 linguas_he" 
Unset:  ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
Comment 1 Roie Kerstein 2005-03-14 04:06:59 UTC
Created attachment 53406 [details]
my kernel configuration
Comment 2 Daniel Drake (RETIRED) gentoo-dev 2005-03-14 08:05:53 UTC
Please elaborate on what you mean by "the kernel hangs". I don't think kernel preemption is along the same lines as what you are thinking.
Comment 3 Roie Kerstein 2005-03-14 08:17:13 UTC
As far as I understand, and please correct me if I am wrong, preemptiveness is a deal about responsiveness, and ensuring that processes interacting with the user will run fluently.
My kernel does not hang for long periods of time, but:
a. It is not responsive anymore. It may take a second and sometimes more until the kernel responds to a mouse click or keyboard press if it is under moderate load.
b. Applications do not run fluently. That is, animations are not smooth etc.
Comment 4 Daniel Drake (RETIRED) gentoo-dev 2005-03-14 08:54:44 UTC
I think you are thinking of general preemption. Kernel preemption is something different.

You should attach the output of dmesg and post the output of hdparm -d /dev/hda where hda is your primary hard disk. When the system is not responding to your mouse click, can you move the mouse at all?
Comment 5 Roie Kerstein 2005-03-14 14:01:27 UTC
No. the mouse does not move as well.
I don't understand why the hell the kernel does not use DMA on my hard drive...
# hdparm -d /dev/hda
/dev/hda:
 using_dma    =  0 (off)

dmesg:
Linux version 2.6.11-gentoo-r3 (root@lightstar) (gcc version 3.4.3 20041125 (Gentoo Linux 3.4.3-r1, ssp-3.4.3-0, pie-8.7.7)) #1 Sun Mar 13 23:26:29 IST 2005
BIOS-provided physical RAM map:
 BIOS-e820: 0000000000000000 - 000000000009fc00 (usable)
 BIOS-e820: 000000000009fc00 - 00000000000a0000 (reserved)
 BIOS-e820: 00000000000e0000 - 0000000000100000 (reserved)
 BIOS-e820: 0000000000100000 - 000000000fe40000 (usable)
 BIOS-e820: 000000000fe40000 - 000000000fe50000 (ACPI data)
 BIOS-e820: 000000000fe50000 - 000000000ff00000 (ACPI NVS)
254MB LOWMEM available.
On node 0 totalpages: 65088
  DMA zone: 4096 pages, LIFO batch:1
  Normal zone: 60992 pages, LIFO batch:14
  HighMem zone: 0 pages, LIFO batch:1
DMI 2.3 present.
ACPI: RSDP (v000 ACPIAM                                ) @ 0x000f74c0
ACPI: RSDT (v001 INTEL  D845GBV  0x20020605 MSFT 0x00000097) @ 0x0fe40000
ACPI: FADT (v002 INTEL  D845GBV  0x20020605 MSFT 0x00000097) @ 0x0fe40200
ACPI: MADT (v001 INTEL  D845GBV  0x20020605 MSFT 0x00000097) @ 0x0fe40300
ACPI: DSDT (v001 INTEL  D845GBV  0x0000010a MSFT 0x0100000d) @ 0x00000000
ACPI: Local APIC address 0xfee00000
ACPI: LAPIC (acpi_id[0x01] lapic_id[0x00] enabled)
Processor #0 15:2 APIC version 20
ACPI: IOAPIC (id[0x01] address[0xfec00000] gsi_base[0])
IOAPIC[0]: apic_id 1, version 32, address 0xfec00000, GSI 0-23
ACPI: INT_SRC_OVR (bus 0 bus_irq 0 global_irq 2 dfl dfl)
ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level)
ACPI: IRQ0 used by override.
ACPI: IRQ2 used by override.
ACPI: IRQ9 used by override.
Enabling APIC mode:  Flat.  Using 1 I/O APICs
Using ACPI (MADT) for SMP configuration information
Allocating PCI resources starting at 0ff00000 (gap: 0ff00000:f0100000)
Built 1 zonelists
Kernel command line: BOOT_IMAGE=2611 ro root=302
mapped APIC to ffffd000 (fee00000)
mapped IOAPIC to ffffc000 (fec00000)
Initializing CPU#0
PID hash table entries: 1024 (order: 10, 16384 bytes)
Detected 1799.836 MHz processor.
Using tsc for high-res timesource
Console: colour VGA+ 80x25
Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
Memory: 254708k/260352k available (1838k kernel code, 5184k reserved, 804k data, 136k init, 0k highmem)
Checking if this processor honours the WP bit even in supervisor mode... Ok.
Calibrating delay loop... 3547.13 BogoMIPS (lpj=1773568)
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
CPU: After generic identify, caps: 3febfbff 00000000 00000000 00000000 00000000 00000000 00000000
CPU: After vendor identify, caps: 3febfbff 00000000 00000000 00000000 00000000 00000000 00000000
CPU: Trace cache: 12K uops, L1 D cache: 8K
CPU: L2 cache: 512K
CPU: After all inits, caps: 3febfbff 00000000 00000000 00000080 00000000 00000000 00000000
Intel machine check architecture supported.
Intel machine check reporting enabled on CPU#0.
CPU0: Intel P4/Xeon Extended MCE MSRs (12) available
CPU: Intel(R) Pentium(R) 4 CPU 1.80GHz stepping 04
Enabling fast FPU save and restore... done.
Enabling unmasked SIMD FPU exception support... done.
Checking 'hlt' instruction... OK.
ENABLING IO-APIC IRQs
..TIMER: vector=0x31 pin1=2 pin2=-1
NET: Registered protocol family 16
PCI: PCI BIOS revision 2.10 entry at 0xf0031, last bus=1
PCI: Using configuration type 1
mtrr: v2.0 (20020519)
ACPI: Subsystem revision 20050211
ACPI: Interpreter enabled
ACPI: Using IOAPIC for interrupt routing
ACPI: PCI Root Bridge [PCI0] (00:00)
PCI: Probing PCI hardware (bus 00)
PCI: Ignoring BAR0-3 of IDE controller 0000:00:1f.1
PCI: Transparent bridge - 0000:00:1e.0
ACPI: PCI Interrupt Routing Table [\_SB_.PCI0._PRT]
ACPI: PCI Interrupt Routing Table [\_SB_.PCI0.P0P1._PRT]
ACPI: Power Resource [URP1] (off)
ACPI: Power Resource [FDDP] (off)
ACPI: Power Resource [LPTP] (off)
ACPI: PCI Interrupt Link [LNKA] (IRQs 3 4 5 7 9 10 *11 12 14 15)
ACPI: PCI Interrupt Link [LNKB] (IRQs *3 4 5 7 9 10 11 12 14 15)
ACPI: PCI Interrupt Link [LNKC] (IRQs 3 4 5 7 *9 10 11 12 14 15)
ACPI: PCI Interrupt Link [LNKD] (IRQs 3 4 *5 7 9 10 11 12 14 15)
ACPI: PCI Interrupt Link [LNKE] (IRQs 3 4 5 6 7 9 10 11 12 14 15) *0, disabled.
ACPI: PCI Interrupt Link [LNKF] (IRQs 3 4 5 6 7 9 10 11 12 14 15) *0, disabled.
ACPI: PCI Interrupt Link [LNKG] (IRQs 3 4 5 6 7 9 10 11 12 14 15) *0, disabled.
ACPI: PCI Interrupt Link [LNKH] (IRQs 3 4 5 6 7 9 *10 11 12 14 15)
SCSI subsystem initialized
usbcore: registered new driver usbfs
usbcore: registered new driver hub
PCI: Using ACPI for IRQ routing
** PCI interrupts are no longer routed automatically.  If this
** causes a device to stop working, it is probably because the
** driver failed to call pci_enable_device().  As a temporary
** workaround, the "pci=routeirq" argument restores the old
** behavior.  If this argument makes the device work again,
** please email the output of "lspci" to bjorn.helgaas@hp.com
** so I can fix the driver.
inotify device minor=63
Initializing Cryptographic API
Linux agpgart interface v0.100 (c) Dave Jones
agpgart: Detected an Intel 845G Chipset.
agpgart: Maximum main memory to use for agp memory: 202M
agpgart: Detected 892K stolen memory.
agpgart: AGP aperture is 128M @ 0xf0000000
[drm] Initialized drm 1.0.0 20040925
ACPI: PCI interrupt 0000:00:02.0[A] -> GSI 16 (level, low) -> IRQ 16
[drm] Initialized i915 1.1.0 20040405 on minor 0: Intel Corp. 82845G/GL[Brookdale-G]/GE Chipset Integrated Graphics Device
ACPI: Power Button (FF) [PWRF]
ACPI: Sleep Button (CM) [SLPB]
ACPI: Processor [CPU1] (supports 8 throttling states)
serio: i8042 AUX port at 0x60,0x64 irq 12
serio: i8042 KBD port at 0x60,0x64 irq 1
Serial: 8250/16550 driver $Revision: 1.90 $ 8 ports, IRQ sharing disabled
ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
mice: PS/2 mouse device common for all mice
input: AT Translated Set 2 keyboard on isa0060/serio0
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered
PPP generic driver version 2.4.2
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
Probing IDE interface ide0...
hda: WDC WD800JB-00FMA0, ATA DISK drive
Probing IDE interface ide1...
hdc: SAMSUNG CD-ROM SC-152L, ATAPI CD/DVD-ROM drive
hdd: CR-48XCTE, ATAPI CD/DVD-ROM drive
Probing IDE interface ide2...
Probing IDE interface ide3...
Probing IDE interface ide4...
Probing IDE interface ide5...
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
ide1 at 0x170-0x177,0x376 on irq 15
hda: max request size: 128KiB
hda: 156301488 sectors (80026 MB) w/8192KiB Cache, CHS=65535/16/63
hda: cache flushes supported
 hda: hda1 hda2 hda3 hda4
hdc: ATAPI 52X CD-ROM drive, 128kB Cache
Uniform CD-ROM driver Revision: 3.20
hdd: ATAPI 48X CD-ROM CD-R/RW drive, 2048kB Cache
usbcore: registered new driver usblp
drivers/usb/class/usblp.c: v0.13: USB Printer Device Class driver
Initializing USB Mass Storage driver...
usbcore: registered new driver usb-storage
USB Mass Storage support registered.
Advanced Linux Sound Architecture Driver Version 1.0.8 (Thu Jan 13 09:39:32 2005 UTC).
ACPI: PCI interrupt 0000:00:1f.5[B] -> GSI 17 (level, low) -> IRQ 17
PCI: Setting latency timer of device 0000:00:1f.5 to 64
intel8x0_measure_ac97_clock: measured 49238 usecs
intel8x0: clocking to 48000
ALSA device list:
  #0: Intel 82801DB-ICH4 with AD1981A at 0xffa7f800, irq 17
NET: Registered protocol family 2
IP: routing cache hash table of 2048 buckets, 16Kbytes
TCP established hash table entries: 8192 (order: 4, 65536 bytes)
TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
TCP: Hash tables configured (established 8192 bind 8192)
NET: Registered protocol family 1
ReiserFS: hda2: found reiserfs format "3.6" with standard journal
ReiserFS: hda2: using ordered data mode
ReiserFS: hda2: journal params: device hda2, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30
ReiserFS: hda2: checking transaction log (hda2)
ReiserFS: hda2: Using r5 hash to sort names
VFS: Mounted root (reiserfs filesystem) readonly.
Freeing unused kernel memory: 136k freed
Adding 1004016k swap on /dev/hda1.  Priority:-1 extents:1
USB Universal Host Controller Interface driver v2.2
ACPI: PCI interrupt 0000:00:1d.0[A] -> GSI 16 (level, low) -> IRQ 16
uhci_hcd 0000:00:1d.0: Intel Corp. 82801DB/DBL/DBM (ICH4/ICH4-L/ICH4-M) USB UHCI Controller #1
PCI: Setting latency timer of device 0000:00:1d.0 to 64
uhci_hcd 0000:00:1d.0: irq 16, io base 0xe800
uhci_hcd 0000:00:1d.0: new USB bus registered, assigned bus number 1
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 2 ports detected
ACPI: PCI interrupt 0000:00:1d.1[B] -> GSI 19 (level, low) -> IRQ 19
uhci_hcd 0000:00:1d.1: Intel Corp. 82801DB/DBL/DBM (ICH4/ICH4-L/ICH4-M) USB UHCI Controller #2
PCI: Setting latency timer of device 0000:00:1d.1 to 64
uhci_hcd 0000:00:1d.1: irq 19, io base 0xe880
uhci_hcd 0000:00:1d.1: new USB bus registered, assigned bus number 2
hub 2-0:1.0: USB hub found
hub 2-0:1.0: 2 ports detected
ACPI: PCI interrupt 0000:00:1d.2[C] -> GSI 18 (level, low) -> IRQ 18
uhci_hcd 0000:00:1d.2: Intel Corp. 82801DB/DBL/DBM (ICH4/ICH4-L/ICH4-M) USB UHCI Controller #3
PCI: Setting latency timer of device 0000:00:1d.2 to 64
uhci_hcd 0000:00:1d.2: irq 18, io base 0xec00
uhci_hcd 0000:00:1d.2: new USB bus registered, assigned bus number 3
hub 3-0:1.0: USB hub found
hub 3-0:1.0: 2 ports detected
usb 2-1: new full speed USB device using uhci_hcd and address 2
ACPI: PCI interrupt 0000:00:1d.7[D] -> GSI 23 (level, low) -> IRQ 23
ehci_hcd 0000:00:1d.7: Intel Corp. 82801DB/DBM (ICH4/ICH4-M) USB 2.0 EHCI Controller
PCI: Setting latency timer of device 0000:00:1d.7 to 64
ehci_hcd 0000:00:1d.7: irq 23, pci mem 0xffa7fc00
ehci_hcd 0000:00:1d.7: new USB bus registered, assigned bus number 4
PCI: cache line size of 128 is not supported by device 0000:00:1d.7
ehci_hcd 0000:00:1d.7: USB 2.0 initialized, EHCI 1.00, driver 10 Dec 2004
hub 4-0:1.0: USB hub found
hub 4-0:1.0: 6 ports detected
hw_random hardware driver 1.0.0 loaded
usb 2-1: USB disconnect, address 2
usb 2-1: new full speed USB device using uhci_hcd and address 3
HDLC line discipline: version $Revision: 4.8 $, maxframe=4096
N_HDLC line discipline registered.
usb 2-1: usbfs: process 7739 (eciadsl-firmwar) did not claim interface 0 before use
usb 2-1: USB disconnect, address 3
usb 2-1: new full speed USB device using uhci_hcd and address 4
usb 2-1: usbfs: process 7805 (eciadsl-pppoeci) did not claim interface 0 before use
mtrr: base(0xf0020000) is not aligned on a size(0x800000) boundary
Comment 6 Roie Kerstein 2005-03-14 14:13:21 UTC
This is what I got when I tried to enable DMA:

# hdparm -d 1 /dev/hda

/dev/hda:
 setting using_dma to 1 (on)
 HDIO_SET_DMA failed: Operation not permitted
 using_dma    =  0 (off)
Comment 7 Daniel Drake (RETIRED) gentoo-dev 2005-03-14 14:24:39 UTC
Your problem is almost certainly DMA. You appear to have completely disabled PCI IDE support in your kernel:
# CONFIG_BLK_DEV_IDEPCI is not set

As well as that you need to set the options which enable DMA (on by default) plus support for the IDE chipset on your motherboard (probably not on by default, depends on your hardware, check with lspci)