You are not logged in.

#1 2011-02-07 10:07:23

steffinger
Member
From: Munich/Beijing
Registered: 2011-02-07
Posts: 41

Weird issue with pm-suspend and libatasmart

Hi everyone,

i got serious problems with suspending to disk. I run an Asus F5SL Laptop and after suspension the waking up process produces an error which looks like this in the error.log:

Feb  6 19:55:32 localhost kernel: ata1: ACPI set timing mode failed (status=0x300b)
Feb  6 19:55:32 localhost kernel: ata3.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen
Feb  6 19:55:32 localhost kernel: ata3.00: failed command: READ VERIFY SECTOR(S)
Feb  6 19:55:32 localhost kernel: ata3.00: cmd 40/00:01:00:00:00/00:00:00:00:00/e0 tag 0
Feb  6 19:55:32 localhost kernel: res 40/00:00:00:4f:c2/00:00:00:00:00/00 Emask 0x4 (timeout)
Feb  6 19:55:32 localhost kernel: ata3.00: status: { DRDY }
Feb  6 19:55:32 localhost kernel: pm_op(): scsi_bus_resume_common+0x0/0x40 [scsi_mod] returns 134217730
Feb  6 19:55:32 localhost kernel: PM: Device 2:0:0:0 failed to resume async: error 134217730
Feb  6 19:57:32 localhost kernel: sr 0:0:0:0: timing out command, waited 120s
Feb  6 19:59:02 localhost kernel: sr 0:0:0:0: timing out command, waited 90s
Feb  6 20:00:02 localhost kernel: sr 0:0:0:0: timing out command, waited 60s
Feb  6 20:01:02 localhost kernel: sr 0:0:0:0: timing out command, waited 60s
Feb  6 20:03:02 localhost kernel: sr 0:0:0:0: timing out command, waited 120s

and if i then want to suspend again I get following message in the error.log:

localhost kernel: Freezing of tasks failed after 20.01 seconds (1 tasks refusing to freeze, wq_busy=0):

This means I can only suspend once everytime i boot up. I'm searching the internet and working around with this issue for more than one week now and the latest I found is: When I delete /usr/lib/libatasmart.so.4.0.3 and /usr/lib/libatasmart.so.4 i can suspend to disk as often as I want but i still get the error as the one above, just without the kernel timing out command.

I try to provide some more Information about my system:

The pm-suspend.log is not very informative as I use laptop-mode:

enabled, not active

/usr/lib/pm-utils/sleep.d/01laptop-mode resume suspend: success.
Running hook /usr/lib/pm-utils/sleep.d/01grub resume suspend:

/usr/lib/pm-utils/sleep.d/01grub resume suspend: success.
Running hook /usr/lib/pm-utils/sleep.d/00powersave resume suspend:

/usr/lib/pm-utils/sleep.d/00powersave resume suspend: success.
Running hook /usr/lib/pm-utils/sleep.d/00logging resume suspend:

/usr/lib/pm-utils/sleep.d/00logging resume suspend: success.
Mo 7. Feb 14:45:33 CST 2011: Finished.

My /etc/rc.conf

LOCALE="de_DE.UTF-8"
HARDWARECLOCK="UTC"
TIMEZONE="Asia/Shanghai"
KEYMAP="de"
CONSOLEFONT="default8x16"
CONSOLEMAP=
USECOLOR="yes"

MOD_AUTOLOAD="yes"
#MOD_BLACKLIST=() #deprecated
MODULES=(fuse acpi_cpufreq cpufreq_ondemand !asus_acpi asus_laptop radeon)
USELVM="no"
HOSTNAME="something"
lo="lo 127.0.0.1"
INTERFACES=(lo !eth0 !wlan0)

gateway="default gw 192.168.0.1"
ROUTES=(!gateway)
DAEMONS=(syslog-ng dbus hal networkmanager @ntpd @netfs @crond @alsa @laptop-mode @laptop-init gdm)

My mkinitcpio.conf:

MODULES=""

BINARIES=""

FILES=""

HOOKS="base udev autodetect pata scsi sata resume filesystems"
$hwdetect-modules

shows the following:

MODULES=(ac battery button processor thermal video cdrom agpgart sis-agp tpm_bios tpm tpm_tis tpm_tis drm_kms_helper drm radeon ttm hid i2c-algo-bit i2c-core evdev joydev pcspkr psmouse serio_raw sparse-keymap uvcvideo v4l1-compat videodev pci_hotplug shpchp asus_acpi asus-laptop output snd-mixer-oss snd-pcm-oss snd-hwdep snd snd-page-alloc snd-pcm snd-timer snd-hda-codec snd-hda-intel soundcore pata_sis scsi_mod sata_sis mii sis190 mac80211 rfkill ath5k ath cfg80211 usb-storage usbhid usbcore ehci-hcd ohci-hcd option usbserial usb_wwan uas sd_mod sr_mod st)

and finally some parts of my grub.cfg:

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
  load_env
fi
set default="0"
if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}

function load_video {
  insmod vbe
  insmod vga
  insmod video_bochs
  insmod video_cirrus
}

set menu_color_normal=light-blue/black
set menu_color_highlight=light-cyan/blue

insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set=root 87dc5e92-2999-4e40-b466-29f08b85909d
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=1024x768x24
  load_video
  insmod gfxterm
fi
terminal_output gfxterm
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set=root 87dc5e92-2999-4e40-b466-29f08b85909d
set locale_dir=($root)/boot/grub/locale
set lang=de_DE
insmod gettext
set timeout=5
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_archtheme ###
set menu_color_normal=light-blue/black
set menu_color_highlight=light-cyan/blue
### END /etc/grub.d/05_archtheme ###

### BEGIN /etc/grub.d/09_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
menuentry "Arch Linux" --class archlinux --class gnu-linux --class gnu --class os {
    load_video
    insmod part_msdos
    insmod ext2
    set root='(hd0,msdos1)'
    search --no-floppy --fs-uuid --set=root 87dc5e92-2999-4e40-b466-29f08b85909d
    echo    'Loading Linux vmlinuz26 ...'
    linux    /boot/vmlinuz26 root=/dev/disk/by-uuid/87dc5e92-2999-4e40-b466-29f08b85909d resume=/dev/disk/by-uuid/2c63d1e2-c1b7-49a9-8c7a-b877d601e559 ro  quiet
    echo    'Loading initial ramdisk ...'
    initrd    /boot/kernel26.img
}
### END /etc/grub.d/09_custom ###

Removing libatasmart is not really an option for me because I use Gnome and libatasmart is necessary for automounting as I understand.

Does anyone have any advices? What else can I provide for you to understand the problem? Is it a bug and how to file it? Where can I read more about problems like this?

Thank you for any help.

Offline

#2 2011-05-20 10:01:34

steffinger
Member
From: Munich/Beijing
Registered: 2011-02-07
Posts: 41

Re: Weird issue with pm-suspend and libatasmart

After some time I recognized that I went into the wrong direction before. I got, that my real problem is not libatasmart, but the module sr_mod which is timing out and causing ksoftirqd to run with 100% cpu-usage of one processor thread (which is very nice, because otherwise the kernel would crash because of all the soft interrupts). So I went on and removed sr_mod temporarily.

rmmod sr_mod

This works pretty well for me since I can suspend now as much as I want and the system wakes up after all. I still get this small message:

ata1: ACPI set timing mode failed (status=0x300b)

after resume, but this seems not to be a bigger problem.

The more interesting thing is, that you can not mount CDs or DVDs if you remove sr_mod from the kernel, because that is what I think it is made for. As I still like to use this type of media, it is pretty annoying, that I can't

modprobe sr_mod

after a resume, because than I get a lot of small soft interrupts and sr_mod is timing out again.

Btw: I use a laptop with a SIS 966 chipset. Might that cause all the trouble? Can anyone think of any further reading or trying or bugreporting?

Offline

Board footer

Powered by FluxBB