LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   compiled my first kernel last night, yay. didn't fix suspend to ram (https://www.linuxquestions.org/questions/slackware-14/compiled-my-first-kernel-last-night-yay-didnt-fix-suspend-to-ram-916968/)

Knightron 12-03-2011 06:53 PM

compiled my first kernel last night, yay. didn't fix suspend to ram
 
Hi guys, running a fairly new laptop, i've found i usually have to upgrade the kernel to 2.6.39 or later to get everything to work right. Suspend to ram normally works right after this adjustment. In Slackware 13.37, suspend to ram does not work, so last night i compiled the 2.6.39.4 kernel using AlienBobs guide, (Thanks Eric) and it ran successfully. Suspend to ram still does not work though. Obviously there is a setting i have neglected to change in the make config; Does anyone have an idea of what setting i'd need to change.

Alien Bob 12-04-2011 06:26 AM

Couple of questions come to mind:
* why is a newer kernel always needed for you?
* you seem to run more distros; do these other distros have similar issues?
* exactly how do you initiate the suspend to RAM?

I have several laptops which have been running several versions of Slackware, and I have never had any issues with suspending to RAM or to disk.

Eric

Knightron 12-04-2011 08:34 PM

Hello Eric, and thanks again for the guide. My laptop is quite modern. I am still quite new to gnu/linux, and learning. I may be wrong about having to upgrade the kernel, but I found it solved the issue in debian by backporting, and was just basing my question on that past experience. I'd be even happier if I can configure slackwares default kernel to work the way I want. I usually suspend to ram by closing the lid but I am un able to initiate it either by going to the k menu and telling it to suspend. As a side note I was just thinking, that it may be a xorg configuration issue because I also backported xorg on debian, and maybe my issue is to do with xorg

Alien Bob 12-05-2011 08:57 AM

Please do your tests with a default Slackware configuration without Debian pollution... I am interested to hear if that makes it work.

Eric

Knightron 12-05-2011 02:06 PM

Debian pollution? Obviously you really enjoy slackware, but do you dislike debian? Where would I start to 'test' slackwares default kernel? What would u sujest I configure?

Alien Bob 12-05-2011 03:04 PM

No, I do not dislike Debian at all. I am sorry if you read my comment that way.
The phrase "pollution" is a reference to the changes you made to Slackware's original (or rather, absense of a) xorg.conf script. Take away those additions, if you wish, and see if a clean Slackware configuration makes a difference.

Eric

Knightron 12-05-2011 05:28 PM

Ok, I think you have misunderstood me. I didn't take debians xorg.conf and place it in slackware. The only change besides a few packages, I've made is upgrading the kernel. What I meant was that I had similar issues in debian to what I am having with slackware, and that upgrading the kernel and xorg fixed my issues in debian. I thought that this info might help those that are more knowledgeable in configuring Linux, to help me with my problem.

STDOUBT 12-06-2011 09:12 AM

Hi Knightron,

I am curious if you have tried suspending under another DE such as XFCE. If you did a Full installation you should be able to run XFCE and try it. You can run xwmconfig after login and select XFCE assuming you use startx after login and not go straight to X upon booting up.

There is certainly a setting (someplace) in KDE which sets the action for closing the laptop lid. In XFCE Settings Manager it defaults to Lock Screen. Please try Suspend from the GUI logout icon in XFCE and see what happens (on stock Slack kernel).
Also, if Suspend doesn't work for you under KDE, what exactly does happen when you just close the lid?

slac-in-the-box 12-06-2011 10:16 AM

I got suspend to ram sort of working here. When it is plugged in to AC, shutting the lid suspends as desired, and opening the lid resumes... however, I still have issues when trying resume/suspend on battery...

AuroraZero 12-06-2011 05:36 PM

Just out of curiosity Knightron open a command prompt and post a dmesg would you? I am wondering if he is having the same problem I was or not.

Knightron 12-06-2011 09:09 PM

Hi guys, thanks for your concern. I'm not in my Slack partition at the moment so i can't test that command out; i was shortly ago though and i tested this command as root
Quote:

echo mem > /sys/power/state
and this command did execute suspend. I closed the lid and opened the laptop back up and it resumed perfectly. So suspend to ram works, but closing the lid and telling the computer from the kmenu does not work.
STDOUBT, no i haven't tried in one of the other desktop environments. Later i'll try that, and the demesg command

bonixavier 12-07-2011 04:59 AM

Have you tried adding the lines in red to /etc/acpi/acpi_handler.sh? It will make the laptop suspend regardless of the DE/WM chosen whenever the lid is closed.
Code:

#!/bin/sh
# Default acpi script that takes an entry for all actions

IFS=${IFS}/
set $@

case "$1" in
  button)
    case "$2" in
      power) /sbin/init 0
        ;;
      lid) /usr/sbin/pm-suspend
        ;;

      *) logger "ACPI action $2 is not defined"
        ;;
    esac
    ;;
  *)
    logger "ACPI group $1 / action $2 is not defined"
    ;;
esac


ymerlin 12-07-2011 10:41 AM

If you use KDE and find your laptop does not standby when the lid is closed, one reason is KDE's default power profiles. Please find "System settings -> Power management -> Power profiles", select your profile. Check "Button events handling" and change "When laptop lid closed" from "Do nothing" to "Sleep". Hope it does work for you.

Knightron 12-07-2011 05:43 PM

Thankyou bonixavier, that solved the issue. The option in the kmenu still doesn't work but that doesn't matter because i never use that anyways. Thanks guys

BCarey 12-10-2011 04:45 PM

Did it work on the stock Slackware kernel, or only on the upgraded one?

Brian


All times are GMT -5. The time now is 05:07 AM.