[ltp] ! (Re: New ATI Driver) - Still not much luck
D. Sen
linux-thinkpad@linux-thinkpad.org
Wed, 16 Nov 2005 20:02:42 +1100
This is a multi-part message in MIME format.
--------------050700040400030302080504
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Here is my suspend script for ACPI. Can anyone poke a hole through it?
Florian Reitmeir wrote:
> On Die, 15 Nov 2005, D. Sen wrote:
>
>
>>Nope ....still no luck!!! recompiled the kernel (2.6.14-2) with the
>>suspend 2 patch and almost exact config file as Fionn (except I have xfs
>>support built in to the kernel).
>>
>>So now I have the exact same kernel and xorg.conf as Fionn and still
>>cant get suspend/resume (to memory) to work.
>>
>>The only other variable are the acpi suspend/resume scripts. Can anyone
>>(who has this working) post them?
>
>
> suspend worked with the default script from acpid for me fine (i also use
> only XFS). Make sure you boot your kernel with the acpi_sleep parameter..
>
> acpi_sleep= [HW,ACPI] Sleep options
> Format: { s3_bios, s3_mode }
> See Documentation/power/video.txt
>
> s3_bios worked for me.
>
>
>>>Still not much luck though. I havent recompiled the kernel to include
>>>suspend2 support YET. This is mostly because I dont need
>>>hibernate/suspend-to-disk as much as I need suspend-to-ram.
>>>
>>>Using your xorg.conf didnt help either. Still got the terminal window
>>>with the text "inu" after resume and a lockup.
>>>
>>>Next I removed the automatic insmoding of intel_agp and agpgart during
>>>startup. This seemed to help a little in that I got X back (after a
>>>resume) but with a large amount of distortions and finally a lockup.
>>>
>>>Then I tried recompiling the fglrx.o module. This helped in that I got X
>>>back and it was functional. When I tried to plot a 3D plot using matlab,
>>>everything locked up again.
>>>
>>>So the next step is to install a 2.6.14 kernel with suspend2 support and
>>>see if that helps.
>>>
>>>Thanks again (and still would appreciate any help/hints on whats going on).
>>>
>>>DS
>>>
>>>Fionn Behrens wrote:
>>>
>>>
>>>>On Di, 2005-11-15 at 03:09 +1100, D. Sen wrote:
>>>>
>>>>
>>>>>Could you send me your xorg.conf and the kernel .config?
>>>>
>>>>
>>>>
>>>>The files can be found at http://fionn.de/config/
>>>>I used fglrxconfig to create the xorg.conf (warning, your old config
>>>>gets overwritten!) and afterwards I edited some values and put the
>>>>synaptics stuff back in. But it already worked fine with the fglrx
>>>>"factory" config.
>>>>
>>>>
>>>>
>>>>>Also, did you configure the kernel for suspend 2?
>>>>
>>>>
>>>>
>>>>Yes, but I actually use it almost never and have not tried it yet. There
>>>>have been other posters today who reported to have had success with
>>>>suspend2 and how.
>>>>After all the battery can hold up S3 for about a week and my Notebook
>>>>aint never off that long.
>>>>
>>>>
>>>>best regards,
>>>> Fionn
>>
>>--
>>The linux-thinkpad mailing list home page is at:
>>http://mailman.linux-thinkpad.org/mailman/listinfo/linux-thinkpad
>>
>
>
--------------050700040400030302080504
Content-Type: application/x-sh;
name="lid.sh"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="lid.sh"
#!/bin/sh
# /etc/acpi/lid.sh
#
# from: http://www.enyo.de/fw/hardware/thinkpad/
#
shlock -f /var/run/sleep.lock -p $$
if [ $(( `date "+%s"` - `stat -c "%Z" /var/run/sleep 2>/dev/null` )) -lt 3 ]; then
echo "detected possible signal bounce, skipping" >&2
echo diff: $(( `date "+%s"` - `stat -c "%Z" /var/run/sleep 2>/dev/null` )) >&2
exit 0
else
echo diff: $(( `date "+%s"` - `stat -c "%Z" /var/run/sleep 2>/dev/null` )) >&2
fi
touch /var/run/sleep
hwclock --systohc
#/bin/rm /var/run/sleep
#killall -9 ssh &
ifdown ath0 &
ifdown eth0 &
# remove USB for external mouse before sleeping
if lsmod | grep '^usbmouse' >/dev/null ; then
/sbin/modprobe -r -s usbmouse &
fi
if lsmod | grep '^usb_storage' >/dev/null ; then
/sbin/modprobe -r -s usb_storage &
fi
if lsmod | grep '^usbhid' >/dev/null ; then
/sbin/modprobe -r -s usbhid &
fi
if lsmod | grep '^uhci_hcd' >/dev/null ; then
/sbin/modprobe -r -s uhci_hcd &
fi
if lsmod | grep '^ehci_hcd' >/dev/null ; then
/sbin/modprobe -r -s ehci_hcd &
fi
/etc/rc.d/init.d/hotplug stop
#log battery charging info
LOG=/var/log/battery.log
date >> $LOG
DATE_BEFORE=`date +%s`
BAT_BEFORE=`grep 'remaining capacity' /proc/acpi/battery/BAT0/state | awk '{print $3}'`
echo "before: $BAT_BEFORE mWh" >> $LOG
#echo -n "standby" > /sys/power/state
echo "putting it sleep" >> $LOG
echo -n mem > /sys/power/state
#echo 3 > /proc/acpi/sleep
DATE_AFTER=`date +%s`
BAT_AFTER=`grep 'remaining capacity' /proc/acpi/battery/BAT0/state | awk '{print $3}'`
echo "after: $BAT_AFTER mWh" >> $LOG
DIFF=`echo "$BAT_BEFORE - $BAT_AFTER" | bc`
SECONDS=`echo "$DATE_AFTER - $DATE_BEFORE" | bc`
echo "diff: $DIFF mWh" >> $LOG
echo "seconds: $SECONDS sec" >> $LOG
#USAGE=`echo "($DIFF * 60 * 60) / ($SECONDS)" | bc`
#echo "result: $USAGE mW" >> $LOG
#REM_TIME=`echo "($BAT_AFTER) / ($USAGE)" | bc`
#echo "remaining time: $REM_TIME hours" >> $LOG
echo "" >> $LOG
/etc/rc.d/init.d/hotplug start &
if !(lsmod | grep '^ehci_hcd') >/dev/null ; then
/sbin/modprobe -s ehci_hcd &
fi
if !(lsmod | grep '^uhci_hcd') >/dev/null ; then
/sbin/modprobe -s uhci_hcd &
fi
if !(lsmod | grep '^usbhid') >/dev/null ; then
/sbin/modprobe -s usbhid &
fi
if !(lsmod | grep '^usb_storage') >/dev/null ; then
/sbin/modprobe -s usb_storage &
fi
if !(lsmod | grep '^usbmouse') >/dev/null ; then
/sbin/modprobe -s usbmouse &
fi
hdparm -B 128 -S 100 /dev/hda &
hwclock --hctosys
/bin/rm /var/run/sleep.lock
:
--------------050700040400030302080504--