# suspend2-sources & 2.6.23

## Xanadu

Hey!

I know I should file a "bug" report (yes, I did search  :Smile:  ), but I thought I'd ask here first rather than bother the Devs.  Is there going to be a 2.6.23 release of 23?  Judging on some of the posts here, 23 seems to not play that nice with things (there was even a bug report of NFS write corruption  :Sad:  ).  I saw a few posts here saying that the nVidia module doesn't seem to like '23, but I honestly didn't read the whole thread so I don't know what the WHOLE issue is since it doesn't apply to me.

I know that I could try the gentoo-sources, but I really rely on the added bonus of suspending / hibernating my laptop.  It's a pretty slow machine (PIII-750) and the flip-the-lid-open-and-wait-only-5-seconds-to-get-back-to-work-thing is something I don't want to lose.  Because it's slow, however, the new scheduler could really benifit me, but I obviously won't know until I try.

Hmmm...  that was a rather long-winded post for something simple like "Is suspend2-sources-2.6.23 in the works?  I just synced and it's still not there."

Thanx all!

----------

## albright

I'd like to see that too (want to try that scheduler that

caused all the fuss  :Smile:   ).

I wonder, is it possible to take gentoo-sources and apply

the suspend2 patches. I don't even know where you'd get

the patches. Maybe if there is someone who has done

this they can file a report.

----------

## Xanadu

 *albright wrote:*   

> I'd like to see that too (want to try that scheduler that
> 
> caused all the fuss   ).
> 
> I wonder, is it possible to take gentoo-sources and apply
> ...

 

LOL! The patches are on your machine!  (or will be!  :Smile:  )

emerge -f suspend2-sources

That'll pull in Linus' sources plus this file:

/var/tmp/distfiles/suspend2-2.2.10-for-2.6.22.patch.bz2

They are your suspend patches.  There's a few other tarballs that come in for the slew of Gentoo patching:

/var/tmp/distfiles/genpatches-2.6.22-6.base.tar.bz2

/var/tmp/distfiles/genpatches-2.6.22-6.extras.tar.bz2

So...  well... there ya go.  That's where you / we get the patches!

Or really they're all here:

http://distfiles.gentoo.org/distfiles/

(or that's where my machine just got them from anyway.  I've told this thing time and time again to pull from ibiblio first so I can reduce traffic that Gentoo has to pay for but that;s where it just pulled from...  :Smile: 

----------

## albright

Sorry if I'm being thick, but aren't those the patches

for the 2.6.22 kernel. Where are the patches for the

2.6.23 kernel?

----------

## Xanadu

 *albright wrote:*   

> Sorry if I'm being thick, but aren't those the patches
> 
> for the 2.6.22 kernel. Where are the patches for the
> 
> 2.6.23 kernel?

 

Well, no, you're not being thick at all.  Indeed they are the '22 patches...

Hmmm... hold on a sec...  I just found this:

http://www.tuxonice.net/

I have no clue if this is the "new" suspend2 or what.  It's in portage, though:

```
$ qsearch onice

sys-apps/tuxonice-userui User Interface for TuxOnIce

sys-kernel/tuxonice-sources TuxOnIce + Gentoo patchset sources
```

You'll have to unmask / ~ARCH:

sys-kernel/tuxonice-sources

sys-apps/tuxonice-userui 

sys-power/hibernate-script

It's 2.6.23 though.

Anyone want to sacrifice their machine to this?  :Smile: 

-----------------------------

EDIT:

Sorry, I got sidetracked with the Tux On Ice thing and didn't complete my original thought.  No you're not being thick.  It was a little bit more of (poor...) humor on my part. :\  I can't imagine the actual patches have changed all that much latley (especially since Linus supposedly froze the API(s)).  But Ican see with something as great as the scheduler change effecting suspending.

-----------------------------

----------

## nubla

 *Xanadu wrote:*   

> I have no clue if this is the "new" suspend2 or what.  It's in portage, though

 

They are. I tried them and they seems to be the same...

 *http://www.tuxonice.net/ wrote:*   

> 2 July 2007: A new name for the project.
> 
> Suspend2 is changing its name. Recent discussions on the kernel mailing list have highlighted the importance of differentiating between suspending to ram and suspending to disk. To help make the difference clearer, Suspend2 is going to change its name to TuxOnIce. The transition will be gradual. Email will continue to use suspend2.net for a little while longer, but the web side of things has been switched over today.

 

----------

## Xanadu

 *nubla wrote:*   

>  *Xanadu wrote:*   I have no clue if this is the "new" suspend2 or what.  It's in portage, though 
> 
> They are. I tried them and they seems to be the same...
> 
>  *http://www.tuxonice.net/ wrote:*   2 July 2007: A new name for the project.
> ...

 

Two things:

Thank you for the info.  I didn't know that.  I guess now I know why there is no '23 in Suspend2...

Second:

WHAT?!?  WOAH!  Am I reading this right?  We won't be able to have BOTH suspend to RAM AND disk available at the same with the same kernel?  I use both.  Suspend to RAM much more often, but still...

I HOPE I'm just reading that wrong...

----------

## nubla

Mhh,

i reverted back to 22-suspend2 because of problems with my sound. At the time i had the 23-tuxonice running i haven't tested if my system suspend with both modes. Never mind, i think they mean maybe labeling inside the code, spelling in general or whatever  :Smile:  Else they would write "splitting" or "parting" instead of "differentiating"...

----------

## Xanadu

 *nubla wrote:*   

> Mhh,
> 
> i reverted back to 22-suspend2 because of problems with my sound. At the time i had the 23-tuxonice running i haven't tested if my system suspend with both modes. Never mind, i think they mean maybe labeling inside the code, spelling in general or whatever  Else they would write "splitting" or "parting" instead of "differentiating"...

 

Ah.  Point made.  I sometimes forget it's the ACTUAL Devs that write a lot of this stuff  :Laughing: 

---

Well, I'll give it a shot on this laptop.  It's plenty old enough that TuxOnIce should love it (it was made in 2000 or REALLY late 1999.  It's a Toshiba Satellite Pro 4600.  This thing LOOOOOOOVES Linux; or Linux love it, I'm not quite sure which is most accurate.  :Smile: 

Thanx again for the help and info, man!

----------

## albright

I had heard of the name change to tuxonice, but idiotically

never thought to look for tuxonice-sources, so thanks for

that  :Smile: 

2.6.23 compiled fine, and suspend works (also suspend to ram or

"standby" works perfectly). 

I notice a new message while hibernation is starting:

"disabling nonboot cpus". This takes a couple of seconds.

I don't think I have any "nonboot cpus" (but I have no idea

what they are really). So I naively hope that this step

can be eliminated. Anybody know what's going on here?

the desktop experience does *seem* a little "snappier" maybe ...

----------

## beatryder

I tried it as well, but some of the modules I needed working don't yet compile against the new kernel, so if you use ipw3945 (iwlwifi works) then don't get too excited about it.

----------

## nubla

 *beatryder wrote:*   

> so if you use ipw3945 (iwlwifi works) then don't get too excited about it

 

Do you mean the sandbox error (i got the same), or another error after you disabling the sandbox feature for ipw3945? Interesting for later upgrading on .23  :Wink: 

 *Xanadu wrote:*   

> It's a Toshiba Satellite Pro 4600. This thing LOOOOOOOVES Linux; or Linux love it

 

Whaat? Toshiba is the biggest enemy of linux  :Laughing:  I have only trouble with my Satellite P100 and their support for linux is horrible.

----------

## beatryder

 *nubla wrote:*   

>  *beatryder wrote:*   so if you use ipw3945 (iwlwifi works) then don't get too excited about it 
> 
> Do you mean the sandbox error (i got the same), or another error after you disabling the sandbox feature for ipw3945? Interesting for later upgrading on .23 
> 
>  *Xanadu wrote:*   It's a Toshiba Satellite Pro 4600. This thing LOOOOOOOVES Linux; or Linux love it 
> ...

 

Well, in general it is considered EXTREMELY BAD to disable the sandbox!!!

I will not do it. There is a reason that the devs advise against it, and why they used to begin with!

The new kernel looks cool and all, but I am gonna see about applying the newest patches to the .22 kernel.

Edit:

If you want the newest tuxonice patches just do this:

```

su -

emerge -f suspend2-sources tuxonice-sources

cd /usr/portage/distfiles

bunzip tuxonice-3.0-rc1-for-2.6.22.10.patch.bz2

bunzip suspend2-2.2.10-for-2.6.22.patch.bz2

cd /usr/src/linux-2.6.22-suspend2-r2

patch -R -p1 < /usr/portage/distfiles/suspend2-2.2.10-for-2.6.22.patch # this removes the old patchset

patch -p1 < /usr/portage/distfiles/kernel-patches/tuxonice-3.0-rc1-for-2.6.22.10.patch

make clean && make && make install modules_install && modules-rebuild -X rebuild

```

----------

## albright

the 2.6.23 tuxonice kernel and the tuxonice features seem

to work very well EXCEPT for two things which I hope

somebody can shed light one.

1. Since using 2.6.23 I have to rmmod snd-intel8x0 and

then modprobe snd-intel8x0 in order for sound to work.

Otherwise the system reports it can't find a sound card

(the modules are definitely being loaded but they have

to for some reason be **re-loaded** for sound to actually

work.). Funny thing is, I get this bad behavior now even

in the older kernels, so I have no idea what is going on.

But on the plus side, the kernel seems definitely "snappier"

and the suspend is faster and very stable.

Right now, I have added

```

rmmod snd-intel8x0 

modprobe snd-intel8x0
```

to /etc/conf.d/localstart, but that does not seem to

be the proper solution ...

2. Sometimes - but not always - when I start KDE, the

alt-F2 key acts exactly like ctrl-alt-F2; that is it takes

me to tty2 (where I see the bootup progress bar from the

bootsplash). When I go back to X and KDE, the run command

dialog is sitting on the desktop. I have even less of an idea

what is going on with this  :Smile: 

Any advice would be greatly appreciated!

----------

## beatryder

Try  adding 

```

UnloadModules snd-intel8x0

GentooModulesAutoload yes

```

and then adding snd-intel8x0 to /etc/modules.autoload.d/kernel-2.6 if you have not already.

or you can use the OnSuspend and OnResume functions.

I actually have done this:

```

lsmod | awk '{print $1}' > /etc/modules.autoload.d/kernel-2.6

```

Make sure to edit the file and remove the first line "'Module" unless errors about modules not loading doesn't bother you.

that way all the modules you have loaded will be in the autoload and reloaded by the hibernat script.

----------

## Xanadu

 *nubla wrote:*   

> Whaat? Toshiba is the biggest enemy of linux  I have only trouble with my Satellite P100 and their support for linux is horrible.

 

 :Laughing: 

Well, I wasn't commenting on the COMPANY Toshiba.  The MACHINE loves Linux even if if it's makers feel different. 

 :Very Happy: 

(besides this is an older machine.  The SatellitePro 4600 was made in REALLY late 1999 or early 2000 since it shipped with a choice of 98_se or w2k.  So it was right around that time somewhere when w2k was OUT, but not widely used/accepted yet.

----------

## Xanadu

 *beatryder wrote:*   

> 
> 
> ```
> 
> lsmod | awk '{print $1}' > /etc/modules.autoload.d/kernel-2.6
> ...

 

or just to keep it to one command / line:

```
lsmod | awk '{print $1}' | grep -v Module
```

I know we all know what you meant but just in case a person newer to *NIX didn't know that, I thought I'd point it out.

----------

## beatryder

 *Xanadu wrote:*   

>  *beatryder wrote:*   
> 
> ```
> 
> lsmod | awk '{print $1}' > /etc/modules.autoload.d/kernel-2.6
> ...

 

I am not offended, I just forgot how to do that, (it's early where I am) :p

----------

## albright

 *Quote:*   

> Try adding 
> 
> ```
> 
>  UnloadModules snd-intel8x0 
> ...

 

I'm sorry - I was very unclear. I have no trouble with sound

after waking up from hibernation. My problem is with a total

reboot ... The modules load but the system does not seem to

recognize them  :Sad: 

----------

## beatryder

are you using the alsa-driver package?

----------

## albright

I'm using the kernel drivers; everything was working

normally until yesterday (at least that's when I started

my computer and had no sound - and then figured out

that unloading/reloading snd-intel8x0 fixed it).

I had just started using 2.6.23-tuxonice kernel, but

like I said, the sound problem exists even if I boot

into an old (2.6.22-r2-suspend2) kernel.

Since the simple re-loading trick works, I don't think

there is a serious problem here; just some obscure

configuration issue maybe ...

----------

## Xanadu

Well, I'm running 2.6.23-tuxonice now.

I agree, it does make the system feel a bit snappier.  HOWEVER, I can't 100% say it's because of the new kernel.  Last Night when I (finally) did the recent PAM update, I noticed all my Gentoo systems seemed snappier.  Perhaps it was just my imagination since I can't see any reason that pam would slow things down, but whatever.

Problems with 2.6.23-tuxonice:

My IR chip module doesn't load (again...) at boot anymore.  The past few kernels would auto-reconfigure the settgings right after kernel init (and before the system even starts booting - there was a message on the console about that).  Now it's not doing it.  I don't know if there's a kernel option that changed it's name (AGAIN...) becuiase I thought there was at one point and that's when it started re-configuring the chip and now it's not selected in my .config.  It's not a big deal since I don't really have any use for it anyway.  I'll have to look into it, though.

The KDE ALT+F2 thing.  Yep, I'm getting that now also.  It seems (MAYBE) to be a problem with the fbsplash not getting notified properly (or completely) and when you hit ALT+F2 my console splash comes up.  Still, it wouldn't explain why the system thinks I was holding down CTL and especially since KDE knows I wasn't (since the run dialog does indeed come up I just have to switch back to X to use it).  This part really blows since I use the Run dialog for near 95% of the things I start on my machine)

P.S.

My sound works fine.  I have alsasound start at boot.  I have a little sound in my net.eth1 play when my Wireless PCMCIA card comes up and it does indeed play the sound.

----------

## Xanadu

OK, found out what's causing the KDE ALT+F2 thing.

It is indeed the boot splash thing hung up.

GO out to a TTY and type 

chvt 16

You'll see your splash screen (mine was stuck at 78% done booting).  I then did:

```
ps -e | grep tty16

 1573 tty16    00:00:06 fbsplashd.stati

 1595 tty16    00:00:00 sh <defunct>

 1813 tty16    00:00:00 sh <defunct>

 1816 tty16    00:00:00 sh <defunct>

13322 tty16    00:00:00 sh <defunct>

14681 tty16    00:00:00 sh <defunct>

14806 tty16    00:00:00 sh <defunct>

15049 tty16    00:00:00 sh <defunct>

16576 tty16    00:00:00 sh <defunct>

16608 tty16    00:00:00 sh <defunct>
```

OK.  Well, splash has been doing that for a while now.  I stopped using a pretty splash for suspending because of it and use xosd for the "suspend meter" thing.  But it USED TO BE only when coming out of suspend. https://bugs.gentoo.org/show_bug.cgi?id=172318  (It's marked resolved even though, AFAICT, it's not.  Actually, it seems to have gotten worse now.

Anyway, kill -HUP the fbsplashd.stati PID and the splashscreen with die with it.  Don't worry your console backgrounds are still there and you'll still get your pretty splash screen when rebooting (or whatever) next time you go to use it.  After this, KDE's ALT+F2 will not send you to the console, it'll ONLY bring up the Run dialog as it's supposed to.

Hope that helps someone out there!

----------

## albright

Here's another small problem with the 2.6.23 kernel.

There used to be a initrd system that used a ram

disk to help display the splash screen really

quickly (or something like that). This does not

seem to work in 2.6.23. There is about 5 seconds

at boot up during which I can see Tux in the

upper left corner of the screen and watch a few

boot messages AND THEN the bootsplash image

appears and the rest of the boot proceeds

normally.

I have no idea what's going on with this ...

----------

## Xanadu

 *albright wrote:*   

> Here's another small problem with the 2.6.23 kernel.
> 
> There used to be a initrd system that used a ram
> 
> disk to help display the splash screen really
> ...

 

Here's the "script" I've been using for 2 or so years for building my ernels on several machines.  It's really not that big of a deal.  The long line towards the end is the big deal part that makes the splash screen come up with the kernel so you never see text at all:

```
#!/bin/sh

cd /usr/src/linux

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

echo  Make Modules

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

make modules

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

echo  Install Modules

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

make modules_install

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

echo  First bzImage

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

make bzImage

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

echo  Splash and Real bzImage

echo ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

#rm -f /usr/src/linux/.version

splash_geninitramfs -g /usr/src/linux/usr/initramfs_data.cpio.gz -r 1024x768 default

make bzImage install
```

----------

## albright

Well ... I'd rather not compile the initramfs into the kernel but

load it dynamically (like the howto recommends). But maybe

that's the problem? Do you have to compile it into the kernel

with 2.6.23?

----------

## Xanadu

 *albright wrote:*   

> Well ... I'd rather not compile the initramfs into the kernel but
> 
> load it dynamically (like the howto recommends). But maybe
> 
> that's the problem? Do you have to compile it into the kernel
> ...

 

I'll be 100% honest and say that I have no clue.  That's just the way I've been doing it since the early 2.6.* kernels (I wasn't using splash screens back when I was using 2.4.*, or 2.2.* so I have no experience there).  The HOWTO in /usr/share/doc/splashutils-1.5.2.1/early_bootup.bz2 (that may not be the version you have installed but you get my point) says to do it that way.  

Here's exactly what it says:

 */usr/share/doc/splashutils-1.5.2.1/early_bootup.bz2 wrote:*   

> If you're making your own initramfs images, you already know what to do. If
> 
> you aren't, splashutils comes with a script that will make your life a little
> 
> easier. The script is called splash_geninitramfs. It has options to
> ...

 

I doubt is HAS to be done that way.  Also, I don't use that initrd= line in my lilo.conf since the initrd is built right into the kernel it just auto-magicly works.  The above line has worked for me with every kernel I've been compiling the past couple years (including '23), so I'll just keep doing it until it stops working then I'll figure out how to make it work again, ya know?  :Smile: 

----------

