APM Suspend + AC Power = Freeze?
Like the title says, I've noticed that trying to suspend my laptop to memory often results in a hang or freeze when I go to wake the machine up. However, unpluging the machine before placing the machine into suspend appears to avoid this issue. Is there a more elegant fix for this?
I'm running Arch 0.7 with the 2.6.7 kernell + cpufreqd on a IBM T23 laptop (1ghz p3 w/512 meg ram). My kernel config for apm is set as follows:
# APM (Advanced Power Management) BIOS Support
CONFIG_APM=y
# CONFIG_APM_IGNORE_USER_SUSPEND is not set
CONFIG_APM_DO_ENABLE=y
CONFIG_APM_CPU_IDLE=y
CONFIG_APM_DISPLAY_BLANK=y
# CONFIG_APM_RTC_IS_GMT is not set
CONFIG_APM_ALLOW_INTS=y
CONFIG_APM_REAL_MODE_POWER_OFF=y
Update: I was able to test out the HDMI adapter as well and the same issue occured. I'm stumped. 10.8.1 maybe.
Similar Messages
-
Firewire without power / Freezing cursor
2 Problems (maybe connected with each other):
- Firewire 400 & 800 on my MacPro ports don't seem to have any electric power to run my FW800-HD (while the HD works perfectly on my Macbook Pro)
- Cursor/Mouse/Keyboard is freezing every (about) 30min. for about 10 seconds, then works again.
Might there be a hardware problem ?
Thanks for helpingI agree - I've just got a new Mac Pro and I'm having the same problem - my time machine which is connected via FW 800 to 400 cable often disconnects and the mouse freezes and disconnects !
Not very good !!!! -
Resume from suspend/ibernation sometimes freeze
When closing the lid of my laptop, my system is set to freeze.
Sometimes when i open the lid i see the graphics turn on (on the login screen) BUT everything is frozen, even the keyboard. If i close and reopen the lid, it somehow turn back to normal.
this message is in dmegs:
------------[ cut here ]------------
[ 4366.308099] WARNING: CPU: 0 PID: 0 at drivers/gpu/drm/i915/intel_display.c:9713 intel_check_page_flip+0xda/0xf0 [i915]()
[ 4366.308100] Kicking stuck page flip: queued at 261481, now 261490
[ 4366.308101] Modules linked in: joydev mousedev ecb arc4 nls_iso8859_1 nls_cp437 vfat fat coretemp intel_rapl iosf_mbi x86_pkg_temp_thermal iwlmvm intel_powerclamp kvm_intel snd_hda_codec_hdmi kvm uvcvideo videobuf2_vmalloc videobuf2_memops videobuf2_core crct10dif_pclmul crc32_pclmul iTCO_wdt v4l2_common crc32c_intel btusb iTCO_vendor_support videodev amdkfd ghash_clmulni_intel mac80211 bluetooth amd_iommu_v2 media aesni_intel aes_x86_64 lrw gf128mul radeon glue_helper ablk_helper cryptd iwlwifi pcspkr evdev psmouse cfg80211 rtsx_pci_ms mac_hid r8169 sparse_keymap ttm serio_raw led_class snd_hda_codec_realtek i2c_i801 memstick ac toshiba_bluetooth thermal toshiba_haps i915 hwmon mii rfkill wmi battery snd_hda_codec_generic button video drm_kms_helper snd_hda_intel snd_hda_controller drm snd_hda_codec
[ 4366.308125] snd_hwdep intel_gtt snd_pcm i2c_algo_bit i2c_core snd_timer ie31200_edac snd mei_me edac_core mei lpc_ich shpchp soundcore processor sch_fq_codel nfs lockd grace sunrpc fscache ext4 crc16 mbcache jbd2 sd_mod rtsx_pci_sdmmc mmc_core atkbd libps2 ahci libahci xhci_pci ehci_pci libata xhci_hcd ehci_hcd usbcore scsi_mod rtsx_pci usb_common i8042 serio
[ 4366.308143] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.19.3-3-ARCH #1
[ 4366.308144] Hardware name: TOSHIBA SATELLITE P50-B-115/VG20SQ, BIOS 1.50 12/09/2014
[ 4366.308145] 0000000000000000 886cbefc2155fb8d ffff88032fa03d18 ffffffff8155d19f
[ 4366.308146] 0000000000000000 ffff88032fa03d70 ffff88032fa03d58 ffffffff81073a4a
[ 4366.308147] ffff88032fa03d58 ffff88032127c000 ffff88031f735000 ffff88031f7351a0
[ 4366.308149] Call Trace:
[ 4366.308150] <IRQ> [<ffffffff8155d19f>] dump_stack+0x4c/0x6e
[ 4366.308159] [<ffffffff81073a4a>] warn_slowpath_common+0x8a/0xc0
[ 4366.308161] [<ffffffff81073ad5>] warn_slowpath_fmt+0x55/0x70
[ 4366.308168] [<ffffffffa051258a>] intel_check_page_flip+0xda/0xf0 [i915]
[ 4366.308175] [<ffffffffa04df968>] ironlake_irq_handler+0x2e8/0xfe0 [i915]
[ 4366.308178] [<ffffffff812be8e0>] ? timerqueue_add+0x60/0xb0
[ 4366.308181] [<ffffffff810dcd69>] ? enqueue_hrtimer+0x29/0xa0
[ 4366.308184] [<ffffffff810cc01e>] handle_irq_event_percpu+0x3e/0x1f0
[ 4366.308185] [<ffffffff810cc211>] handle_irq_event+0x41/0x70
[ 4366.308187] [<ffffffff810cf30e>] handle_edge_irq+0x9e/0x110
[ 4366.308191] [<ffffffff81018242>] handle_irq+0x22/0x40
[ 4366.308193] [<ffffffff8156557f>] do_IRQ+0x4f/0xf0
[ 4366.308195] [<ffffffff8156352d>] common_interrupt+0x6d/0x6d
[ 4366.308195] <EOI> [<ffffffff814215d5>] ? cpuidle_enter_state+0x65/0x190
[ 4366.308198] [<ffffffff814215c1>] ? cpuidle_enter_state+0x51/0x190
[ 4366.308200] [<ffffffff814217e7>] cpuidle_enter+0x17/0x20
[ 4366.308201] [<ffffffff810b4aa8>] cpu_startup_entry+0x388/0x410
[ 4366.308203] [<ffffffff815536b5>] rest_init+0x85/0x90
[ 4366.308205] [<ffffffff818fe020>] start_kernel+0x48e/0x4af
[ 4366.308207] [<ffffffff818fd120>] ? early_idt_handlers+0x120/0x120
[ 4366.308208] [<ffffffff818fd4d7>] x86_64_start_reservations+0x2a/0x2c
[ 4366.308210] [<ffffffff818fd62b>] x86_64_start_kernel+0x152/0x175
[ 4366.308210] ---[ end trace e9f540c04cbb56d5 ]---This happens to me 100% of the time with 3.11.6 and 3.10.17, resuming from suspend results in naught but an underscore top left. VT switching appears to work temporarily, I was able to enter in my user name in the VT, but then everything hung on pressing enter. Not sure about earlier kernel versions because this is a fresh install on this hardware. Happens with and without X.
Hibernate results in an underscore before the computer is able to shut down. I tried using pm_trace and dumping logs before/after as recommended around the internet, pm_trace didn't match any hashes & there are no logs after suspend that get written out as far as I can tell. The computer is also unresponsive to the network. I also tried using pm_debug but I wasn't really sure what I was doing, running the core test I thought shouldn't cause the computer to actually suspend, but it did & there was my underscore again in all its glory.
Wish I knew a way to get some more information.. -
Software for suspend/hibernate and power management?
After working with Arch on my desktop pc for a while, I today installed it on my laptop, as well. Everything works fine so far, but after reading through a lot of articles on the wiki and threads on this board, I'm a little confused about which tools I should use for hibernate/suspend and power management?
Cpufreq-utils, acpid, pm-utils, laptop-mode-tools, etc. What do you recommend for use?
Thanks in advance!
Last edited by mamr (2008-10-25 09:07:14)All that you listed there have different functions. I use all the above on my laptop. Cpufreq-utils enables the frequency scaling, pm-utils (should) enables suspend and/or hibernate, laptop-mode-tools adds some power management functions, etc. Anyways, they're all useful for a laptop. Install, tweak, ask questions
Good luck!
Scott -
SOLVE strange problem with suspend and resume with gnome-power-manager
I have pm-utils and gnome installed.
Suspending and hibernation works well from the command line ($ pm-hibernate and $ pm-suspend). Resuming works without any problems.
Suspending from gnome "Shutdown dialog" works perfectly as well.
However, if suspending is initiated by gnome-power-manager something strange happens: After pressing the power button resuming switches to hibernation and my laptop turns off. Resuming from disk works fine again.
Now, suspending works fine again if I change and save any config file in /etc/pm/.
Here comes the strange thing: It doesn't really matter what I change as long as I save it.
However, as soon as I reboot resuming fails again the way I described above.
Anyone have a clue what's going on?
I get no error messages and I've tried all sorts of boot entries.
Last edited by mehldutt (2007-12-26 19:42:31)After some try and error my guess is that "HAL" is responsible for this problem:
I deinstalled ACPID and 'pm-utils' and switched to 'uswsusp'.
I made the appropriate changes to the appropriate hal-scrips
usr/lib/hal/scripts/hal-system-power-suspend:
#!/bin/sh
/sbin/s2ram --force
usr/lib/hal/scripts/hal-system-power-hibernate:
#!/bin/sh
/sbin/s2disk
After these changes I still have the same problem: immidiatly after resuming form suspend (via power-button) my laptop hibernates (s2disk).
However, if I delete all entries in "usr/lib/hal/scripts/hal-system-power-hibernate" resuming from suspend works fine again, but hibernate doesn't of course. So, some script must be calling "usr/lib/hal/scripts/hal-system-power-hibernate" emmediatly after resuming from suspend.
A couple of weeks ago everything worked fine. My guess is that one of the recent hal-updates is causing this.
How can I figure what script is calling "usr/lib/hal/scripts/hal-system-power-hibernate" after resuming from suspend? -
Hi All,
After a update of my laptop, it does not fully wakes after going into suspend. It does not react to numlock anymore. I have to push the power button for 10 seconds to shut it down.
/var/log/everything.log, normal operations:
Jul 21 03:42:38 localhost dhcpcd[1029]: wlan0: sending IPv6 Router Solicitation
Jul 21 03:42:38 localhost dhcpcd[1029]: wlan0: sendmsg: Cannot assign requested address
Jul 21 03:42:38 localhost dhcpcd[1029]: wlan0: no IPv6 Routers available
Jul 21 03:42:45 localhost dbus[533]: [system] Activating service name='org.freedesktop.ConsoleKit' (using servicehelper)
Jul 21 03:42:45 localhost dbus[533]: [system] Successfully activated service 'org.freedesktop.ConsoleKit'
Jul 21 03:42:45 localhost acpid: client connected from 1134[0:1000]
Jul 21 03:42:45 localhost acpid: 1 client rule loaded
Jul 21 03:42:46 localhost NetworkManager[559]: <info> (wlan0): IP6 addrconf timed out or failed.
Jul 21 03:42:46 localhost NetworkManager[559]: <info> Activation (wlan0) Stage 4 of 5 (IPv6 Configure Timeout) scheduled...
Jul 21 03:42:46 localhost NetworkManager[559]: <info> Activation (wlan0) Stage 4 of 5 (IPv6 Configure Timeout) started...
Jul 21 03:42:46 localhost NetworkManager[559]: <info> Activation (wlan0) Stage 4 of 5 (IPv6 Configure Timeout) complete.
Jul 21 03:42:50 localhost acpid: client connected from 1134[0:1000]
Jul 21 03:42:50 localhost acpid: 1 client rule loaded
Jul 21 03:42:55 localhost kernel: [ 48.812457] fuse init (API version 7.18)
Jul 21 03:42:59 localhost dbus[533]: [system] Activating service name='org.freedesktop.UDisks2' (using servicehelper)
Jul 21 03:42:59 localhost udisksd[1209]: udisks daemon version 1.94.0 starting
Jul 21 03:42:59 localhost dbus[533]: [system] Successfully activated service 'org.freedesktop.UDisks2'
Jul 21 03:42:59 localhost udisksd[1209]: Acquired the name org.freedesktop.UDisks2 on the system message bus
Jul 21 04:01:01 localhost /USR/SBIN/CROND[1363]: (root) CMD (run-parts /etc/cron.hourly)
Jul 21 04:01:01 localhost anacron[1369]: Anacron started on 2012-07-21
Jul 21 04:01:01 localhost anacron[1369]: Will run job `cron.daily' in 42 min.
Jul 21 04:01:01 localhost anacron[1369]: Jobs will be executed sequentially
Jul 21 04:21:01 localhost -- MARK --
/var/log/everything.log, after starting suspend:
Jul 21 04:21:13 localhost kernel: [ 2346.821030] EXT4-fs (sda5): re-mounted. Opts: commit=0
Jul 21 04:21:13 localhost kernel: [ 2347.000872] EXT4-fs (sda8): re-mounted. Opts: commit=0
Jul 21 04:25:10 localhost kernel: [ 2349.512404] PM: Syncing filesystems ... done.
Jul 21 04:25:10 localhost kernel: [ 2349.514874] PM: Preparing system for mem sleep
Jul 21 04:25:10 localhost kernel: [ 2349.514891] Freezing user space processes ... (elapsed 0.01 seconds) done.
Jul 21 04:25:10 localhost kernel: [ 2349.526541] Freezing remaining freezable tasks ... (elapsed 0.01 seconds) done.
Jul 21 04:25:10 localhost kernel: [ 2349.539896] PM: Entering mem sleep
Jul 21 04:25:10 localhost kernel: [ 2349.539930] Suspending console(s) (use no_console_suspend to debug)
Jul 21 04:25:10 localhost kernel: [ 2349.573787] sd 0:0:0:0: [sda] Synchronizing SCSI cache
Jul 21 04:25:10 localhost kernel: [ 2349.611052] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:10 localhost kernel: [ 2349.613512] sd 0:0:0:0: [sda] Stopping disk
Jul 21 04:25:10 localhost kernel: [ 2350.236650] PM: suspend of devices complete after 696.314 msecs
Jul 21 04:25:10 localhost kernel: [ 2350.236925] PM: late suspend of devices complete after 0.270 msecs
Jul 21 04:25:10 localhost kernel: [ 2350.237272] r8169 0000:08:00.0: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.266603] ehci_hcd 0000:00:1d.7: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.303271] uhci_hcd 0000:00:1d.1: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.326605] uhci_hcd 0000:00:1d.0: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.343218] ehci_hcd 0000:00:1a.7: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.379942] uhci_hcd 0000:00:1a.2: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.403292] uhci_hcd 0000:00:1a.1: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.426606] uhci_hcd 0000:00:1a.0: wake-up capability enabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.426678] PM: noirq suspend of devices complete after 189.749 msecs
Jul 21 04:25:10 localhost kernel: [ 2350.427140] ACPI: Preparing to enter system sleep state S3
Jul 21 04:25:10 localhost kernel: [ 2350.519991] PM: Saving platform NVS memory
Jul 21 04:25:10 localhost kernel: [ 2350.520810] Disabling non-boot CPUs ...
Jul 21 04:25:10 localhost kernel: [ 2350.623205] CPU 1 is now offline
Jul 21 04:25:10 localhost kernel: [ 2350.623688] Extended CMOS year: 2000
Jul 21 04:25:10 localhost kernel: [ 2350.623688] ACPI: Low-level resume complete
Jul 21 04:25:10 localhost kernel: [ 2350.623688] PM: Restoring platform NVS memory
Jul 21 04:25:10 localhost kernel: [ 2350.623688] Extended CMOS year: 2000
Jul 21 04:25:10 localhost kernel: [ 2350.623688] Enabling non-boot CPUs ...
Jul 21 04:25:10 localhost kernel: [ 2350.630554] Booting Node 0 Processor 1 APIC 0x1
Jul 21 04:25:10 localhost kernel: [ 2350.641916] NMI watchdog: enabled, takes one hw-pmu counter.
Jul 21 04:25:10 localhost kernel: [ 2350.645407] CPU1 is up
Jul 21 04:25:10 localhost kernel: [ 2350.647122] ACPI: Waking up from system sleep state S3
Jul 21 04:25:10 localhost kernel: [ 2350.653227] uhci_hcd 0000:00:1a.0: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.659889] uhci_hcd 0000:00:1a.1: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.666555] uhci_hcd 0000:00:1a.2: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.683204] ehci_hcd 0000:00:1a.7: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.689888] uhci_hcd 0000:00:1d.0: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.696556] uhci_hcd 0000:00:1d.1: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.713204] ehci_hcd 0000:00:1d.7: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.715075] PM: noirq resume of devices complete after 67.761 msecs
Jul 21 04:25:10 localhost kernel: [ 2350.715286] PM: early resume of devices complete after 0.105 msecs
Jul 21 04:25:10 localhost kernel: [ 2350.715344] uhci_hcd 0000:00:1a.0: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715373] usb usb1: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715391] uhci_hcd 0000:00:1a.1: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715421] usb usb2: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715437] uhci_hcd 0000:00:1a.2: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715465] usb usb3: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715480] ehci_hcd 0000:00:1a.7: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715521] uhci_hcd 0000:00:1d.0: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715540] snd_hda_intel 0000:00:1b.0: irq 47 for MSI/MSI-X
Jul 21 04:25:10 localhost kernel: [ 2350.715550] usb usb4: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715571] uhci_hcd 0000:00:1d.1: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715601] usb usb5: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715611] uhci_hcd 0000:00:1d.2: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715623] ehci_hcd 0000:00:1d.7: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715639] usb usb6: root hub lost power or was reset
Jul 21 04:25:10 localhost kernel: [ 2350.715647] pci 0000:00:1e.0: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715663] ata_piix 0000:00:1f.2: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715667] ata_piix 0000:00:1f.5: setting latency timer to 64
Jul 21 04:25:10 localhost kernel: [ 2350.715690] r8169 0000:08:00.0: wake-up capability disabled by ACPI
Jul 21 04:25:10 localhost kernel: [ 2350.723377] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:10 localhost kernel: [ 2350.723395] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:10 localhost kernel: [ 2350.816609] r8169 0000:08:00.0: eth0: link down
Jul 21 04:25:10 localhost kernel: [ 2351.111777] ata4: SATA link down (SStatus 0 SControl 300)
Jul 21 04:25:10 localhost kernel: [ 2351.128460] ata3: SATA link down (SStatus 0 SControl 300)
Jul 21 04:25:10 localhost kernel: [ 2351.199920] usb 2-1: reset low-speed USB device number 2 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2351.263475] ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
Jul 21 04:25:10 localhost kernel: [ 2351.276859] firewire_core 0000:1a:00.0: rediscovered device fw0
Jul 21 04:25:10 localhost kernel: [ 2351.283960] ata2.00: configured for UDMA/100
Jul 21 04:25:10 localhost kernel: [ 2351.739942] usb 2-2: reset low-speed USB device number 3 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2352.129932] usb 8-2: reset high-speed USB device number 2 using ehci_hcd
Jul 21 04:25:10 localhost kernel: [ 2352.359839] usb 6-1: reset full-speed USB device number 2 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2352.784239] usb 6-1.1: reset full-speed USB device number 3 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2352.883229] btusb 6-1.1:1.0: no reset_resume for driver btusb?
Jul 21 04:25:10 localhost kernel: [ 2352.883233] btusb 6-1.1:1.1: no reset_resume for driver btusb?
Jul 21 04:25:10 localhost kernel: [ 2352.941243] usb 6-1.2: reset full-speed USB device number 4 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2352.969919] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
Jul 21 04:25:10 localhost kernel: [ 2353.101249] usb 6-1.3: reset full-speed USB device number 5 using uhci_hcd
Jul 21 04:25:10 localhost kernel: [ 2353.181194] ata1.00: configured for UDMA/133
Jul 21 04:25:10 localhost kernel: [ 2353.181463] sd 0:0:0:0: [sda] Starting disk
Jul 21 04:25:10 localhost kernel: [ 2353.436737] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
Jul 21 04:25:10 localhost kernel: [ 2358.057138] PM: resume of devices complete after 7341.844 msecs
Jul 21 04:25:10 localhost kernel: [ 2358.057602] PM: Finishing wakeup.
Jul 21 04:25:10 localhost kernel: [ 2358.057604] Restarting tasks ... done.
Jul 21 04:25:10 localhost kernel: [ 2358.064234] video LNXVIDEO:00: Restoring backlight state
Jul 21 04:25:11 localhost kernel: [ 2358.233575] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:11 localhost kernel: [ 2358.272368] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:11 localhost kernel: [ 2358.309721] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:11 localhost kernel: [ 2358.349601] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:25:13 localhost kernel: [ 2360.644416] EXT4-fs (sda5): re-mounted. Opts: commit=0
Jul 21 04:25:13 localhost kernel: [ 2360.648163] EXT4-fs (sda8): re-mounted. Opts: commit=0
Jul 21 04:25:13 localhost acpid: client 1134[0:1000] has disconnected
Jul 21 04:25:13 localhost acpid: client 1134[0:1000] has disconnected
Jul 21 04:25:13 localhost acpid: client connected from 1134[0:1000]
Jul 21 04:25:13 localhost acpid: 1 client rule loaded
Jul 21 04:25:26 localhost kernel: [ 2373.415894] NVRM: Xid (0000:01:00): 8, Channel 0000007e
Jul 21 04:25:26 localhost kernel: [ 2373.700350] hrtimer: interrupt took 91847280 ns
Jul 21 04:25:26 localhost kernel: [ 2373.700352] NVRM: GPU at 0000:01:00.0 has fallen off the bus.
Jul 21 04:28:36 localhost kernel: [ 2563.568752] EXT4-fs (sda5): re-mounted. Opts: commit=0
Jul 21 04:28:36 localhost kernel: [ 2563.573610] EXT4-fs (sda8): re-mounted. Opts: commit=0
What does this message mean?
Jul 21 04:25:26 localhost kernel: [ 2373.700352] NVRM: GPU at 0000:01:00.0 has fallen off the bus.
What can i do to solve this?
Best regards,
Cedric
Last edited by cdwijs (2012-08-09 18:33:34)I did a quick google search. This page suggested that I set my videocard in persistend mode:
http://scientificlinuxforum.org/index.p … topic=1469
So i did the following:
]# /usr/bin/nvidia-smi -pm 1
Enabled persistence mode for GPU 0000:01:00.0.
All done.
# /usr/bin/nvidia-smi -q
==============NVSMI LOG==============
Timestamp : Sat Jul 21 04:58:55 2012
Driver Version : 302.17
Attached GPUs : 1
GPU 0000:01:00.0
Product Name : GeForce 9600M GS
Display Mode : N/A
Persistence Mode : Enabled
Driver Model
Current : N/A
Pending : N/A
Serial Number : N/A
GPU UUID : N/A
VBIOS Version : 62.94.8D.00.0B
Inforom Version
OEM Object : N/A
ECC Object : N/A
Power Management Object : N/A
PCI
Bus : 0x01
Device : 0x00
Domain : 0x0000
Device Id : 0x064810DE
Bus Id : 0000:01:00.0
Sub System Id : 0x02C01028
GPU Link Info
PCIe Generation
Max : N/A
Current : N/A
Link Width
Max : N/A
Current : N/A
Fan Speed : N/A
Performance State : N/A
Memory Usage
Total : 511 MB
Used : 30 MB
Free : 480 MB
Compute Mode : Default
Utilization
Gpu : N/A
Memory : N/A
Ecc Mode
Current : N/A
Pending : N/A
ECC Errors
Volatile
Single Bit
Device Memory : N/A
Register File : N/A
L1 Cache : N/A
L2 Cache : N/A
Total : N/A
Double Bit
Device Memory : N/A
Register File : N/A
L1 Cache : N/A
L2 Cache : N/A
Total : N/A
Aggregate
Single Bit
Device Memory : N/A
Register File : N/A
L1 Cache : N/A
L2 Cache : N/A
Total : N/A
Double Bit
Device Memory : N/A
Register File : N/A
L1 Cache : N/A
L2 Cache : N/A
Total : N/A
Temperature
Gpu : 61 C
Power Readings
Power Management : N/A
Power Draw : N/A
Power Limit : N/A
Clocks
Graphics : N/A
SM : N/A
Memory : N/A
Max Clocks
Graphics : N/A
SM : N/A
Memory : N/A
Compute Processes : Not Supported
This did not solve the issue. The laptop goes into suspend (the power LED starts blinking), but when the power button is then briefly pressed, the machine does power-up, but after hearing 2 clicks from the speaker, i get a black screen, a full-running CPU fan, and no reaction to numlock.
/var/log/everything.log:
Jul 21 04:30:13 localhost NetworkManager[565]: <info> Activation (wlan0) Stage 4 of 5 (IPv6 Configure Timeout) complete.
Jul 21 04:50:40 localhost -- MARK --
Jul 21 04:54:46 localhost kernel: [ 1516.765698] EXT4-fs (sda5): re-mounted. Opts: commit=0
Jul 21 04:54:46 localhost kernel: [ 1516.942964] EXT4-fs (sda8): re-mounted. Opts: commit=0
Jul 21 04:55:02 localhost kernel: [ 1519.654895] PM: Syncing filesystems ... done.
Jul 21 04:55:02 localhost kernel: [ 1519.657049] PM: Preparing system for mem sleep
Jul 21 04:55:02 localhost kernel: [ 1519.657066] Freezing user space processes ... (elapsed 0.01 seconds) done.
Jul 21 04:55:02 localhost kernel: [ 1519.669943] Freezing remaining freezable tasks ... (elapsed 0.01 seconds) done.
Jul 21 04:55:02 localhost kernel: [ 1519.683296] PM: Entering mem sleep
Jul 21 04:55:02 localhost kernel: [ 1519.683337] Suspending console(s) (use no_console_suspend to debug)
Jul 21 04:55:02 localhost kernel: [ 1519.717139] sd 0:0:0:0: [sda] Synchronizing SCSI cache
Jul 21 04:55:02 localhost kernel: [ 1519.749832] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1519.786781] sd 0:0:0:0: [sda] Stopping disk
Jul 21 04:55:02 localhost kernel: [ 1520.410064] PM: suspend of devices complete after 726.343 msecs
Jul 21 04:55:02 localhost kernel: [ 1520.410337] PM: late suspend of devices complete after 0.266 msecs
Jul 21 04:55:02 localhost kernel: [ 1520.410678] r8169 0000:08:00.0: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.440024] ehci_hcd 0000:00:1d.7: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.476689] uhci_hcd 0000:00:1d.1: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.500023] uhci_hcd 0000:00:1d.0: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.516685] ehci_hcd 0000:00:1a.7: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.553353] uhci_hcd 0000:00:1a.2: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.576688] uhci_hcd 0000:00:1a.1: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.603354] uhci_hcd 0000:00:1a.0: wake-up capability enabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.603426] PM: noirq suspend of devices complete after 193.085 msecs
Jul 21 04:55:02 localhost kernel: [ 1520.603888] ACPI: Preparing to enter system sleep state S3
Jul 21 04:55:02 localhost kernel: [ 1520.693403] PM: Saving platform NVS memory
Jul 21 04:55:02 localhost kernel: [ 1520.694218] Disabling non-boot CPUs ...
Jul 21 04:55:02 localhost kernel: [ 1520.796623] CPU 1 is now offline
Jul 21 04:55:02 localhost kernel: [ 1520.797088] Extended CMOS year: 2000
Jul 21 04:55:02 localhost kernel: [ 1520.797088] ACPI: Low-level resume complete
Jul 21 04:55:02 localhost kernel: [ 1520.797088] PM: Restoring platform NVS memory
Jul 21 04:55:02 localhost kernel: [ 1520.797088] Extended CMOS year: 2000
Jul 21 04:55:02 localhost kernel: [ 1520.797088] Enabling non-boot CPUs ...
Jul 21 04:55:02 localhost kernel: [ 1520.803951] Booting Node 0 Processor 1 APIC 0x1
Jul 21 04:55:02 localhost kernel: [ 1520.815303] NMI watchdog: enabled, takes one hw-pmu counter.
Jul 21 04:55:02 localhost kernel: [ 1520.816608] CPU1 is up
Jul 21 04:55:02 localhost kernel: [ 1520.818293] ACPI: Waking up from system sleep state S3
Jul 21 04:55:02 localhost kernel: [ 1520.823322] uhci_hcd 0000:00:1a.0: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.829975] uhci_hcd 0000:00:1a.1: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.836638] uhci_hcd 0000:00:1a.2: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.853290] ehci_hcd 0000:00:1a.7: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.859971] uhci_hcd 0000:00:1d.0: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.866638] uhci_hcd 0000:00:1d.1: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.883290] ehci_hcd 0000:00:1d.7: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.885162] PM: noirq resume of devices complete after 66.681 msecs
Jul 21 04:55:02 localhost kernel: [ 1520.885372] PM: early resume of devices complete after 0.105 msecs
Jul 21 04:55:02 localhost kernel: [ 1520.885432] uhci_hcd 0000:00:1a.0: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885432] uhci_hcd 0000:00:1a.1: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885465] usb usb1: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885466] usb usb2: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885487] uhci_hcd 0000:00:1a.2: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885490] ehci_hcd 0000:00:1a.7: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885518] usb usb3: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885549] uhci_hcd 0000:00:1d.0: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885582] usb usb4: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885582] snd_hda_intel 0000:00:1b.0: irq 48 for MSI/MSI-X
Jul 21 04:55:02 localhost kernel: [ 1520.885600] uhci_hcd 0000:00:1d.1: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885629] usb usb5: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885648] uhci_hcd 0000:00:1d.2: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885653] ehci_hcd 0000:00:1d.7: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885680] pci 0000:00:1e.0: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885679] usb usb6: root hub lost power or was reset
Jul 21 04:55:02 localhost kernel: [ 1520.885698] ata_piix 0000:00:1f.2: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885713] ata_piix 0000:00:1f.5: setting latency timer to 64
Jul 21 04:55:02 localhost kernel: [ 1520.885736] r8169 0000:08:00.0: wake-up capability disabled by ACPI
Jul 21 04:55:02 localhost kernel: [ 1520.890553] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1520.891048] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1520.960285] r8169 0000:08:00.0: eth0: link down
Jul 21 04:55:02 localhost kernel: [ 1521.281391] ata3: SATA link down (SStatus 0 SControl 300)
Jul 21 04:55:02 localhost kernel: [ 1521.297666] ata4: SATA link down (SStatus 0 SControl 300)
Jul 21 04:55:02 localhost kernel: [ 1521.332377] Extended CMOS year: 2000
Jul 21 04:55:02 localhost kernel: [ 1521.376657] usb 2-1: reset low-speed USB device number 2 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1521.406940] ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 300)
Jul 21 04:55:02 localhost kernel: [ 1521.427670] ata2.00: configured for UDMA/100
Jul 21 04:55:02 localhost acpid: client 1147[0:1000] has disconnected
Jul 21 04:55:02 localhost acpid: client 1147[0:1000] has disconnected
Jul 21 04:55:02 localhost kernel: [ 1521.453328] firewire_core 0000:1a:00.0: rediscovered device fw0
Jul 21 04:55:02 localhost kernel: [ 1521.915219] usb 2-2: reset low-speed USB device number 3 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1522.303337] usb 8-2: reset high-speed USB device number 2 using ehci_hcd
Jul 21 04:55:02 localhost kernel: [ 1522.533339] usb 6-1: reset full-speed USB device number 2 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1522.955078] usb 6-1.1: reset full-speed USB device number 3 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1523.057065] btusb 6-1.1:1.0: no reset_resume for driver btusb?
Jul 21 04:55:02 localhost kernel: [ 1523.057070] btusb 6-1.1:1.1: no reset_resume for driver btusb?
Jul 21 04:55:02 localhost kernel: [ 1523.113342] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
Jul 21 04:55:02 localhost kernel: [ 1523.115078] usb 6-1.2: reset full-speed USB device number 4 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1523.278082] usb 6-1.3: reset full-speed USB device number 5 using uhci_hcd
Jul 21 04:55:02 localhost kernel: [ 1523.321369] ata1.00: configured for UDMA/133
Jul 21 04:55:02 localhost kernel: [ 1523.321637] sd 0:0:0:0: [sda] Starting disk
Jul 21 04:55:02 localhost kernel: [ 1523.613501] b43-phy0: Loading firmware version 666.2 (2011-02-23 01:15:07)
Jul 21 04:55:02 localhost kernel: [ 1528.234017] PM: resume of devices complete after 7348.637 msecs
Jul 21 04:55:02 localhost kernel: [ 1528.234472] PM: Finishing wakeup.
Jul 21 04:55:02 localhost kernel: [ 1528.234474] Restarting tasks ... done.
Jul 21 04:55:02 localhost kernel: [ 1528.239320] video LNXVIDEO:00: Restoring backlight state
Jul 21 04:55:02 localhost acpid: client connected from 1147[0:1000]
Jul 21 04:55:02 localhost acpid: 1 client rule loaded
Jul 21 04:55:02 localhost kernel: [ 1528.396372] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1528.433245] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1528.469720] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:02 localhost kernel: [ 1528.506634] sdhci-pci 0000:1a:00.1: Will use DMA mode even though HW doesn't fully claim to support it.
Jul 21 04:55:03 localhost kernel: [ 1530.007718] EXT4-fs (sda5): re-mounted. Opts: commit=0
Jul 21 04:55:04 localhost kernel: [ 1530.271879] EXT4-fs (sda8): re-mounted. Opts: commit=0
Jul 21 04:55:55 localhost kernel: [ 0.000000] Initializing cgroup subsys cpuset
Jul 21 04:55:55 localhost kernel: [ 0.000000] Initializing cgroup subsys cpu
Interestingly, the message that the GPU has fallen off the bus is no longer present. Something else is going on as well :-)
Best regards,
Cedric -
Acer Aspire E13 : Suspend/Poweroff don't Work
Hi !
I just got hold of a nice new laptop, An Acer Aspire E 13 (ES1-311-C1E8) and I've been running into a couple of issues.
I've already tried Ubuntu on this device and the issues are not present.
Two Big ones really,
On Poweroff, it doesn't actually shut down, it seems to complete the shutdown process, the screen goes black, but the hard drive keeps spinning, and the power light remains on. Not entirely sure why.
The bigger issue is Suspend : On closing the lid, using the suspend button, using the power button, or using (sudo) pm-suspend, it just freezes. the /var/log/pm-suspend.log claims that the suspend succeeded but I cannot resume it from suspend (Tried every key on the keyboard, touchpad and power button)
Here's the output of lsmod :
[jordan@e13 log]$ lsmod
Module Size Used by
btrfs 934835 0
xor 21040 1 btrfs
raid6_pq 99334 1 btrfs
ufs 73310 0
hfsplus 101557 0
hfs 53889 0
minix 35479 0
ntfs 202187 0
vfat 21231 0
msdos 17046 0
fat 62032 2 vfat,msdos
jfs 181524 0
xfs 849801 0
libcrc32c 12426 1 xfs
rfcomm 62023 2
fuse 87590 3
ctr 12927 3
ccm 17534 3
bnep 17349 2
ecb 12737 1
snd_hda_codec_hdmi 49263 1
uvcvideo 84822 0
snd_hda_codec_realtek 67322 1
snd_hda_codec_generic 63087 1 snd_hda_codec_realtek
videobuf2_vmalloc 13286 1 uvcvideo
videobuf2_memops 12519 1 videobuf2_vmalloc
joydev 17063 0
videobuf2_core 39635 1 uvcvideo
arc4 12536 2
i915 1002472 3
ath9k 129093 0
mousedev 17272 0
v4l2_common 12814 1 videobuf2_core
ath9k_common 26722 1 ath9k
ath9k_hw 428874 2 ath9k_common,ath9k
acer_wmi 17603 0
snd_hda_intel 26387 5
sparse_keymap 12818 1 acer_wmi
drm_kms_helper 98881 1 i915
videodev 135040 3 uvcvideo,v4l2_common,videobuf2_core
media 18365 2 uvcvideo,videodev
ath 26067 3 ath9k_common,ath9k,ath9k_hw
led_class 12855 2 ath9k,acer_wmi
mac80211 648753 1 ath9k
iTCO_wdt 12831 0
iTCO_vendor_support 12649 1 iTCO_wdt
cfg80211 476584 4 ath,ath9k_common,ath9k,mac80211
snd_hda_controller 26857 1 snd_hda_intel
evdev 21544 14
psmouse 107442 0
snd_hda_codec 112621 5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel,snd_hda_controller
snd_hwdep 17244 1 snd_hda_codec
drm 273125 5 i915,drm_kms_helper
snd_pcm 88779 5 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_controller
mac_hid 12633 0
mei_txe 18098 0
intel_gtt 17848 1 i915
snd_timer 26614 1 snd_pcm
serio_raw 12849 0
coretemp 12820 0
hwmon 12930 1 coretemp
ath3k 12685 0
btusb 30036 0
intel_rapl 17605 0
r8169 76869 0
bluetooth 433830 27 bnep,ath3k,btusb,rfcomm
snd 73436 17 snd_hda_codec_realtek,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
mii 12675 1 r8169
intel_powerclamp 17122 0
rfkill 18867 6 cfg80211,acer_wmi,bluetooth
mei 75468 1 mei_txe
kvm_intel 143417 0
kvm 435299 1 kvm_intel
i2c_i801 16965 0
i2c_algo_bit 12744 1 i915
i2c_core 50240 7 drm,i915,i2c_i801,drm_kms_helper,i2c_algo_bit,v4l2_common,videodev
pcspkr 12595 0
rtsx_pci_ms 16898 0
memstick 13696 1 rtsx_pci_ms
thermal 17559 0
ac 12715 0
video 22205 2 i915,acer_wmi
battery 17452 0
iosf_mbi 12682 1 intel_rapl
soundcore 13031 2 snd,snd_hda_codec
lpc_ich 20768 0
fan 12726 0
shpchp 35210 0
wmi 17339 1 acer_wmi
button 12953 1 i915
processor 27777 0
sch_fq_codel 17343 6
xts 12679 1
gf128mul 12970 1 xts
algif_skcipher 17051 0
af_alg 12988 1 algif_skcipher
sd_mod 43575 3
rtsx_pci_sdmmc 21261 0
mmc_core 110613 1 rtsx_pci_sdmmc
atkbd 22254 0
libps2 12739 2 atkbd,psmouse
ahci 33248 2
libahci 27215 1 ahci
crct10dif_pclmul 13394 0
crc32_pclmul 12915 0
xhci_pci 12675 0
crc32c_intel 21809 2
xhci_hcd 152471 1 xhci_pci
libata 181461 2 ahci,libahci
ehci_pci 12512 0
ehci_hcd 69979 1 ehci_pci
ghash_clmulni_intel 12978 0
cryptd 18553 1 ghash_clmulni_intel
rtsx_pci 41994 2 rtsx_pci_ms,rtsx_pci_sdmmc
scsi_mod 147395 2 libata,sd_mod
usbcore 199382 7 ath3k,btusb,uvcvideo,ehci_hcd,ehci_pci,xhci_hcd,xhci_pci
usb_common 12561 1 usbcore
i8042 18002 2 acer_wmi,libps2
serio 18282 6 serio_raw,atkbd,i8042,psmouse
sha512_ssse3 41814 0
sha512_generic 12632 1 sha512_ssse3
sha256_ssse3 25692 0
sha256_generic 16804 1 sha256_ssse3
aes_x86_64 16719 9
ext4 514390 2
crc16 12343 2 ext4,bluetooth
mbcache 17171 1 ext4
jbd2 86379 1 ext4
dm_crypt 22551 1
dm_mod 93753 9 dm_crypt
[jordan@e13 log]$ sudo lsmod
[sudo] password for jordan:
Module Size Used by
btrfs 934835 0
xor 21040 1 btrfs
raid6_pq 99334 1 btrfs
ufs 73310 0
hfsplus 101557 0
hfs 53889 0
minix 35479 0
ntfs 202187 0
vfat 21231 0
msdos 17046 0
fat 62032 2 vfat,msdos
jfs 181524 0
xfs 849801 0
libcrc32c 12426 1 xfs
rfcomm 62023 2
fuse 87590 3
ctr 12927 3
ccm 17534 3
bnep 17349 2
ecb 12737 1
snd_hda_codec_hdmi 49263 1
uvcvideo 84822 0
snd_hda_codec_realtek 67322 1
snd_hda_codec_generic 63087 1 snd_hda_codec_realtek
videobuf2_vmalloc 13286 1 uvcvideo
videobuf2_memops 12519 1 videobuf2_vmalloc
joydev 17063 0
videobuf2_core 39635 1 uvcvideo
arc4 12536 2
i915 1002472 3
ath9k 129093 0
mousedev 17272 0
v4l2_common 12814 1 videobuf2_core
ath9k_common 26722 1 ath9k
ath9k_hw 428874 2 ath9k_common,ath9k
acer_wmi 17603 0
snd_hda_intel 26387 5
sparse_keymap 12818 1 acer_wmi
drm_kms_helper 98881 1 i915
videodev 135040 3 uvcvideo,v4l2_common,videobuf2_core
media 18365 2 uvcvideo,videodev
ath 26067 3 ath9k_common,ath9k,ath9k_hw
led_class 12855 2 ath9k,acer_wmi
mac80211 648753 1 ath9k
iTCO_wdt 12831 0
iTCO_vendor_support 12649 1 iTCO_wdt
cfg80211 476584 4 ath,ath9k_common,ath9k,mac80211
snd_hda_controller 26857 1 snd_hda_intel
evdev 21544 14
psmouse 107442 0
snd_hda_codec 112621 5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel,snd_hda_controller
snd_hwdep 17244 1 snd_hda_codec
drm 273125 5 i915,drm_kms_helper
snd_pcm 88779 5 snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_controller
mac_hid 12633 0
mei_txe 18098 0
intel_gtt 17848 1 i915
snd_timer 26614 1 snd_pcm
serio_raw 12849 0
coretemp 12820 0
hwmon 12930 1 coretemp
ath3k 12685 0
btusb 30036 0
intel_rapl 17605 0
r8169 76869 0
bluetooth 433830 27 bnep,ath3k,btusb,rfcomm
snd 73436 17 snd_hda_codec_realtek,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel
mii 12675 1 r8169
intel_powerclamp 17122 0
rfkill 18867 6 cfg80211,acer_wmi,bluetooth
mei 75468 1 mei_txe
kvm_intel 143417 0
kvm 435299 1 kvm_intel
i2c_i801 16965 0
i2c_algo_bit 12744 1 i915
i2c_core 50240 7 drm,i915,i2c_i801,drm_kms_helper,i2c_algo_bit,v4l2_common,videodev
pcspkr 12595 0
rtsx_pci_ms 16898 0
memstick 13696 1 rtsx_pci_ms
thermal 17559 0
ac 12715 0
video 22205 2 i915,acer_wmi
battery 17452 0
iosf_mbi 12682 1 intel_rapl
soundcore 13031 2 snd,snd_hda_codec
lpc_ich 20768 0
fan 12726 0
shpchp 35210 0
wmi 17339 1 acer_wmi
button 12953 1 i915
processor 27777 0
sch_fq_codel 17343 6
xts 12679 1
gf128mul 12970 1 xts
algif_skcipher 17051 0
af_alg 12988 1 algif_skcipher
sd_mod 43575 3
rtsx_pci_sdmmc 21261 0
mmc_core 110613 1 rtsx_pci_sdmmc
atkbd 22254 0
libps2 12739 2 atkbd,psmouse
ahci 33248 2
libahci 27215 1 ahci
crct10dif_pclmul 13394 0
crc32_pclmul 12915 0
xhci_pci 12675 0
crc32c_intel 21809 2
xhci_hcd 152471 1 xhci_pci
libata 181461 2 ahci,libahci
ehci_pci 12512 0
ehci_hcd 69979 1 ehci_pci
ghash_clmulni_intel 12978 0
cryptd 18553 1 ghash_clmulni_intel
rtsx_pci 41994 2 rtsx_pci_ms,rtsx_pci_sdmmc
scsi_mod 147395 2 libata,sd_mod
usbcore 199382 7 ath3k,btusb,uvcvideo,ehci_hcd,ehci_pci,xhci_hcd,xhci_pci
usb_common 12561 1 usbcore
i8042 18002 2 acer_wmi,libps2
serio 18282 6 serio_raw,atkbd,i8042,psmouse
sha512_ssse3 41814 0
sha512_generic 12632 1 sha512_ssse3
sha256_ssse3 25692 0
sha256_generic 16804 1 sha256_ssse3
aes_x86_64 16719 9
ext4 514390 2
crc16 12343 2 ext4,bluetooth
mbcache 17171 1 ext4
jbd2 86379 1 ext4
dm_crypt 22551 1
dm_mod 93753 9 dm_crypt
I don't know if anyone has had similar issues, or found any way around this, or if anyone knows what the ubuntu devs have added to fix things ?
edit : Attempted using lts kernel, No improvement
Thanks in advance
-jman6495
Last edited by jman6495 (2015-03-29 20:57:57)jman6495:
I had exactly the same problem with my Acer ES1-512 laptop. Tried a bunch of kernels, systemd versions, tried pm-utils, systemctl. Instantly freezed on suspend, and didn't turn off the computer neither with "systemctl poweroff", neither with "sudo poweroff".
A few days ago I've found the solution (or at least for my laptop): In the BIOS settings I had to disable the "xHCI support (external USB 3.0 controller)". Maybe not the best solution, but it works for me.
Also, it's worth mentioning that I disabled UEFI in the BIOS and using legacy mode instead (installed Arch this way).
I hope this helps! -
Gnome 3.16 Can't Suspend With Media Player Open
I have been seeing this problem since I updraded to Gnome 3.16. I use GDM.
Normally when I close the laptop lid, the computer is suspended (the power led changes color and starts blinking). But sometimes, when the lid is closed, the system seems to get stuck. The power led doesnot change color, and when I open the lid after some time, the screen is blank but I can't seem to wake it up. I can hear a slight humming (I guess it's the harddisk). I have to turn it off with the power button, and when I start the computer back there is a bunch of "Orpaned node removed" messages. The longer I leave the system in that state the more is these messages.
After a few hit and trial I figured out that every time the system went to that state there was some media player running (Rhymbox, VLC, Banshee, Audacious). They don't need to be playing, even when they are just open. So I guess the bug is in something common between them. Maybe they have some interface with gnome-shell or gdm to supress screenlock when they are playing and the bug is there?
Here is the output to uname -a
Linux squgeim-V5473 3.19.3-3-ARCH #1 SMP PREEMPT Wed Apr 8 14:10:00 CEST 2015 x86_64 GNU/Linux
Here is the /etc/systemd/login.conf file:
[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
#HandleSuspendKey=suspend
#HandleHibernateKey=hibernate
#HandleLidSwitch=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
I have tried uncommenting the HandleLidSwitch. When uncommented the system is not suspended at all.
Can someone point to any fix or to where exactly the bug is, so I can file a bug report.This issue has since been resolved. I do not know how. I did a system update yesterday and it had updates for linux kernel and gnome, so maybe that was that.
-
Hi
I use a joystick for a game I play in Wine.
If I pm-suspend then the joystick is unusable when I resume.
I guess it's unmounted at suspend and not remounted at resume but, I'm not sure how to go about resolving this issue. I looked through the pm-utils entry in wiki but nothing there helped with my problem.
Any help would be appreciated.
Obviously if you need any info from my side then do say.
TIA
Last edited by Bazzaah (2011-01-28 19:12:53)I did not say anything about reinstalling grub.
Yes, i'm using systemd
When I restart the netbook AFTER suspend-and-resume, instead the grub2 menu I get a blinking cursor and after a minute the following message "Reboot and select proper device..", just as the picture of the original message.
Just to clarify:
Case A:
1- power on netbook
2- grub2 menu
3- Login Archlinux
4- shutdown -r now - > netbook restart
5- grub2 menu, and everything ok
6-
Case B (restart after suspend):
1- power on netbook
2- grub2 menu
3- Login Archlinux
4- close lid -> suspend -> power led blinking
5- open lid and press button -> netbook on
6- shutdown -r now - > netbook restart
7- after bios text, instead of grub2 I get a blinking cursor and after a minute the following message "Reboot and select proper device.."
8-
Case C (power on after suspend):
1- power on netbook
2- grub2 menu
3- Login Archlinux
4- close lid -> suspend -> power led blinking
5- open lid and press button -> netbook on
6- shutdown -h now - > netbook powers off
7- press power button -> power on netbook
8- after bios text, instead of grub2 I get a blinking cursor and after a minute the following message "Reboot and select proper device.."
9-
Case D:
1- power on netbook
2- grub2 menu
3- Login Archlinux
4- close lid -> suspend -> power led blinking
5- open lid and press button -> netbook on
6- shutdown -h now - > netbook powers off
7- wait for 30 min
8- press power button -> power on netbook
9- grub2 menu, and everything ok
10- -
NEO4 - F power up from KB or Mouse
Howdy folks..
Let me get this straight.
Can I boot up from keyboard or mouse ?
(No, not S3 resume from KB/mouse), from total shutdown, to cold start..like every OThER MOBO ..
Cheers all
Adrian.Thanks for the reply syar2003, a rare occurence with this question . Alas it was a feature i relied on to save having animal marks round the on/off switch. Damn! and ive just got a nice black and grey case with chrome switches. It aint on though its not like its a budget board. Do you know if there are any plans by MSI to remedy this sad situation. Can you explain this a little more
Quote
It works , but only if the pc is set in "suspend to ram" state (S3) , not ordinary shutdown to S1 .
We just have to live with it i guess .Quote
Ive looked in control panel/power options but i cant see suspend to ram, i do have this set in the bios though under Power management setup/ Sleep state = [S3 (STR) ] is this what you refer to. Here,s what i have set in bios for power management
Power Management Setup
Sleep state = [S3 (str) ]
Power management = user define
Video off method = [DPMS support]
HDD power down [ disabled ]
HDD power down in suspend = disabled
Power button function [ power off ]
After ac power lost = [ off ]
Wake Up Event Activity
WOL (PME #) from soft off = [ disabled ]
Power on by alarm = [ disabled ]
S3 wake up by PS2 keyboard = [ enabled ]
S3 wake up by PS2 mouse = [enabled ]
I have also tried varios combinations of these settings, but nothing i do will make the keyboard or mouse wake this PC. The only thing i can do that works is Start/turn off computer/standy by: not the most satisfactory solution. -
K8T NEO-FIS2R goes into suspend. Lose display.
First, here is my setup.
[list=a]
MB: K8T NEO-FIS2R
CPU: AMD 64 3200+ 1MB L2 Cache
CPU Fan: Thermaltake Venus 12
RAM: TWINX1024-3200LLPT (2x512Mb DDR400 - Corsair XMS Extreme - Cas Latency: 2-3-2-6 T1)
HD: 6Y120M0 - SATA Maxtor 120GB (plugged on SER1 not the one from Promise)
DVD-RW & Floppy
video card: ASUS nVIDIA GeForce FX5700 - 8X AGP - 256MB DDR - Core Speed 425MHz
Power Supply: Turbolink 350W - +3.3V/24A - +5V/35A - +12V/12A[/list=a]
And of course I have 5 case fans w/ led, the UV light, etc... etc...
Now here is my problem:
When I power up for the first time, my display is kind of crappy (some small lines etc...). I managed to get to the bios etc... after a while the system goes into suspend (Power LED blinking). Can't turn it back on unless I turn off/on the PSU.
When I switch my video card to a ATI Rage 128Mb (my old computer). The picture is good but the system still goes into suspend mode (Power LED blinking).
Also the other weird thing with my 256MB video card, when the system goes into suspend after that I bring it backup, my display is gone, when I switch to my 128MB video card and back to the 256 I get the display back.
I suspect that my PSU is too weak but instead of spending more money on this system I wanted to double check with you guys.
Also, before anybody asks me. Yes, I plugged in the 4-pin 12V connector into the MB.
TZ
EDITED: There was a typo on the +12V of the PSU The correct value is 12A as listed on the PSU. Sorry about that.Jocko>
new PSU -> Enermax 550W (EG651P-VE(FMA), beautifull by the way, feel the power )
Yes 4 pin 12V for connector plugged in
Yes 3 pin power fan connected in pwr_fan connector
Yes still shutdown w/ green light laughing at me.......
No Thermal paste, using a thermal pad, new. Volcano heatsink/fan, running, have a dial on PCI mount place turned to max. According to bios fan running at 5300 rpm. According to bios, CPU temp is 96°F. Should I switch to thermal paste? (I don't really want to butter the CPU if I need to return it... who knows... will check tomorrow anyway...)
video card1: ASUS nVIDIA GeForce FX5700 - 8X AGP - 256MB DDR - Core Speed 425MHz
video card2: ATI Rage 128Mb (don't know model # or anything, I'm not at the office right now....)
video card1: no display when hard drive/DVD/floppy plugged in
video card2: display ok
both video cards have fans and they are both spinnin'
=====================================================
southmike>
[list=1]
ground myself and touch the case everytime.
yes, and removes easily and goes back in easily.
nope everything is cool, nothing got bent pushed or anything
all new came with the heatsink, but might switch to thermal paste now.... ndicator wire pluggin in cpufan1, fan speed crontroled by dial which is set at the max now.
the stix i have right now are corsair twinx. but I also tried with 1 stick kingston value pc2700(?)(DDR333)
didn't do only power switch & power led only, will do tomorrow and let you know.
yes
yes
pin 1 faces where it should (used floppy drive to flash bios already)
no, 1 DVD set as CS at the end of cable, 1 SATA Maxtor 120GB on SATA1 (the one that's not from promise)
yes
yes
no right now I took the MB out to exclude shorts
yes, tried also w/o the d-bracket[/list=1]
CPU is immaculate. will put thermal paste instead of the pad tomorrow (now, i'm starting to think that the thermal pad is not thick enough to contact the CPU and the heatsink, but geez, hard to believe... anyway, worth a try)
no loose wires
heatsink secure (actually I love this new system with the locking thing )
I think that the kingston value is used by other users, and the twinx corsair DDR400 is used also if settings changed in bios (which I tried also), but I don't think it would 'cause a shutdown though, specially if the computer does nothing but seat and be on.
Yes different video card, but my ASUS 256Mb doesn't have its own power supply, checked five times, and fan spins when mb powered up
No, right now hard drive and DVD drive are not plugged in until my system stays up (no need to fry them)
d-bracket lights: 4 green lights when booting on floppy (even when getting to looking for booting device)
Didn't try different wall outlet but used this one already to run several computers, should I try another one?
Nope never, before I put my fingers in, I turn off the computer, switch the PSU off, unplug the power cord from the PSU, and make sure to hear the little buzz sound when power unloads. -
ASUS P5W DH Deluxe kernel panic ACPI & IDE controller is
I recently built a new system with the ASUS P5W DH Deluxe motherboard. Using the newISOs (both the new kernel and old) available on the forums I tried to install Arch only to be met with an extremely nondescript kernel panic (just a bunch of numbers followed by kernel panic). After a bit of fiddling with it I managed to get the system to boot to the installation shell by giving it the "acpi=off" boot parameter.
After figuring this out I thought I was set, but I was so very wrong. The IDE harddrive I was trying to install to was on the Jmicron JMB363 IDE controller that seems to have been hacked together and thrown in at the last second to allow 4 IDE devices in the system (something to do with the Intel specification for the 975X chipset I believe.)
Anyway, the system mounts my primary SATA harddrive "sda" just fine. It then proceeds to load my two PATA DVD+RW drives: "hda" and "hdb" from the intel IDE controller just fine. Then while trying to load the my PATA harddrive "hde" from the Jmicron JMB363 IDE controller, the installation slows to a crawl requiring several minutes before the system boots and throwing errors along the way. The harddrive is also unusable in the system. If I try to do something like "cfdisk /dev/hde" the system will hard lock and require a reboot.
Is there something I've configured incorrectly or is this perhaps a support issue with the Jmicron JMB363 controller. Also, why do I need to turn ACPI off to avoid a kernel panic? I should probably mention that there is a bios option that can be turned on or off to support ACPI 2.0 (disabled by default).
Thanks for any input!I'm running archlinux on a P5W DH Deluxe. Personally, I disabled JMicron in the BIOS as the drivers for it are pretty buggy from what I've read. I'm just using the ICHR PATA/SATA Controller (I have an SATA disk and a PATA DVDRW). I have it set to AHCI mode in the BIOS (this is the most compatible mode and faster for sata drives). It might look like it's frozen during boot, but there is a device that causes problems and takes a minute or so for the kernel to give up on it and continue booting.
If you want to use the JMicron controller, there is a flag you can pass to the kernel in your grub menu.conf (I think it's "ALL-GENERIC-IDE" (no quotes) and you might have to pass "irqpoll" as well. I got it working once but haven't used it for a while, so this may have changed. You might want to look into JMICRON_PATA.
There are some issues with the linux kernel and the P5W.
The bridge between the ICHR to the EZRaid controller isn't recognized by the kernel yet, so it will give some error messages and with a few 30 second pauses between them (which is a pain... I don't know of a way to disable the controller though). I've heard that if you attach a SATA hard disks to BOTH the EZRaid controller and the ICHR it's supposed to avoid it, but I don't want to install an extra hard disk.
The kernel seems to have have problems keeping time with the P5W. I tried installing openntpd to help with it, but it only help a little... moving the clock by about 10 seconds every couple of minutes. I found ntpd does a little better job (altering it by about 1 second every 5-10 minutes). I think this is the cause of some glitches during video playback for me.
I haven't had any luck getting any kind of suspend working with the P5W. It can suspend, but it won't resume. Resetting the computer after a suspend makes it freeze just before you can access the BIOS screen. The only way to recover is to turn-off the power supply on the back for a minute or so and starting it up. It will run for a few seconds and shutdown (some kind of weird hardware reset?). After that it will boot normally.
Let me know how your progress goes. I'd like to know if you come across any fixes for the above. -
Module snd-hda-intel ingore its /etc/modprobe.d/sound.conf
Hi,
I have trouble with modprobe. During boot there are loaded modules, I suppose with configs in /etc/modprobe.d. To get my sound card working I need to load module snd-hda-intel with this option:
options snd-hda-intel model=3stack-dig
So I added the line to /etc/modprobe.d/sound.conf. The option isn't loaded during boot, but if I rmmod snd-hda-intel and modprobe snd-hda-intel then is everything OK.
Thx for help.# aplay /usr/share/sounds/pop.wav
ALSA lib pcm_dmix.c:996:(snd_pcm_dmix_open) unable to open slave
aplay: main:564: audio open error: No such file or directory
cat /proc/asound/cards
0 [default ]: USB-Audio - AK5370
AKM AK5370 at usb-0000:00:02.1-1, full speed
1 [default_1 ]: USB-Audio - PnP Audio Device
PnP Audio Device at usb-0000:00:02.1-4, full speed
$ arecord -L
null
Discard all samples (playback) or generate zero samples (capture)
default:CARD=default_1
PnP Audio Device , USB Audio
Default Audio Device
front:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
Front speakers
surround40:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
IEC958 (S/PDIF) Digital Audio Output
[/CODE]
my dmesg indicates:
4.289035] usb 3-2: New USB device found, idVendor=0556, idProduct=0001
[ 4.289038] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 4.289041] usb 3-2: Product: AK5370
[ 4.289042] usb 3-2: Manufacturer: AKM
[ 4.289109] usb 3-2: configuration #1 chosen from 1 choice
[ 4.596032] usb 3-4: new full speed USB device using ohci_hcd and address 3
[ 4.596072] hdc: host max PIO5 wanted PIO255(auto-tune) selected PIO4
[ 4.596171] hdc: UDMA/66 mode selected
[ 4.596304] ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
[ 4.611027] ide1 at 0x170-0x177,0x376 on irq 15
[ 4.611331] sata_nv 0000:00:0a.0: version 3.5
[ 4.611601] ACPI: PCI Interrupt Link [LTID] enabled at IRQ 21
[ 4.611605] sata_nv 0000:00:0a.0: PCI INT A -> Link[LTID] -> GSI 21 (level, low) -> IRQ 21
[ 4.611634] sata_nv 0000:00:0a.0: setting latency timer to 64
[ 4.611677] scsi0 : sata_nv
[ 4.611751] scsi1 : sata_nv
[ 4.612194] ata1: SATA max UDMA/133 cmd 0xf80 ctl 0xf00 bmdma 0xe000 irq 21
[ 4.612197] ata2: SATA max UDMA/133 cmd 0xe80 ctl 0xe00 bmdma 0xe008 irq 21
[ 4.806034] usb 3-4: New USB device found, idVendor=0d8c, idProduct=0201
[ 4.806038] usb 3-4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[ 4.806040] usb 3-4: Product: PnP Audio Device
[ 4.806107] usb 3-4: configuration #1 chosen from 1 choice
[ 5.254944] ide-gd driver 1.18
[ 5.254972] hda: max request size: 512KiB
[ 5.258359] ide-cd driver 5.00
[ 5.258369] hda: 234441648 sectors (120034 MB) w/8192KiB Cache, CHS=16383/255/63
[ 5.258762] hda: cache flushes supported
[ 5.258801] hda: hda1 hda2 < hda5 hda6 hda7 > hda3
[ 5.334957] ide-cd: hdc: ATAPI 48X DVD-ROM DVD-R/RAM CD-R/RW drive, 2048kB Cache
[ 5.334964] Uniform CD-ROM driver Revision: 3.20
[ 5.981592] PM: Starting manual resume from disk
[ 6.038889] kjournald starting. Commit interval 5 seconds
[ 6.038902] EXT3-fs: mounted filesystem with ordered data mode.
[ 7.500906] udevd version 125 started
[ 7.815041] Linux agpgart interface v0.103
[ 7.817365] agpgart-amd64 0000:00:00.0: AGP bridge [10de/00e1]
[ 7.817390] agpgart-amd64 0000:00:00.0: aperture size 4096 MB is not right, using settings from NB
[ 7.817394] agpgart-amd64 0000:00:00.0: setting up Nforce3 AGP
[ 7.833006] agpgart-amd64 0000:00:00.0: AGP aperture is 512M @ 0xc0000000
[ 7.945067] i2c-adapter i2c-0: nForce2 SMBus adapter at 0x5000
[ 7.945081] i2c-adapter i2c-1: nForce2 SMBus adapter at 0x5040
[ 8.052716] input: Power Button as /devices/LNXSYSTM:00/LNXPWRBN:00/input/input2
[ 8.052723] ACPI: Power Button [PWRF]
[ 8.052793] input: Power Button as /devices/LNXSYSTM:00/device:00/PNP0C0C:00/input/input3
[ 8.052796] ACPI: Power Button [PWRB]
[ 8.097668] processor ACPI_CPU:00: registered as cooling_device0
[ 8.097699] processor ACPI_CPU:01: registered as cooling_device1
[ 8.382280] input: USB Optical Mouse USB Optical Mouse as /devices/pci0000:00/0000:00:02.0/usb1/1-1/1-1:1.0/input/input4
[ 8.382328] a4tech 0003:09DA:0006.0001: input,hidraw2: USB HID v1.10 Mouse [USB Optical Mouse USB Optical Mouse] on usb-0000:00:02.0-1/input0
[ 8.575155] pci_hotplug: PCI Hot Plug PCI Core version: 0.5
[ 8.588074] shpchp: Standard Hot Plug PCI Controller Driver version: 0.4
[ 8.736034] k8temp 0000:00:18.3: Temperature readouts might be wrong - check erratum #141
[ 8.793015] input: PC Speaker as /devices/platform/pcspkr/input/input5
[ 9.474067] Linux video capture interface: v2.00
[ 9.565013] bttv: driver version 0.9.18 loaded
[ 9.565017] bttv: using 8 buffers with 2080k (520 pages) each for capture
[ 9.565052] bttv: Bt8xx card found (0).
[ 9.565299] ACPI: PCI Interrupt Link [LNKB] enabled at IRQ 19
[ 9.565309] bttv 0000:02:09.0: PCI INT A -> Link[LNKB] -> GSI 19 (level, low) -> IRQ 19
[ 9.565318] bttv0: Bt878 (rev 2) at 0000:02:09.0, irq: 19, latency: 32, mmio: 0xfbffe000
[ 9.565342] bttv0: detected: FlyVideo 98 (LR50)/ Chronos Video Shuttle II [card=35], PCI subsystem ID is 1851:1850
[ 9.565345] bttv0: using: Lifeview FlyVideo 98 LR50 / Chronos Video Shuttle II [card=35,autodetected]
[ 9.565348] IRQ 19/bttv0: IRQF_DISABLED is not guaranteed on shared IRQs
[ 9.565381] bttv0: gpio: en=00000000, out=00000000 in=008dff00 [init]
[ 9.565427] bttv0: FlyVideo_gpio: unknown tuner type.
[ 9.565430] bttv0: FlyVideo Radio=no RemoteControl=yes Tuner=-1 gpio=0x8dff00
[ 9.565432] bttv0: FlyVideo LR90=no tda9821/tda9820=no capture_only=no
[ 9.565435] bttv0: tuner type unset
[ 9.565468] bttv0: registered device video0
[ 9.565487] bttv0: registered device vbi0
# lsmod | grep snd
snd_usb_audio 72008 1
snd_pcm_oss 32232 0
snd_mixer_oss 12368 1 snd_pcm_oss
snd_pcm 62364 2 snd_usb_audio,snd_pcm_oss
snd_page_alloc 8180 1 snd_pcm
snd_usb_lib 13508 1 snd_usb_audio
snd_hwdep 6104 1 snd_usb_audio
snd_seq_midi 5688 0
snd_rawmidi 18580 2 snd_usb_lib,snd_seq_midi
snd_seq_midi_event 6212 1 snd_seq_midi
snd_seq 42436 2 snd_seq_midi,snd_seq_midi_event
snd_timer 17436 2 snd_pcm,snd_seq
snd_seq_device 6136 3 snd_seq_midi,snd_rawmidi,snd_seq
snd 49040 11 snd_usb_audio,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_hwdep,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
soundcore 6184 1 snd
usbcore 125872 6 snd_usb_audio,snd_usb_lib,usbhid,ehci_hcd,ohci_hcd
I would like to exchange the usb microphone to the sound card.
USB microphone would be second place, since it is a mic only.
first main sound would come from usb sound card system.
then would get sounds
ALSA has a special built‐in module autoloading system. You do
not have to make use of it, and it is useless if your /dev direc‐
tory is managed by udev, but in case you do want to use it, here
is a brief explanation of how it is supposed to work.
When the "snd" module is loaded and the user tries to open a
sound device file with a minor number that indicates that card
number N is wanted, snd modprobes "snd‐card‐N". Thus, if you set
up module loader configuration file /etc/modprobe.d/sound to look
like this:
alias snd‐card‐0 snd‐cs46xx
options snd‐cs46xx index=0
then snd‐cs46xx will be automagically loaded when it is needed to
handle the attempted open() of the sound device. The "index=0"
option ensures that when snd‐cs46xx is loaded the first card that
it registers is given index 0.
If you have an additional sound card of the same type then make
the file look like this:
alias snd‐card‐0 snd‐cs46xx
alias snd‐card‐1 snd‐cs46xx
options snd‐cs46xx index=0,1
If you have, instead, an additional sound card of a different
type then make the file look like this:
alias snd‐card‐0 snd‐cs46xx
options snd‐cs46xx index=0
alias snd‐card‐1 snd‐emu10k1
options snd‐emu10k1 index=1
ALSA supports up to eight sound cards.
The alsaconf program, available in the alsa‐utils package (in De‐
bian but not in Ubuntu), performs hardware detection and can
write out a module loader configuration file that looks like the
above.
Unfortunately, alsaconf can only detect one sound card and is
generally a poorly written program.
The module loader configuration files just described are addi‐
tional to /etc/modprobe.d/alsa‐base which is shipped as conffile
with the alsa‐base package. The files contain basic configura‐
tion entries which don't normally need to be customized. The en‐
tries may include:
* ALSA autoloader aliases * an entry for each normal sound card
driver that will cause a command
to be executed after the driver has initialized * an entry for
each abnormal driver (i.e., a driver that drives
hardware such as a TV card or modem that is not suited to be
the
primary sound card) preventing it from grabbing index 0
Suppose you decide that you need to load a certain driver, snd‐
foo, with options: "dma1=0 ctlport=0x530". The recommended way
to set this up is to create additional files in /etc/modprobe.d/
each containing an "options" line:
# /etc/modprobe.d/alsa_local
options snd‐foo dma1=0 ctlport=0x530
creating device files ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ ALSA native device
files are located in /dev/snd/. (ALSA's kernel‐ OSS‐emulation
device files are of course the same as the OSS device files.)
Udev takes care of creating devices files when modules are load‐
ed.
reloading modules across APM suspend‐a
what shall I enter into, /etc/modprobe.d/sound.conf
Create /etc/modprobe.d/sound.conf with the following contents:
## ALSA portion
alias char-major-116 snd
alias snd-card-0 snd-hda-intel
alias snd-card-1 snd-usb-audio
## module options should go here
options snd-hda-intel index=0 model=ref
options snd-usb-audio index=1
and run 'alsa force-reload' or reboot.
# aplay /usr/share/sounds/pop.wav
ALSA lib pcm_dmix.c:996:(snd_pcm_dmix_open) unable to open slave
aplay: main:564: audio open error: No such file or directory
cat /proc/asound/cards
0 [default ]: USB-Audio - AK5370
AKM AK5370 at usb-0000:00:02.1-1, full speed
1 [default_1 ]: USB-Audio - PnP Audio Device
PnP Audio Device at usb-0000:00:02.1-4, full speed
$ arecord -L
null
Discard all samples (playback) or generate zero samples (capture)
default:CARD=default_1
PnP Audio Device , USB Audio
Default Audio Device
front:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
Front speakers
surround40:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=default_1,DEV=0
PnP Audio Device , USB Audio
IEC958 (S/PDIF) Digital Audio Output
[/CODE]
my dmesg indicates:
4.289035] usb 3-2: New USB device found, idVendor=0556, idProduct=0001
[ 4.289038] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 4.289041] usb 3-2: Product: AK5370
[ 4.289042] usb 3-2: Manufacturer: AKM
[ 4.289109] usb 3-2: configuration #1 chosen from 1 choice
[ 4.596032] usb 3-4: new full speed USB device using ohci_hcd and address 3
[ 4.596072] hdc: host max PIO5 wanted PIO255(auto-tune) selected PIO4
[ 4.596171] hdc: UDMA/66 mode selected
[ 4.596304] ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
[ 4.611027] ide1 at 0x170-0x177,0x376 on irq 15
[ 4.611331] sata_nv 0000:00:0a.0: version 3.5
[ 4.611601] ACPI: PCI Interrupt Link [LTID] enabled at IRQ 21
[ 4.611605] sata_nv 0000:00:0a.0: PCI INT A -> Link[LTID] -> GSI 21 (level, low) -> IRQ 21
[ 4.611634] sata_nv 0000:00:0a.0: setting latency timer to 64
[ 4.611677] scsi0 : sata_nv
[ 4.611751] scsi1 : sata_nv
[ 4.612194] ata1: SATA max UDMA/133 cmd 0xf80 ctl 0xf00 bmdma 0xe000 irq 21
[ 4.612197] ata2: SATA max UDMA/133 cmd 0xe80 ctl 0xe00 bmdma 0xe008 irq 21
[ 4.806034] usb 3-4: New USB device found, idVendor=0d8c, idProduct=0201
[ 4.806038] usb 3-4: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[ 4.806040] usb 3-4: Product: PnP Audio Device
[ 4.806107] usb 3-4: configuration #1 chosen from 1 choice
[ 5.254944] ide-gd driver 1.18
[ 5.254972] hda: max request size: 512KiB
[ 5.258359] ide-cd driver 5.00
[ 5.258369] hda: 234441648 sectors (120034 MB) w/8192KiB Cache, CHS=16383/255/63
[ 5.258762] hda: cache flushes supported
[ 5.258801] hda: hda1 hda2 < hda5 hda6 hda7 > hda3
[ 5.334957] ide-cd: hdc: ATAPI 48X DVD-ROM DVD-R/RAM CD-R/RW drive, 2048kB Cache
[ 5.334964] Uniform CD-ROM driver Revision: 3.20
[ 5.981592] PM: Starting manual resume from disk
[ 6.038889] kjournald starting. Commit interval 5 seconds
[ 6.038902] EXT3-fs: mounted filesystem with ordered data mode.
[ 7.500906] udevd version 125 started
[ 7.815041] Linux agpgart interface v0.103
[ 7.817365] agpgart-amd64 0000:00:00.0: AGP bridge [10de/00e1]
[ 7.817390] agpgart-amd64 0000:00:00.0: aperture size 4096 MB is not right, using settings from NB
[ 7.817394] agpgart-amd64 0000:00:00.0: setting up Nforce3 AGP
[ 7.833006] agpgart-amd64 0000:00:00.0: AGP aperture is 512M @ 0xc0000000
[ 7.945067] i2c-adapter i2c-0: nForce2 SMBus adapter at 0x5000
[ 7.945081] i2c-adapter i2c-1: nForce2 SMBus adapter at 0x5040
[ 8.052716] input: Power Button as /devices/LNXSYSTM:00/LNXPWRBN:00/input/input2
[ 8.052723] ACPI: Power Button [PWRF]
[ 8.052793] input: Power Button as /devices/LNXSYSTM:00/device:00/PNP0C0C:00/input/input3
[ 8.052796] ACPI: Power Button [PWRB]
[ 8.097668] processor ACPI_CPU:00: registered as cooling_device0
[ 8.097699] processor ACPI_CPU:01: registered as cooling_device1
[ 8.382280] input: USB Optical Mouse USB Optical Mouse as /devices/pci0000:00/0000:00:02.0/usb1/1-1/1-1:1.0/input/input4
[ 8.382328] a4tech 0003:09DA:0006.0001: input,hidraw2: USB HID v1.10 Mouse [USB Optical Mouse USB Optical Mouse] on usb-0000:00:02.0-1/input0
[ 8.575155] pci_hotplug: PCI Hot Plug PCI Core version: 0.5
[ 8.588074] shpchp: Standard Hot Plug PCI Controller Driver version: 0.4
[ 8.736034] k8temp 0000:00:18.3: Temperature readouts might be wrong - check erratum #141
[ 8.793015] input: PC Speaker as /devices/platform/pcspkr/input/input5
[ 9.474067] Linux video capture interface: v2.00
[ 9.565013] bttv: driver version 0.9.18 loaded
[ 9.565017] bttv: using 8 buffers with 2080k (520 pages) each for capture
[ 9.565052] bttv: Bt8xx card found (0).
[ 9.565299] ACPI: PCI Interrupt Link [LNKB] enabled at IRQ 19
[ 9.565309] bttv 0000:02:09.0: PCI INT A -> Link[LNKB] -> GSI 19 (level, low) -> IRQ 19
[ 9.565318] bttv0: Bt878 (rev 2) at 0000:02:09.0, irq: 19, latency: 32, mmio: 0xfbffe000
[ 9.565342] bttv0: detected: FlyVideo 98 (LR50)/ Chronos Video Shuttle II [card=35], PCI subsystem ID is 1851:1850
[ 9.565345] bttv0: using: Lifeview FlyVideo 98 LR50 / Chronos Video Shuttle II [card=35,autodetected]
[ 9.565348] IRQ 19/bttv0: IRQF_DISABLED is not guaranteed on shared IRQs
[ 9.565381] bttv0: gpio: en=00000000, out=00000000 in=008dff00 [init]
[ 9.565427] bttv0: FlyVideo_gpio: unknown tuner type.
[ 9.565430] bttv0: FlyVideo Radio=no RemoteControl=yes Tuner=-1 gpio=0x8dff00
[ 9.565432] bttv0: FlyVideo LR90=no tda9821/tda9820=no capture_only=no
[ 9.565435] bttv0: tuner type unset
[ 9.565468] bttv0: registered device video0
[ 9.565487] bttv0: registered device vbi0
# lsmod | grep snd
snd_usb_audio 72008 1
snd_pcm_oss 32232 0
snd_mixer_oss 12368 1 snd_pcm_oss
snd_pcm 62364 2 snd_usb_audio,snd_pcm_oss
snd_page_alloc 8180 1 snd_pcm
snd_usb_lib 13508 1 snd_usb_audio
snd_hwdep 6104 1 snd_usb_audio
snd_seq_midi 5688 0
snd_rawmidi 18580 2 snd_usb_lib,snd_seq_midi
snd_seq_midi_event 6212 1 snd_seq_midi
snd_seq 42436 2 snd_seq_midi,snd_seq_midi_event
snd_timer 17436 2 snd_pcm,snd_seq
snd_seq_device 6136 3 snd_seq_midi,snd_rawmidi,snd_seq
snd 49040 11 snd_usb_audio,snd_pcm_oss,snd_mixer_oss,snd_pcm,snd_hwdep,snd_rawmidi,snd_seq,snd_timer,snd_seq_device
soundcore 6184 1 snd
usbcore 125872 6 snd_usb_audio,snd_usb_lib,usbhid,ehci_hcd,ohci_hcd
I would like to exchange the usb microphone to the sound card.
USB microphone would be second place, since it is a mic only.
first main sound would come from usb sound card system.
then would get sounds
ALSA has a special built‐in module autoloading system. You do
not have to make use of it, and it is useless if your /dev direc‐
tory is managed by udev, but in case you do want to use it, here
is a brief explanation of how it is supposed to work.
When the "snd" module is loaded and the user tries to open a
sound device file with a minor number that indicates that card
number N is wanted, snd modprobes "snd‐card‐N". Thus, if you set
up module loader configuration file /etc/modprobe.d/sound to look
like this:
alias snd‐card‐0 snd‐cs46xx
options snd‐cs46xx index=0
then snd‐cs46xx will be automagically loaded when it is needed to
handle the attempted open() of the sound device. The "index=0"
option ensures that when snd‐cs46xx is loaded the first card that
it registers is given index 0.
If you have an additional sound card of the same type then make
the file look like this:
alias snd‐card‐0 snd‐cs46xx
alias snd‐card‐1 snd‐cs46xx
options snd‐cs46xx index=0,1
If you have, instead, an additional sound card of a different
type then make the file look like this:
alias snd‐card‐0 snd‐cs46xx
options snd‐cs46xx index=0
alias snd‐card‐1 snd‐emu10k1
options snd‐emu10k1 index=1
ALSA supports up to eight sound cards.
The alsaconf program, available in the alsa‐utils package (in De‐
bian but not in Ubuntu), performs hardware detection and can
write out a module loader configuration file that looks like the
above.
Unfortunately, alsaconf can only detect one sound card and is
generally a poorly written program.
The module loader configuration files just described are addi‐
tional to /etc/modprobe.d/alsa‐base which is shipped as conffile
with the alsa‐base package. The files contain basic configura‐
tion entries which don't normally need to be customized. The en‐
tries may include:
* ALSA autoloader aliases * an entry for each normal sound card
driver that will cause a command
to be executed after the driver has initialized * an entry for
each abnormal driver (i.e., a driver that drives
hardware such as a TV card or modem that is not suited to be
the
primary sound card) preventing it from grabbing index 0
Suppose you decide that you need to load a certain driver, snd‐
foo, with options: "dma1=0 ctlport=0x530". The recommended way
to set this up is to create additional files in /etc/modprobe.d/
each containing an "options" line:
# /etc/modprobe.d/alsa_local
options snd‐foo dma1=0 ctlport=0x530
creating device files ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐ ALSA native device
files are located in /dev/snd/. (ALSA's kernel‐ OSS‐emulation
device files are of course the same as the OSS device files.)
Udev takes care of creating devices files when modules are load‐
ed.
reloading modules across APM suspend‐a
what shall I enter into, /etc/modprobe.d/sound.conf
Create /etc/modprobe.d/sound.conf with the following contents:
## ALSA portion
alias char-major-116 snd
alias snd-card-0 snd-hda-intel
alias snd-card-1 snd-usb-audio
## module options should go here
options snd-hda-intel index=0 model=ref
options snd-usb-audio index=1
and run 'alsa force-reload' or reboot.
lspci -n
00:00.0 0600: 10de:00e1 (rev a1)
00:01.0 0601: 10de:00e0 (rev a2)
00:01.1 0c05: 10de:00e4 (rev a1)
00:02.0 0c03: 10de:00e7 (rev a1)
00:02.1 0c03: 10de:00e7 (rev a1)
00:02.2 0c03: 10de:00e8 (rev a2)
00:05.0 0680: 10de:00df (rev a2)
00:08.0 0101: 10de:00e5 (rev a2)
00:0a.0 0101: 10de:00e3 (rev a2)
00:0b.0 0604: 10de:00e2 (rev a2)
00:0e.0 0604: 10de:00ed (rev a2)
00:18.0 0600: 1022:1100
00:18.1 0600: 1022:1101
00:18.2 0600: 1022:1102
00:18.3 0600: 1022:1103
01:00.0 0300: 10de:0253 (rev a3)
02:09.0 0400: 109e:036e (rev 02)
02:09.1 0480: 109e:0878 (rev 02)
any ideas? -
2nd K8N SLi Platinum motherboard just died
Hope somebody else has experienced this - now on my 3rd board. A bit about my system:
Msi K8N SLi Platinum motherboard
2 x Seagate Barracuda ST3200822AS 200Gb Hard disk
Antec PSU True Blue 480w
1 x AMD (Winchester) Athlon 64bit 3200+ CPU
OCZ Dual Channel Kit 2x512MB DDR400 Ram
128MB Gigabyte GV NX66T128VP Graphics Card
Running MCE 2005
I built my first system running Media Center 2005 a few months back. Very stable. Used to put it into S3 sleep mode each evening and wake up the next day. Never any problems. CPU temp ran about 47degC. Never did anything stressful on it, no games just watched tv with a tuner card and played mp3s.
One day it wouldn't wake up, wouldn't post, no beeps nothing. cpu fan spun briefly (2 secs) and died. I stripped it down to bare essentials (1 stick ram, cpu). Tested PSU - fine. Tried out of case, again no joy, so I RMAed. Put it down to a bad board.
So I installed the new board - it worked fine. Must have been a bad board. Great! It ran for another month and the same thing happened, it just would wake up one day! Now I'm worried, am I doing something wrong with these boards, are they getting too hot? How come they fail when they are switched off? Is it a bios thing? - I tried resetting the Cmos, no joy there.
Any way that I can update the bios when they are in this state?
Any ideas - cheers Richardrichardwilshire...here is a list of many potential non-compliant APM features you may want to look at, and note that these are carry-overs from Windows 2000, the foundation of WinXP:
Key APM Components and What They Do
APM BIOS: Placed in ROM or flash by the OEM. Does most of the real work of powering the system on and off. The operating system can call the BIOS, and it either works or it doesn't; its operation is opaque to the operating system. The APM BIOS must be turned on using the BIOS setup utility for APM to work. If the APM BIOS is unstable, it may be necessary to turn the APM BIOS off using the BIOS setup utility, in addition to turning off Windows 2000 APM support. The APM BIOS should be configured such that timeouts are either turned off or set for the longest period possible, so that the operating system can control timeouts instead of the APM BIOS.
Ntdetect.com: It detects whether the APM BIOS is present before booting the operating system, determines whether Windows 2000 can use it, and reports the results of detection in the registry.
NtLdr: Restarts APM upon resume from hibernate, if APM was active before hibernation.
Ntapm.sys: A Windows 2000 driver that hooks the system and the APM BIOS together. It includes certain system operations for dispatch to the APM BIOS, and it polls APM BIOS events and status. Note than when the APM BIOS presents an event (such as suspend or power off), Ntapm.sys catches this, and then issues an NtInitiatePowerAction call, which tells the operating system to respond appropriately. At the end, the Windows 2000 power manager calls into the HAL, which calls back into Ntapm.sys, which calls the APM BIOS. In this process, almost all operating system and driver power code is the same between APM and ACPI.
Hal.dll: Windows 2000 APM support works only with Halx86, which is the only HAL to have the hooks needed to call into Ntapm.sys. It's also the only HAL relevant to important APM machines in the market.
Apmbatt.sys: This emulates a battery unit so the system battery status code can work.
Power Applet: The Control Panel applet that allows the user to enable or disable APM support on a computer. This is the only supported way to turn operating system APM support on or off.
Biosinfo.inf: Windows 2000 file that lists machines on the Autoenable APM list and the Disable APM list, and also lists the BIOS detection sequences used to match them.
Key Elements in the Registry
Ntdetect Reporting. The data about APM that is discovered by Ntdetect.com is reported in the registry using a Multi-function adapter (MFA) entry in the system description of the hardware tree. To find this, look in HKEY_LOCAL_MACHINE\ hardware\ description\ system\ multifunctionadapter.
There will be a set of keys there named 0, 1, 2, 3, etc. Each of them will have value entries named Component Information, Configuration Data, Identifier, and so on. Find the key whose Identifier entry == "APM". The "Configuration Data" entry of that key will contain the data on APM found and reported by Ntdetect.com. If the key is absent, then APM was not found. The contents of this value entry are reported in sdk\inc\ntapmsdk.h.
Running Apmstat.exe -v will dump this structure, for machines where it's relevant. For machines where it's not relevant (multiprocessors, not x86, not halx86, ACPI is on, and so on), Apmstat.exe will report that.
Biosinfo vs. Machine-Specific Info. The results of machine-specific detection versus Biosinfo.inf are stored in HKEY_LOCAL_MACHINE\ System\ CurrentControlSet\ Control\ BIOSInfo\ APM. If the "Attributes" value is 1, the machine's APM BIOS is "known good" and the machine is on the Autoenable APM list. If the value 2, the machine's APM BIOS is "known bad" and the machine is on the Disable APM list. Otherwise, the machine is neutral.
Running apmstat will report whether the APM BIOS is known to be good, known to be bad, or is neutral.
HAL Reporting. If the HAL is Halx86.dll, the registry key HKEY_LOCAL_MACHINE\ System\ CurrentControlSet\ Control\ ApmLegalHal will have a value entry present with data of 1.
Running apmstat will report if this is not the case.
ACPI Reporting. If the machine is an ACPI machine, there will be a services entry for ACPI under (HKLM\System\currentcontrolset\services\ACPI) with value Start == 0. This is telling the system to load and run Acpi.sys at phase 0. If this is not present, the machine is not being run as an ACPI machine, even if, perhaps, it should be.
Running apmstat will report a machine as an ACPI machine if it sees Acpi.sys has Start == 0.
UI Elements
Power Applet APM Tab. The Control Panel includes a Power applet. If the APM is installed at all (enabled or disabled), there will be an APM tab in this applet. You can turn APM on and off by checking the box in this tab. This is the only recommended and supported way to do that. Turning APM on is an on-the-fly Plug and Play action; turning it off requires a reboot. If the tab is absent, it's an ACPI machine, an APM Disabled machine, or the machine simply doesn't have APM.
Standby on Shutdown Menu. If APM is turned on, there will be a Standby entry under the Shutdown option when the user presses CTRL+ALT+DEL. There may also be a Hibernate entry, which is a separate function. (Hibernate can work even if neither APM nor ACPI are present.) Standby under APM has the same use as under ACPI.
Battery Status Icon. If the battery display is turned on in the Control Panel Power applet, there will be a Battery Status icon on the system tray, which works about the same as for ACPI. Note that an APM machine always reports a single composite battery, regardless of how many are present or what the machine reports. (Windows 2000 uses the unified/composite number, because this is thought to be more reliable on a wide range of APM BIOSes, and is simpler.)
Power Button. On most APM machines, the power button, a sleep button, or the like, can suspend the machine (place on standby). Most require the power button to resume, though at least one will come back with a keyboard touch. Windows 2000 APM does not support custom power buttons.
Tools
Apmstat.exe: As of Windows 2000 RC1, Apmstat.exe is included in the support directory on the Windows 2000 product CD. Support personnel and expert users can run this utility to determine status.
BIOS Setup Utility. Essentially all APM machines will have some sort of machine setup/configuration screen, usually accessed at boot by pressing ESC, DEL, F1, F2, or F10. Support personnel and expert users may be able to improve system behavior by changing or disabling APM options.
Note: Be warned that some APM BIOSes will turn themselves off if all timers are disabled. In this case, it's best to set all timers to some long timeout value.
APM BIOS and Kernel Debugger. Some APM BIOSes will refuse to suspend if the kernel debugger is active on one of the system COM ports.
Event log. If an APM_SETPOWER call fails (that is, a standby/suspend fails at the APM BIOS interface), then Ntapm.sys will write a record into the system event log, with data reporting that this happened and whatever error code the APM BIOS returned. This information is sometimes useful if a machine is refusing to suspend because of activity on some port that isn't obvious to the user.
NOTES:
• APM support is not allowed on server products. This means that the APM tab will not appear and that there is no APM support in Windows 2000 Advanced Server or in Windows 2000 Datacenter.
• APM will not hook up the standby vector on machines that do not have batteries. This means that on machines that do not have batteries, standby will not appear as an option on the Shutdown list, and will not be available as an operation.
• Hibernate is independent of APM or ACPI; hibernate can be used on machines that do not have either APM or ACPI.
• To get the battery status icon, you must turn it on with the Power applet in the control panel.
• To get hibernate, you must turn it on with the Power applet in the control panel.
Suggestions for Problem Resolution
The following provides guidelines for support personnel or expert users who are troubleshooting APM support on a system running Windows 2000.
1.
Make sure the user has APM turned on, hibernate turned on, and the battery icon turned on.
2.
Make sure that APM BIOS screen blanking is turned off. This will often make the system seem to behave badly when problem is only that the screen is black. (Use a screen saver of BLANK to get the right effect.)
3.
Run Apmstat.exe. Its output will often make the issue obvious (trying to run APM on a multiple-processor machine, for example).
4.
If the machine is a desktop, it will rarely run APM well, but you can get 90 percent of the value by using hibernate, which does not require either APM or ACPI to work.
5. If Windows 2000 APM has been turned off, and the machine is still not stable, try turning off the APM BIOS itself in the machine's setup screen.
6.
Some machines will work better with Windows 2000 APM turned on, because this puts the operating system more in sync with the system's APM BIOS. -
Laptop mode tools problem with kernel 3.0
today I just updated the system and my laptop runs dramatically hotter after that. I read the archwiki, it does talk about the laptop mode tools problem with kernel 3.0 but when I opened the file /usr/sbin/laptop_mode, the lines which the wiki mentions are not there. Does anyone here have the same problem and can you offer the solution?
Here is my /usr/sbin/laptop_mode
#! /bin/sh
# Script to start or stop laptop_mode, and to control various settings of the
# kernel, hardware etc. that influence power consumption.
# This script is a part of Laptop Mode Tools. If you are running a supported
# power management daemon, this script will be automatically called on power
# state change.
# Configure laptop mode tools in /etc/laptop-mode/laptop-mode.conf, and in
# the broken-out config files in /etc/laptop-mode/conf.d.
# Please consult the manual pages laptop-mode.conf(8) and laptop_mode(8) for
# additional information.
# Maintainer: Ritesh Raj Sarraf ([email protected])
# Original Author: Bart Samwel ([email protected])
# Project home page: http://samwel.tk/laptop_mode
# Contributors to this script: Bart Samwel
# Kiko Piris
# Micha Feigin
# Andrew Morton
# Herve Eychenne
# Dax Kelson
# Jan Polacek
# ... and many others that I've stopped
# keeping track of.
# Based on a script for Linux 2.4 written by Jens Axboe.
set -a
# The laptop mode tools version number. Extracted by the installer makefile
# as well, so don't change the format!
LMTVERSION=1.59
# This script is loaded from multiple scripts to set the config defaults
# and to read the configuration on top of those. Only when the command is
# recognized does this script do anything else.
VERBOSE_OUTPUT=0
ENABLE_LAPTOP_MODE_ON_BATTERY=1
ENABLE_LAPTOP_MODE_ON_AC=0
ENABLE_LAPTOP_MODE_WHEN_LID_CLOSED=0
PARTITIONS="auto /dev/mapper/*"
LM_BATT_MAX_LOST_WORK_SECONDS=600
LM_AC_MAX_LOST_WORK_SECONDS=360
DEF_MAX_AGE=30
LM_READAHEAD=3072
NOLM_READAHEAD=128
CONTROL_READAHEAD=1
CONTROL_NOATIME=0
USE_RELATIME=1
CONTROL_HD_IDLE_TIMEOUT=1
LM_AC_HD_IDLE_TIMEOUT=4 # 20 seconds
LM_BATT_HD_IDLE_TIMEOUT=4 # 20 seconds
NOLM_HD_IDLE_TIMEOUT=244 # 2 hours
DEF_UPDATE=5
DEF_XFS_AGE_BUFFER=15
DEF_XFS_SYNC_INTERVAL=30
DEF_XFS_BUFD_INTERVAL=1
XFS_HZ=100
CONTROL_MOUNT_OPTIONS=1
BATT_HD_POWERMGMT=1
LM_AC_HD_POWERMGMT=254
NOLM_AC_HD_POWERMGMT=254
CONTROL_HD_POWERMGMT=0
CONTROL_HD_WRITECACHE=0
NOLM_AC_HD_WRITECACHE=1
NOLM_BATT_HD_WRITECACHE=0
LM_HD_WRITECACHE=0
LM_DIRTY_RATIO=60
LM_DIRTY_BACKGROUND_RATIO=1
NOLM_DIRTY_BACKGROUND_RATIO=10
NOLM_DIRTY_RATIO=40
LM_SECONDS_BEFORE_SYNC=2
BATT_CPU_MAXFREQ=medium
BATT_CPU_MINFREQ=slowest
BATT_CPU_GOVERNOR=ondemand
BATT_CPU_IGNORE_NICE_LOAD=1
LM_AC_CPU_MAXFREQ=fastest
LM_AC_CPU_MINFREQ=slowest
LM_AC_CPU_GOVERNOR=ondemand
LM_AC_CPU_IGNORE_NICE_LOAD=1
NOLM_AC_CPU_MAXFREQ=fastest
NOLM_AC_CPU_MINFREQ=slowest
NOLM_AC_CPU_GOVERNOR=ondemand
NOLM_AC_CPU_IGNORE_NICE_LOAD=0
CONTROL_CPU_FREQUENCY=0
HD="/dev/[hs]d[abcdefgh]"
CONTROL_SYSLOG_CONF=0
LM_AC_SYSLOG_CONF=/etc/syslog-on-ac-with-lm.conf
NOLM_AC_SYSLOG_CONF=/etc/syslog-on-ac-without-lm.conf
BATT_SYSLOG_CONF=/etc/syslog-on-battery.conf
SYSLOG_CONF_SIGNAL_PROGRAM=syslogd
SYSLOG_CONF=/etc/syslog.conf
CONTROL_DPMS_STANDBY=0
BATT_DPMS_STANDBY=300
LM_AC_DPMS_STANDBY=1200
NOLM_AC_DPMS_STANDBY=1200
CONTROL_CPU_THROTTLING=0
BATT_CPU_THROTTLING=medium
LM_AC_CPU_THROTTLING=minimum
NOLM_AC_CPU_THROTTLING=minimum
CONTROL_START_STOP=1
CONTROL_TERMINAL=0
TERMINALS="/dev/vc/1 /dev/vcs1"
BATT_TERMINAL_BLANK_MINUTES=1
BATT_TERMINAL_POWERDOWN_MINUTES=2
LM_AC_TERMINAL_BLANK_MINUTES=10
LM_AC_TERMINAL_POWERDOWN_MINUTES=10
NOLM_AC_TERMINAL_BLANK_MINUTES=10
NOLM_AC_TERMINAL_POWERDOWN_MINUTES=50
ENABLE_AUTO_HIBERNATION=0
HIBERNATE_COMMAND=/usr/sbin/hibernate
AUTO_HIBERNATION_ON_CRITICAL_BATTERY_LEVEL=1
DISABLE_LAPTOP_MODE_ON_CRITICAL_BATTERY_LEVEL=1
AUTO_HIBERNATION_BATTERY_CHARGE_MAH=0
AUTO_HIBERNATION_BATTERY_CHARGE_MWH=0
MINIMUM_BATTERY_CHARGE_MAH=0
MINIMUM_BATTERY_CHARGE_MWH=0
ASSUME_SCSI_IS_SATA=1
CONTROL_BRIGHTNESS=0
BATT_BRIGHTNESS_COMMAND=false
LM_AC_BRIGHTNESS_COMMAND=false
NOLM_AC_BRIGHTNESS_COMMAND=false
LOG_TO_SYSLOG=1
DEBUG=0
ENABLE_LAPTOP_MODE_TOOLS=1
# Initialize the PATH Variable
export PATH="${PATH}":/bin:/sbin:/usr/bin:/usr/sbin
# This is a 2 phase locking approach. LMT_REQ_LOCK is the outer lock and LMT_INVOC_LOCK is the inner lock
# We take this approach to ensure the scenario that, "At any point when an event occurs (AC/BATT), the
# kernel can generate multiple events spanning over a couple of events. The first event is honored and
# lmt executes. If the last event triggered at the 9th second, there is a fair chance that a good amount
# of state change would have occured in the OS, to honor that state, we keep an outer lock (LMT_REQ_LOCK)
# handy, so that those changes can also be applied and not forgotten.
# Workflow:
# Event-1 is generated and lmt executes (lmt runtime could span 5-10 seconds)
# At seventh second, 4 events generate. But Event-1 is still running.
# We don't want to discard all the remaining 4 events, but at least honor 1 so that we can act to the changes
# that occured in the last 7 seconds.
# So, Event-2 acquire LMT_REQ_LOCK and waits to acquire LMT_INVOC_LOCK (which is acquire by Event-1)
LMT_REQ_LOCK="/var/lock/lmt-req.lock"
LMT_INVOC_LOCK="/var/lock/lmt-invoc.lock"
FLOCK=`which flock`
checkint ()
# $1 arg should be the string/integer
# that you want to check for as an integer.
echo $1 | grep "[^0-9]" > /dev/null 2>&1
return $?;
# Returns 1 if it is an integer
# Function to handle logging
LOGGER=`which logger`;
log ()
# $1 should be msg type
# $2 should be the real msg
if [ x$LOG_TO_SYSLOG = x1 ]; then
# NOTE: Add the check on $2 being empty, once you are confident
# that there aren't any bugs in logging. And no bugs in executing
# modules and logging
if [ -x $LOGGER -a "$1" != "STATUS" ]; then
#if [ -z $2 ]; then
# continue
#elif [ "$1" = "MSG" ]; then
if [ "$1" = "MSG" ]; then
logger -p daemon.info -t laptop-mode "$2";
elif [ "$1" = "ERR" ]; then
logger -p daemon.err -t laptop-mode "$2";
elif [ "$1" = "VERBOSE" ]; then
if [ x$VERBOSE_OUTPUT = x1 ]; then
logger -p daemon.debug -t laptop-mode "$2";
fi
else
logger -p daemon.notice -t laptop-mode "$2";
fi
fi
fi
if [ "$1" = "VERBOSE" ]; then
$LM_VERBOSE && echo "$2" >/dev/fd/2;
elif [ "$1" = "ERR" ]; then
echo "$2" >/dev/fd/2;
else
# Message of type MSG and STATUS can go to stdout.
echo "$2" >/dev/fd/1;
fi
enableDebug ()
# Check if debug is enabled
if [ x$(($(basename $1 | cut -d . -f1 | tr "[:lower:]" "[:upper:]" | sed 's/-/_/g')_DEBUG)) = x1 ]; then
set -vx
fi
disableDebug ()
# Check if debug is enabled
if [ x$(($(basename $1 | cut -d . -f1 | tr "[:lower:]" "[:upper:]" | sed 's/-/_/g')_DEBUG)) = x1 ]; then
set +vx
fi
# No default on these ones -- we need to detect if they have been set, for
# backward compatibility with MINIMUM_BATTERY_MINUTES etc.
AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT=
MINIMUM_BATTERY_CHARGE_PERCENT=
# Backward compatibility variable that is sometimes
# set externally (Debian init system)
unset VERBOSE
lmt_load_config ()
# Source config. Some config settings have been moved from the main config file
# to modular configuration files, and to support existing laptop-mode.conf
# files from earlier versions, we source the modular configuration files FIRST.
if [ -d /etc/laptop-mode/conf.d ] ; then
for CONF in /etc/laptop-mode/conf.d/*.conf ; do
if [ -r "$CONF" ] ; then
. "$CONF"
#Handle individual module debug settings
if [ "$DEBUG" -eq 1 ]; then
export $(basename $CONF | cut -d . -f1 | tr "[:lower:]" "[:upper:]" | sed 's/-/_/g')_DEBUG=1
log "VERBOSE" "Enabling debug mode for module $CONF"
fi
DEBUG=0
else
log "MSG" "Warning: Configuration file $CONF is not readable, skipping."
fi
done
fi
if [ -r /etc/laptop-mode/laptop-mode.conf ] ; then
. /etc/laptop-mode/laptop-mode.conf
else
log "ERR" "$0: Configuration file /etc/laptop-mode/laptop-mode.conf not present or not readable."
exit 1
fi
if [ x$ENABLE_LAPTOP_MODE_TOOLS = x0 ]; then
log "MSG" "laptop-mode-tools is disabled in config file. Exiting"
exit 0;
fi
# Add a simple bash debug mode switch
if [ "$DEBUG" -eq 1 ]; then
set -vx;
fi
# Support for old config settings
if [ "$AC_HD" != "" ] ; then
AC_HD_WITHOUT_LM="$AC_HD"
AC_HD_WITH_LM="$AC_HD"
fi
if [ "$VERBOSE" != "" ] ; then
VERBOSE_OUTPUT="$VERBOSE"
fi
if [ "$CPU_MAXFREQ" != "" ] ; then
BATT_CPU_MAXFREQ="$CPU_MAXFREQ"
fi
if [ "$MAX_AGE" != "" ] ; then
LM_BATT_MAX_LOST_WORK_SECONDS="$MAX_AGE"
LM_AC_MAX_LOST_WORK_SECONDS="$MAX_AGE"
fi
if [ "$DEF_AGE" != "" ] ; then
DEF_MAX_AGE="$DEF_AGE"
fi
if [ "$LAPTOP_MODE_ALWAYS_ON" != "" ] ; then
ENABLE_LAPTOP_MODE_ALWAYS="$LAPTOP_MODE_ALWAYS_ON"
fi
if [ "$LM_WHEN_LID_CLOSED" != "" ] ; then
ENABLE_LAPTOP_MODE_WHEN_LID_CLOSED="$LM_WHEN_LID_CLOSED"
fi
if [ "$REMOUNT_PARTITIONS" != "" ] ; then
PARTITIONS="$REMOUNT_PARTITIONS"
fi
if [ "$READAHEAD" != "" ] ; then
LM_READAHEAD="$READAHEAD"
fi
if [ "$DO_REMOUNT_NOATIME" != "" ] ; then
CONTROL_NOATIME="$DO_REMOUNT_NOATIME"
fi
if [ "$DO_HD" != "" ] ; then
CONTROL_HD_IDLE_TIMEOUT="$DO_HD"
fi
if [ "$AC_HD_WITH_LM" != "" ] ; then
LM_AC_HD_IDLE_TIMEOUT="$AC_HD_WITH_LM"
fi
if [ "$AC_HD_WITHOUT_LM" != "" ] ; then
NOLM_HD_IDLE_TIMEOUT="$AC_HD_WITHOUT_LM"
fi
if [ "$BATT_HD" != "" ] ; then
LM_BATT_HD_IDLE_TIMEOUT="$BATT_HD"
fi
if [ "$DO_REMOUNTS" != "" ] ; then
CONTROL_MOUNT_OPTIONS="$DO_REMOUNTS"
fi
if [ "$DO_HD_POWERMGMT" != "" ] ; then
CONTROL_HD_POWERMGMT="$DO_HD_POWERMGMT"
fi
if [ "$AC_HDPARM_POWERMGMT_WITH_LM" != "" ] ; then
LM_AC_HD_POWERMGMT="$AC_HDPARM_POWERMGMT_WITH_LM"
fi
if [ "$AC_HDPARM_POWERMGMT_WITHOUT_LM" != "" ] ; then
NOLM_AC_HD_POWERMGMT="$AC_HDPARM_POWERMGMT_WITHOUT_LM"
fi
if [ "$BATT_HDPARM_POWERMGMT" != "" ] ; then
BATT_HD_POWERMGMT="$BATT_HDPARM_POWERMGMT"
fi
if [ "$DO_WRITECACHE" != "" ] ; then
CONTROL_HD_WRITECACHE="$DO_WRITECACHE"
fi
if [ "$AC_WRITECACHE_WITHOUT_LM" != "" ] ; then
NOLM_AC_HD_WRITECACHE="$AC_WRITECACHE_WITHOUT_LM"
fi
if [ "$BATT_WRITECACHE" != "" ] ; then
LM_HD_WRITECACHE="$BATT_WRITECACHE"
fi
if [ "$DIRTY_RATIO" != "" ]; then
LM_DIRTY_RATIO="$DIRTY_RATIO"
fi
if [ "$DIRTY_BACKGROUND_RATIO" != "" ] ; then
LM_DIRTY_BACKGROUND_RATIO="$DIRTY_BACKGROUND_RATIO"
fi
if [ "$DEF_DIRTY_RATIO" != "" ]; then
NOLM_DIRTY_RATIO="$DEF_DIRTY_RATIO"
fi
if [ "$DEF_DIRTY_BACKGROUND_RATIO" != "" ] ; then
NOLM_DIRTY_BACKGROUND_RATIO="$DEF_DIRTY_BACKGROUND_RATIO"
fi
if [ "$DO_CPU" != "" ] ; then
CONTROL_CPU_FREQUENCY="$DO_CPU"
fi
if [ "$CONTROL_CPU_MAXFREQ" != "" ] ; then
CONTROL_CPU_FREQUENCY="$CONTROL_CPU_MAXFREQ"
fi
if [ "$AC_CPU_MAXFREQ_WITH_LM" != "" ] ; then
LM_AC_CPU_MAXFREQ="$AC_CPU_MAXFREQ_WITH_LM"
fi
if [ "$AC_CPU_MAXFREQ_WITHOUT_LM" != "" ] ; then
NOLM_AC_CPU_MAXFREQ="$AC_CPU_MAXFREQ_WITHOUT_LM"
fi
if [ "$DO_SYSLOG" != "" ] ; then
CONTROL_SYSLOG_CONF="$DO_SYSLOG"
fi
if [ "$SYSLOG_SIGNAL_PROGRAM" != "" ] ;then
SYSLOG_CONF_SIGNAL_PROGRAM="$SYSLOG_SIGNAL_PROGRAM"
fi
if [ "$AC_SYSLOG_WITH_LM" != "" ] ; then
LM_AC_SYSLOG_CONF="$AC_SYSLOG_WITH_LM"
fi
if [ "$AC_SYSLOG_WITHOUT_LM" != "" ] ; then
NOLM_AC_SYSLOG_CONF="$AC_SYSLOG_WITHOUT_LM"
fi
if [ "$BATT_SYSLOG" != "" ] ; then
BATT_SYSLOG_CONF="$BATT_SYSLOG"
fi
if [ "$ENABLE_LAPTOP_MODE_ALWAYS" != "" ] ; then
ENABLE_LAPTOP_MODE_ON_AC="$ENABLE_LAPTOP_MODE_ALWAYS"
fi
if [ "$MINIMUM_BATTERY_MINUTES" != "" -a "$MINIMUM_BATTERY_CHARGE_PERCENT" = "" ] ; then
# Use a very conservative estimate (1% = 1 battery minute, 100 minutes in a battery)
# for backward compatibility.
MINIMUM_BATTERY_CHARGE_PERCENT="$MINIMUM_BATTERY_MINUTES"
fi
if [ -z "$MINIMUM_BATTERY_CHARGE_PERCENT" ] ; then
# Apply the default, now that we've determined that this is the minimum.
MINIMUM_BATTERY_CHARGE_PERCENT=3
fi
if [ "$AUTO_HIBERNATION_BATTERY_MINUTES" != "" -a "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" = "" ] ; then
# Use a very conservative estimate (1% = 1 battery minute, 100 minutes in a battery)
# for backward compatibility.
AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT="$AUTO_HIBERNATION_BATTERY_MINUTES"
fi
if [ -z "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" ] ; then
# Apply the default, now that we've determined that this is the minimum.
AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT=2
fi
# Postprocessing
if [ "$VERBOSE_OUTPUT" -ne 0 ] ; then
OUTPUT="/dev/stdout"
LM_VERBOSE="[ 1 = 1 ]"
else
OUTPUT="/dev/null"
LM_VERBOSE="[ 1 = 0 ]"
fi
if [ "$PARTITIONS" = "" ] ; then
PARTITIONS="auto /dev/mapper/*"
fi
# Expand shell wild cards immediately.
PARTITIONS=$( echo $PARTITIONS )
TERMINALS=$( echo $TERMINALS )
# Convert seconds to hdparm -S format
# Everything over 20 minutes is interpreted as 2 hours.
seconds_to_hdparm_S() {
if [ "$1" -eq 0 ] ; then
# disable.
echo 0
elif [ "$1" -gt 0 -a "$1" -lt 5 ] ; then
# 5 seconds minimum
echo 1
elif [ "$1" -le $((240*5)) ] ; then
# Values between 1 and 240 signify increments of 5 seconds
echo $(($1 / 5))
elif [ "$1" -lt $((30*60)) ] ; then
# Values between 20 and 30 minutes are rounded up to 30 minutes.
echo 241
elif [ "$1" -lt $((12*30*60)) ] ; then
# Values between 30 minutes and 6 hours (exclusive) yield values between
# 241 and 251, in 30-minute increments.
echo $(( 240 + ($1 / (30*60)) ))
else
# Larger values effectively indicate no timeout at all.
echo 0
fi
# Convert configured idle timeouts to hdparm -S format.
if [ "$LM_AC_HD_IDLE_TIMEOUT_SECONDS" != "" ] ; then
LM_AC_HD_IDLE_TIMEOUT=$(seconds_to_hdparm_S $LM_AC_HD_IDLE_TIMEOUT_SECONDS)
fi
if [ "$LM_BATT_HD_IDLE_TIMEOUT_SECONDS" != "" ] ; then
LM_BATT_HD_IDLE_TIMEOUT=$(seconds_to_hdparm_S $LM_BATT_HD_IDLE_TIMEOUT_SECONDS)
fi
if [ "$NOLM_HD_IDLE_TIMEOUT_SECONDS" != "" ] ; then
NOLM_HD_IDLE_TIMEOUT=$(seconds_to_hdparm_S $NOLM_HD_IDLE_TIMEOUT_SECONDS)
fi
# The main workhorse.
lmt_main_function ()
if [ "$1" = "status" ] ; then
# Display a status report.
log "STATUS" "Mounts:"
mount | sed "s/^/ /"
log "STATUS" " "
log "STATUS" "Drive power status:"
for disk in $HD; do
if [ -r $disk ]; then
hdparm -C $disk 2>/dev/null | sed "s/^/ /"
else
log "STATUS" " Cannot read $disk, permission denied - $0 needs to be run as root"
fi
done
log "STATUS" " "
log "STATUS" "(NOTE: drive settings affected by Laptop Mode cannot be retrieved.)"
log "STATUS" " "
log "STATUS" "Readahead states:"
cat /etc/mtab | while read DEV MP FST OPTS DUMP PASS ; do
# skip funny stuff
case "$FST" in
rootfs|unionfs|tmpfs|squashfs|sysfs|usbfs|proc|devpts) continue
esac
if [ -b $DEV ] ; then
if [ -r $DEV ] ; then
log "STATUS" " $DEV: $((`blockdev --getra $DEV` / 2)) kB"
else
log "STATUS" " Cannot read $DEV, permission denied - $0 needs to be run as root"
fi
fi
done
log "STATUS" " "
if [ -e /var/run/laptop-mode-tools/enabled ] ; then
log "STATUS" "Laptop Mode Tools is allowed to run: /var/run/laptop-mode-tools/enabled exists."
else
log "STATUS" "Laptop Mode Tools is NOT allowed to run: /var/run/laptop-mode-tools/enabled does not exist."
fi
log "STATUS" " "
STATFILES="/proc/sys/vm/laptop_mode /proc/apm /proc/pmu/info /proc/sys/vm/bdflush /proc/sys/vm/dirty_ratio /proc/sys/fs/xfs/age_buffer /proc/sys/fs/xfs/sync_interval /proc/sys/fs/xfs/lm_age_buffer /proc/sys/fs/xfs/lm_sync_interval /proc/sys/vm/pagebuf/lm_flush_age /proc/sys/fs/xfs/xfsbufd_centisecs /proc/sys/fs/xfs/xfssyncd_centisecs /proc/sys/vm/dirty_background_ratio /proc/sys/vm/dirty_expire_centisecs /proc/sys/fs/xfs/age_buffer/centisecs /proc/sys/vm/dirty_writeback_centisecs /sys/devices/system/cpu/*/cpufreq/cpuinfo_*_freq /sys/devices/system/cpu/*/cpufreq/scaling_governor /proc/acpi/button/lid/*/state /proc/acpi/ac_adapter/*/state /proc/acpi/battery/*/state /sys/class/power_supply/*/online /sys/class/power_supply/*/state"
for THISFILE in $STATFILES ; do
if [ -e "$THISFILE" ] ; then
log "STATUS" "$THISFILE:"
if [ -r "$THISFILE" ] ; then
cat "$THISFILE" | sed "s/^/ /"
else
log "STATUS" " Not accessible, permission denied - $0 needs to be run as root."
fi
log "STATUS" " "
fi
done
elif [ "$1" != "readconfig" -a "$1" != "defaults" ] ; then
KLEVEL="$(uname -r |
IFS='.-' read a b c
echo $a.$b
KMINOR="$(uname -r |
IFS='.-' read a b c d
# Strip any stuff from the end -- only the initial digits are part of the KMINOR.
echo $c | sed -e 's/\([[:digit:]]*\).*/\1/'
# Stop exporting everything -- what we do from here is private.
set +a
if [ "$1" = "--version" ] ; then
log "MSG" "Laptop Mode Tools $LMTVERSION"
exit 0
fi
if [ ! -e /proc/sys/vm/laptop_mode ] ; then
log "ERR" "Kernel does not have support for laptop mode. Please apply the laptop mode"
log "ERR" "patch or install a newer kernel."
exit 1
fi
if [ ! -w /proc/sys/vm/laptop_mode ] ; then
log "ERR" "You do not have enough privileges to enable laptop_mode."
exit 1
fi
INIT=0 # Display info in init script format?
FORCE=0 # Force reapplying the current state?
while [ "$1" != "" ] ; do
case "$1" in
init) INIT=1 ;;
force) FORCE=1 ;;
# Old options. We always do "auto" for any option now, but
# we still have to accept the options.
start) ;;
stop) ;;
auto) ;;
modules=*)
MODULES=$1
MODULES=${MODULES#"modules="}
devices=*)
DEVICES=$1
DEVICES=${DEVICES#"devices="}
*) log "ERR" "Unrecognized option $1."
exit 1 ;;
esac
shift
done
mkdir -p /var/run/laptop-mode-tools
# Used to display laptop mode state later on. This is the enabled/disabled
# state for laptop mode processing, it tells us nothing about whether laptop
# mode is actually _active_.
STATE=enabled
if [ "$ENABLE_LAPTOP_MODE_ON_BATTERY" -eq 0 -a "$ENABLE_LAPTOP_MODE_ON_AC" -eq 0 -a "$ENABLE_LAPTOP_MODE_WHEN_LID_CLOSED" -eq 0 ] ; then
STATE=disabled
fi
# Determine the power state.
# First try /sys/class/power_supply/*
FOUND_SYS_CLASS_POWER_SUPPLY_AC=0
ON_AC=0
for POWER_SUPPLY in /sys/class/power_supply/* ; do
if [ -f $POWER_SUPPLY/type ] ; then
if [ "$(cat $POWER_SUPPLY/type)" = "Mains" ] ;then
log "VERBOSE" "Determining power state from $POWER_SUPPLY/online."
FOUND_SYS_CLASS_POWER_SUPPLY_AC=1
if [ "$(cat $POWER_SUPPLY/online)" = 1 ] ; then
ON_AC=1
fi
fi
fi
done
if [ $FOUND_SYS_CLASS_POWER_SUPPLY_AC = 1 ] ; then
# Already found it!
log "VERBOSE" "Not trying other options, already found a power supply."
elif [ -d /proc/acpi/ac_adapter ] ; then
log "VERBOSE" "Determining power state from /proc/acpi/ac_adapter."
ADAPTERS_FOUND=0
ON_AC=0
for ADAPTER in /proc/acpi/ac_adapter/* ; do
if [ -f $ADAPTER/state ] ; then
ADAPTERS_FOUND=1
STATUS=`awk '/^state: / { print $2 }' $ADAPTER/state`
if [ "$STATUS" = "on-line" ] ; then
ON_AC=1
fi
fi
done
if [ "$ADAPTERS_FOUND" -eq 0 ] ; then
ON_AC=1
fi
elif [ -f /proc/pmu/info ] ; then
log "VERBOSE" "Determining power state from /proc/pmu/info."
if ( grep -q "^AC Power.*0$" /proc/pmu/info ) ; then
log "VERBOSE" "/proc/pmu/info indicates absence of AC power."
ON_AC=0
else
# It is possible that there is no AC Power = 1 in the file,
# but we always assume AC power when we're not sure.
ON_AC=1
log "VERBOSE" "/proc/pmu/info indicates presence of AC power."
fi
elif [ -f /proc/apm ] ; then
log "VERBOSE" "Determining power state from /proc/apm."
read D1 D2 D3 APM_AC_STATE D0 </proc/apm
if [ "$APM_AC_STATE" = "0x00" ] ; then
ON_AC=0
else
ON_AC=1
fi
else
log "VERBOSE" "No /sys/class/power_supply, ACPI, APM or PMU power management information found -- assuming AC power is present."
ON_AC=1
fi
# Determine whether to activate or deactivate laptop mode.
ACTIVATE=0
if [ "$ON_AC" -eq 1 ] ; then
if [ "$ENABLE_LAPTOP_MODE_ON_AC" -ne 0 ] ; then
log "VERBOSE" "On AC power: Activating, because ENABLE_LAPTOP_MODE_ON_AC is set."
ACTIVATE=1
else
log "VERBOSE" "On AC power: Deactivating, because ENABLE_LAPTOP_MODE_ON_AC is not set."
ACTIVATE=0
fi
else
if [ "$ENABLE_LAPTOP_MODE_ON_BATTERY" -ne 0 ] ; then
log "VERBOSE" "On battery power: Activating, because ENABLE_LAPTOP_MODE_ON_BATTERY is set."
ACTIVATE=1
else
log "VERBOSE" "On battery power: Deactivating, because ENABLE_LAPTOP_MODE_ON_BATTERY is not set."
ACTIVATE=0
fi
fi
if [ "$ENABLE_LAPTOP_MODE_WHEN_LID_CLOSED" -ne 0 -a "$ACTIVATE" -eq 0 ] ; then
if [ -x "`which hal-find-by-property`" ] ; then
HAL_LID_BUTTON=$(hal-find-by-property --key "button.type" --string "lid")
fi
if [ "$HAL_LID_BUTTON" != "" ] ; then
HAL_LID_BUTTON_STATE=$(hal-get-property --udi $(hal-find-by-property --key "button.type" --string "lid") --key "button.state.value")
if [ "$HAL_LID_BUTTON_STATE" = "true" ] ; then
log "VERBOSE" "Setting action to \"start\" because the lid is closed (says HAL)."
ACTIVATE=1
fi
elif [ -f /proc/acpi/button/lid/*/state ] ; then
if ( grep -q "closed" /proc/acpi/button/lid/*/state ) ; then
log "VERBOSE" 'Setting action to "start" because the lid is closed (says /proc/acpi/button/lid/*/state).'
ACTIVATE=1
fi
else
log "MSG" "Warning: ENABLE_LAPTOP_MODE_WHEN_LID_CLOSED is set, but there is no file"
log "MSG" "/proc/acpi/button/lid/.../state, and hal information is not available either!"
fi
fi
# If the init script has not been run or has been run with the "stop"
# argument, then we should never start laptop mode.
if [ ! -f /var/run/laptop-mode-tools/enabled ] ; then
log "VERBOSE" "Laptop mode disabled because /var/run/laptop-mode-tools/enabled is missing."
STATE=disabled
fi
if [ "$ACTIVATE" -eq 1 -a -f /etc/default/laptop-mode ] ; then
. /etc/default/laptop-mode
if ! ( echo "$ENABLE_LAPTOP_MODE" |grep y ) ; then
log "VERBOSE" "Not starting laptop mode because it is disabled in /etc/default/laptop-mode."
STATE=disabled
fi
fi
if [ "$STATE" = "disabled" ] ; then
ACTIVATE=0
fi
# Check whether we are allowed to activate the data-loss-sensitive stuff.
# If the battery charge is too low, we want to disable this, but not the
# other power-saving stuff.
if [ "$ACTIVATE" -eq 0 ] ; then
ACTIVATE_WITH_POSSIBLE_DATA_LOSS=0
elif [ "$ON_AC" = 1 ] ; then
log "VERBOSE" "On AC, not checking minimum battery charge."
ACTIVATE_WITH_POSSIBLE_DATA_LOSS=1
else
ACTIVATE_WITH_POSSIBLE_DATA_LOSS=1
ENOUGH_CHARGE=0
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=0
# Weird way of checking that /sys/class/power_supply is not empty -- but it works.
if [ "$(echo /sys/class/power_supply/*)" != '/sys/class/power_supply/*' ] ; then
log "VERBOSE" "Not on AC and we have battery information in /sys/class/power_supply/BAT* -- checking minimum battery charge."
for BATT in /sys/class/power_supply/* ; do
BATT_TYPE=$(cat $BATT/type)
log "VERBOSE" "$BATT is of type $BATT_TYPE."
if [ "$BATT_TYPE" != "Battery" ] ; then
log "VERBOSE" "Not of type \"Battery\", skipping."
else
PREV_ENOUGH_CHARGE=$ENOUGH_CHARGE
PREV_ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=$ENOUGH_CHARGE_TO_PREVENT_HIBERNATION
log "VERBOSE" "Checking levels for $BATT."
PRESENT=$(cat $BATT/present)
log "VERBOSE" "Present: $PRESENT."
# Only do if the battery is present
if [ "$PRESENT" -eq 1 ] ; then
FOUND_AN_ENABLED_CHECK=0
FOUND_AN_ENABLED_HIBERNATION_CHECK=0
# Get the remaining capacity.
IN_UAH=0
IN_UWH=0
if [ -f $BATT/charge_now ] ; then
REMAINING=$(cat $BATT/charge_now)
IN_UAH=1 # charge_* is in microAmpere-hours
elif [ -f $BATT/energy_now ] ; then
REMAINING=$(cat $BATT/energy_now)
IN_UWH=1 # energy_* is in microWatt-hours
else
REMAINING=0
fi
if [ -z "$REMAINING" -o "$REMAINING" -eq 0 ] ; then
log "VERBOSE" "Battery does not report remaining charge. Perhaps it is not present?"
REMAINING=0
fi
log "VERBOSE" "Remaining charge: $REMAINING"
if [ -f $BATT/charge_full_design ] ; then
CAPACITY=$(cat $BATT/charge_full_design)
elif [ -f $BATT/energy_full_design ] ; then
CAPACITY=$(cat $BATT/energy_full_design)
else
CAPACITY=0
fi
if [ -z "$CAPACITY" -o "$CAPACITY" -eq 0 ] ; then
log "VERBOSE" "Battery does not report design full charge, using non-design full charge."
if [ -f $BATT/charge_full ] ; then
CAPACITY=$(cat $BATT/charge_full)
elif [ -f $BATT/energy_full_design ] ; then
CAPACITY=$(cat $BATT/energy_full)
else
CAPACITY=0
fi
if [ -z "$CAPACITY" -o "$CAPACITY" -eq 0 ] ; then
log "VERBOSE" "Battery does not report non-design full charge."
CAPACITY=0
fi
fi
log "VERBOSE" "Full capacity: $CAPACITY"
# Check the charge percentage
if [ "$MINIMUM_BATTERY_CHARGE_PERCENT" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$CAPACITY" -eq 0 ] ; then
log "MSG" "WARNING: Battery does not report a capacity. Minimum battery"
log "MSG" "charge checking does not work without a design capacity."
ENOUGH_CHARGE=1
elif [ "$(($REMAINING * 100 / $CAPACITY))" -ge "$MINIMUM_BATTERY_CHARGE_PERCENT" ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$CAPACITY" -eq 0 ] ; then
log "MSG" "WARNING: Battery does not report a design capacity. Auto hibernation"
log "MSG" "does not work without a design capacity."
ENOUGH_CHARGE=1
elif [ "$(($REMAINING * 100 / $CAPACITY))" -ge "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
# $BATT/alarm is the design_capacity_warning of a battery.
ALARM_LEVEL=$(cat $BATT/alarm)
if [ "$ALARM_LEVEL" -ne 0 ] ; then
if [ "$REMAINING" -le "$ALARM_LEVEL" ] ; then
# Restore the state we had before checking this battery, so that
# this battery does not count as having enough charge.
ENOUGH_CHARGE=$PREV_ENOUGH_CHARGE
elif [ "$FOUND_AN_ENABLED_CHECK" -eq 0 ] ; then
# This is the only check that is enabled. In that case a non-critical
# battery level counts as "enough". (If we would count non-critical
# battery levels as enough *always*, then the other settings would
# have no effect; this is only a final fallback.)
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_ON_CRITICAL_BATTERY_LEVEL" -ne 0 ] ; then
if [ "$REMAINING" -le "$ALARM_LEVEL" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=$PREV_ENOUGH_CHARGE_TO_PREVENT_HIBERNATION
elif [ "$FOUND_AN_ENABLED_HIBERNATION_CHECK" -eq 0 ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
# Fallback: hard values
if [ "$IN_UAH" -ne 0 ] ; then
if [ "$MINIMUM_BATTERY_CHARGE_MAH" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$REMAINING" -ge $((1000*"$MINIMUM_BATTERY_CHARGE_MAH")) ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_MAH" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$REMAINING" -ge $((1000*"$AUTO_HIBERNATION_BATTERY_CHARGE_MAH")) ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
elif [ "$IN_UWH" -ne 0 ] ; then
if [ "$MINIMUM_BATTERY_CHARGE_MWH" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$REMAINING" -ge $((1000*"$MINIMUM_BATTERY_CHARGE_MWH")) ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_MWH" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$REMAINING" -ge $((1000*"$AUTO_HIBERNATION_BATTERY_CHARGE_MWH")) ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
else
log "ERR" "Failed to determine battery charge. Battery charge units are not in"
log "ERR" "mWh, uWh, mAh or uAh."
fi
else
log "VERBOSE" "Battery is not present."
fi
fi
done
elif [ "$(echo /proc/acpi/battery/*)" != '/proc/acpi/battery/*' ] ; then
log "VERBOSE" "Not on AC and we have batteries in /proc/acpi/battery -- checking minimum battery charge."
for BATT in /proc/acpi/battery/* ; do
PREV_ENOUGH_CHARGE=$ENOUGH_CHARGE
PREV_ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=$ENOUGH_CHARGE_TO_PREVENT_HIBERNATION
BATT_STATE=$BATT/state
BATT_INFO=$BATT/info
log "VERBOSE" "Checking info and state for $BATT."
# Only do if the battery is present
if ( grep -q 'present:.*yes' $BATT_INFO ) ; then
FOUND_AN_ENABLED_CHECK=0
FOUND_AN_ENABLED_HIBERNATION_CHECK=0
# Get the remaining capacity.
REMAINING=`grep "remaining capacity:" $BATT_STATE | sed "s/.* \([0-9][0-9]* \).*/\1/" `
if [ -z "$REMAINING" ] ; then
log "VERBOSE" "Battery does not report remaining charte. Perhaps it is not present?"
REMAINING=0
fi
log "VERBOSE" "Remaining charge: $REMAINING"
CAPACITY=`grep "design capacity:" $BATT_INFO | sed "s/.* \([0-9][0-9]* \).*/\1/" `
if [ -z "$CAPACITY" ] ; then
log "VERBOSE" "Battery does not report capacity. Perhaps it is not present?"
CAPACITY=0
fi
log "VERBOSE" "Design capacity: $CAPACITY"
# Check the charge percentage
if [ "$MINIMUM_BATTERY_CHARGE_PERCENT" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$CAPACITY" -eq 0 ] ; then
log "MSG" "WARNING: Battery does not report a design capacity. Minimum battery"
log "MSG" "charge checking does not work without a design capacity."
ENOUGH_CHARGE=1
elif [ "$(($REMAINING * 100 / $CAPACITY))" -ge "$MINIMUM_BATTERY_CHARGE_PERCENT" ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$CAPACITY" -eq 0 ] ; then
log "MSG" "WARNING: Battery does not report a design capacity. Auto hibernation"
log "MSG" "does not work without a design capacity."
ENOUGH_CHARGE=1
elif [ "$(($REMAINING * 100 / $CAPACITY))" -ge "$AUTO_HIBERNATION_BATTERY_CHARGE_PERCENT" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
# Fallback: hard values.
# Determine the reporting unit.
IN_MAH=0
IN_MWH=0
if ( grep -q mWh $BATT_INFO ) ; then
IN_MWH=1
elif ( grep -q mAh $BATT_INFO ) ; then
IN_MAH=1
fi
if [ "$IN_MAH" -ne 0 ] ; then
if [ "$MINIMUM_BATTERY_CHARGE_MAH" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$REMAINING" -ge "$MINIMUM_BATTERY_CHARGE_MAH" ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_MAH" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$REMAINING" -ge "$AUTO_HIBERNATION_BATTERY_CHARGE_MAH" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
elif [ "$IN_MWH" -ne 0 ] ; then
if [ "$MINIMUM_BATTERY_CHARGE_MWH" -ne 0 ] ; then
FOUND_AN_ENABLED_CHECK=1
if [ "$REMAINING" -ge "$MINIMUM_BATTERY_CHARGE_MWH" ] ; then
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_BATTERY_CHARGE_MWH" -ne 0 ] ; then
FOUND_AN_ENABLED_HIBERNATION_CHECK=1
if [ "$REMAINING" -ge "$AUTO_HIBERNATION_BATTERY_CHARGE_MWH" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
else
log "ERR" "Failed to determine battery charge. Battery charge units are not in"
log "ERR" "mWh or mAh."
fi
CAP_STATE=`sed -r 's/^capacity state:\s*(.*)\s*$/\1/;t;d' "$BATT_STATE"`
if [ "$DISABLE_LAPTOP_MODE_ON_CRITICAL_BATTERY_LEVEL" -ne 0 ] ; then
if [ "$CAP_STATE" = "critical" ] ; then
# Restore the state we had before checking this battery, so that
# this battery does not count as having enough charge.
ENOUGH_CHARGE=$PREV_ENOUGH_CHARGE
elif [ "$FOUND_AN_ENABLED_CHECK" -eq 0 ] ; then
# This is the only check that is enabled. In that case a non-critical
# battery level counts as "enough". (If we would count non-critical
# battery levels as enough *always*, then the other settings would
# have no effect; this is only a final fallback.)
ENOUGH_CHARGE=1
fi
fi
if [ "$AUTO_HIBERNATION_ON_CRITICAL_BATTERY_LEVEL" -ne 0 ] ; then
if [ "$CAP_STATE" = "critical" ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=$PREV_ENOUGH_CHARGE_TO_PREVENT_HIBERNATION
elif [ "$FOUND_AN_ENABLED_HIBERNATION_CHECK" -eq 0 ] ; then
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
fi
fi
else
log "VERBOSE" "Battery is not present."
fi
done
else
ENOUGH_CHARGE=1
ENOUGH_CHARGE_TO_PREVENT_HIBERNATION=1
log "VERBOSE" "Not on AC and could not check battery state -- data loss sensitive features stay enabled and auto-hibernation will not work."
fi
if [ "$ENABLE_AUTO_HIBERNATION" -ne 0 -a "$ENOUGH_CHARGE_TO_PREVENT_HIBERNATION" -eq 0 ] ; then
log "VERBOSE" "None of the batteries have a charge above the auto-hibernation level."
log "VERBOSE" "Starting hibernation."
if [ -x $HIBERNATE_COMMAND ]; then
$HIBERNATE_COMMAND
elif [ -f /sys/power/state ]; then
grep -q disk /sys/power/state && echo disk > /sys/power/state
fi
# Don't continue -- if things are configured correctly, then we
# will be called on resume.
exit 0
fi
if [ "$ENOUGH_CHARGE" -eq 0 ] ; then
log "VERBOSE" "None of the batteries have a charge above the minimum level."
log "VERBOSE" "Deactivating data loss sensitive features."
ACTIVATE_WITH_POSSIBLE_DATA_LOSS=0
fi
fi
if [ "$INIT" -eq 0 ] ; then
log "MSG" "Laptop mode "
fi
# WAS_ACTIVE is used later on. If there is no /var/run/laptop-mode-tools/state, then
# we know that laptop mode wasn't active before.
WAS_ACTIVE=0
log "VERBOSE" "Checking if desired state is different from current state."
if [ -f /var/run/laptop-mode-tools/state ] ; then
read WAS_ACTIVE WAS_ON_AC WAS_ACTIVATE_WITH_POSSIBLE_DATA_LOSS WAS_STATE < /var/run/laptop-mode-tools/state
if [ "$WAS_STATE" != "" ] ; then
if [ "$WAS_ACTIVE" -eq "$ACTIVATE" -a "$WAS_ON_AC" -eq "$ON_AC" -a "$WAS_ACTIVATE_WITH_POSSIBLE_DATA_LOSS" -eq "$ACTIVATE_WITH_POSSIBLE_DATA_LOSS" -a "$WAS_STATE" = "$STATE" -a "$FORCE" -eq 0 ] ; then
log "MSG" "$STATE, "
if [ "$WAS_ACTIVE" -eq 1 ] ; then
log "MSG" "active [unchanged]"
if [ "$ACTIVATE_WITH_POSSIBLE_DATA_LOSS" -eq 0 ] ; then
log "MSG" " (Data-loss sensitive features disabled.)"
fi
else
log "MSG" "not active [unchanged]"
fi
exit 0
fi
fi
else
log "VERBOSE" "/var/run/laptop-mode-tools/state does not exist, no previous state."
fi
echo "$ACTIVATE $ON_AC $ACTIVATE_WITH_POSSIBLE_DATA_LOSS $STATE" > /var/run/laptop-mode-tools/state
if [ "$ACTIVATE" -eq 1 ] ; then
log "MSG" "$STATE, active"
if [ "$ACTIVATE_WITH_POSSIBLE_DATA_LOSS" -eq 0 ] ; then
log "MSG" " (Data-loss sensitive features disabled.)"
fi
else
log "MSG" "$STATE, not active"
fi
# Finally, call laptop-mode-tools modules. The modules can use the settings
# from the config files, but they may NOT assume the settings actually exist,
# as no defaults have been given for them.
# Note that the /usr/local/lib path is deprecated.
export FORCE STATE ON_AC ACTIVATE ACTIVATE_WITH_POSSIBLE_DATA_LOSS KLEVEL KMINOR WAS_ACTIVE LM_VERBOSE DEVICES
for SCRIPT in /usr/share/laptop-mode-tools/modules/* /usr/local/lib/laptop-mode-tools/modules/* /usr/local/share/laptop-mode-tools/modules/* /etc/laptop-mode/modules/* ; do
if [ -z "$MODULES" ] ; then
# If a module list has not been provided, execute all modules
EXECUTE_SCRIPT=1
else
# If a module list has been provided, execute only the listed
# modules.
EXECUTE_SCRIPT=0
for MODULE in $MODULES; do
# Attempt to remove the module name from the end of the
# full script path. If the module name matches the
# script, the name will be removed from the end of the
# full file path, leaving the path to the script. If
# there was not a match made, the module name would not
# be removed from the path, and $PATH_TO_SCRIPT would
# be the same as $SCRIPT.
PATH_TO_SCRIPT=${SCRIPT%%$MODULE}
# Execute the script if a match was found (module name
# was removed from the script path, making it shorter.
if [ $PATH_TO_SCRIPT != $SCRIPT ] ; then
EXECUTE_SCRIPT=1
fi
done
fi
if [ -x "$SCRIPT" -a $EXECUTE_SCRIPT -eq 1 ] ; then
log "VERBOSE" "Invoking module $SCRIPT."
SCRIPT_DEBUG=$SCRIPT; # We do this because in start-stop-programs module a $SCRIPT variable is used. That
# changes the whole meaning when passed to disableDebug ()
enableDebug $SCRIPT_DEBUG;
. $SCRIPT
disableDebug $SCRIPT_DEBUG;
else
log "VERBOSE" "Module $SCRIPT is not executable or is to be skipped."
fi
done
exit 0
# This fi closes the if for "readconfig". If I would have indented this one
# I would have indented the whole file. :)
fi
lmt_load_config
lock_retry ()
( $FLOCK -n -x -w 1 8 || exit 0;
i=10;
while [ $i -ge 1 ]
do
log "ERR" "Couldn't acquire lock. Retrying.... PID is $$\n"
$FLOCK -x -w 1 9 && lmt_main_function "$@" && break;
i=$(( $i - 1 ))
done
) 8>$LMT_REQ_LOCK
# Check and acquire locks and then exec.
( $FLOCK -n -x -w 1 8; ) 8>$LMT_REQ_LOCK
($FLOCK -n -x -w 1 9 && lmt_main_function "$@";) || lock_retry "$@"
) 9<>$LMT_INVOC_LOCK
# We do a special run of battery polling daemon here so that it does not get
# plagued by the lock. We need the polling daemon to be independent of any locks
if [ x$ENABLE_BATTERY_LEVEL_POLLING = x1 ] && [ x$BLACKLIST_IN_FLOCK = x1 ]; then
log "VERBOSE" "Battery level polling is enabled."
if [ x$ON_AC = x1 ] ; then
log "VERBOSE" "On AC, stopping the polling daemon."
# In AC mode we disable the polling daemon.
killall -q lm-polling-daemon
else
if ! pidof -x lm-polling-daemon ; then
log "VERBOSE" "On battery and there was no polling daemon yet, starting the polling daemon."
# If there is no polling daemon, we start one.
/usr/share/laptop-mode-tools/module-helpers/lm-polling-daemon < /dev/null > /dev/null 2> /dev/null &
fi
fi
else
log "VERBOSE" "Battery level polling is disabled."
fi
exit 0;
and here is the lines which archwiki mentions
case "$KLEVEL" in
"2.4" ) ;;
"2.6" ) ;;
log "ERR" "Unhandled kernel version: $KLEVEL ('uname -r' = '$(uname -r)')" >&2
exit 1
esacI had the problem but edited the line in /usr/sbin/laptop_mode and it worked. But thoes lines are not there anymore. I guess they changed it at the recent update of laptop-mode-tools.
Regarding your heat problem; is there any other thing you use to cut down power usage (from AUR maybe)? I use acpi_call from AUR had to edit lines there aswell, but it should be updated by now.
Maybe you are looking for
-
My ipad is disabled and it says i need to connect to itunes when i connect it to itunes, it says it wont recognize it until i put my passcode into my ipad, but with my ipad disabled, this is immposible, how can i resolve this problem?
-
I can't seem to get my friend's G3 iMac (Bondi Blue) that to boot from a CD. It's spent it's life as part of a corporate network so on boot it tries to load something from the network called "Macintosh Manager." Because it is no longer connected to t
-
How do i get back to itunes from the radio
How do i get back into itunes from the radio!
-
Buttons to play external swf files
Hello I know what to do but I do not know how to do it. I want to make some tutorial movies available to users. I have about 12 little swf files that were created in camtasia, I would like to make them available though a single player instance. Here
-
How do i save a frame on safari??
im looking to save a frame off an ebay auction for security purposes. anyone know how to do that? thanks a bunch