Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
HOWTO: upgrade a7n8x/nforce2 to mm-kernel-sources 2.6.5
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
stillman
Apprentice
Apprentice


Joined: 07 Dec 2002
Posts: 223
Location: Vienna, Austria

PostPosted: Wed Apr 07, 2004 2:44 pm    Post subject: HOWTO: upgrade a7n8x/nforce2 to mm-kernel-sources 2.6.5 Reply with quote

HOWTO: upgrade a7n8x/nforce2 to mm-kernel-sources
2.6.5


two days ago i've decided to touch my running system and upgrade from 2.4.20-gentoo-r8 to 2.6.5-mm. my mobo is a a7n8x rev1.04(not deluxe!) because it took me a whole night till everything worked and i have studied many threads in this forum i want to collect the information i've gathered here. i'll cover only the issues were i had trouble since everything else worked the same as in my old kernel, even /devfs ans /proc can be found in
Code:
File systems --->
  Pseudo Filesystems --->

these are also covered in the installation manual - kernel configuration.

since i wanted to start from scratch i did
Code:
emerge -C nforce-net
emerge -C nforce-audio
emerge -C nvidia-glx
emerge -C nvidia-kernel


now
Code:
emerge mm-sources

before we configure the kernel we have to remove two patches from the mm-kernel-sources because they have a fixed setting to use 4Kb for kernel stacks instead of 8Kb(Whatever that means) which causes problems with nvidia-graphic-cards:
Go to http://kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.5/2.6.5-mm1/broken-out/ and grab these patches to undo the fixation:
Code:
move-__this_module-to-modpost.patch
4k-stacks-always-on.patch


then you go to /usr/src/linux(make sure that you've already linked 'linux' with the new kernel sourcetree), copy the two patches there and reverse the patches by doing:
Code:
patch -R -p1 < 4k-stacks-always-on.patch
patch -R -p1 < move-__this_module-to-modpost.patch


now we're set to
Code:
make menuconfig


i went through every feature in the menu step-by-step and looked if it matches my needs. most of the menu options are the same as in the 2.4.20 kernel tree, but APIC can be used without a hassle, no more waiting when you turn of the workstation ;-)
problems occured with the nvidia nforce2 chipset and the nvidia-driver for graphic-cards(as described above).


nforce-net


nvidia has not yet produced an working nforce-net driver for the 2.6 kernel-series(check the protest thread), 'emerge nforce-net' interrupts with errors. some gentle individuals have reverse engineered the nvidia driver and there is a option in
Code:
Device Drivers --->
  Networking Support --->
    Ethernet (10 or 100MBit) --->
      <M> Reverse Engineered nForce Ethernet Support (EXPERIMENTAL)


you should build as a Module called forcedeth.


nforce-audio


while the nforce-audio driver was doing a great job in the 2.4.20 kernel it can't be compiled with the new kernel - you'll have to look for alternatives, fortunately ALSA has advanced and is now part of the kernel.
be sure to activate
Code:
Device Drivers --->
 Sound --->
  <*>Sound Card Support --->
    Advanced Linux Sound Architecture --->
     <M> Advanced Linux Sound Architecture
     <M> Advanced Linux Sound Architecture
     <M> Sequencer support
     <M>   Sequencer dummy client
     <M> OSS Mixer API
     <M> OSS PCM (digital audio) API
         PCI devices --->
    <M> Intel i8x0/MX440, SiS 7012; Ali 5455; NForce Audio; AMD768/8111
   



nvidia-graphic-card


since we've already unpatched the stack-size-option we can do the following now:
Code:
Kernel Hacking --->
   [ ] Use 4Kb for kernel stacks instead of 8Kb

make sure that this option is deactivated!
additionally check your other options in
Code:

Device drivers --->
  Character Devices --->

for my ti4200 i only have to build agpart as module to make AGP Features and 3-D-Rendering work.


compiling kernel and loading modules


after we have completed the configuration we exit and save. now we do
Code:

make dep; make clean; make bzImage; make modules
rm -rf /lib/modules/*
make modules_install
mount /boot
cp /usr/src/linux/arch/i386/boot/bzImage /boot/bzImage
umount /boot
rm /etc/modules.d/nvidia
rm /etc/modules.d/nvnet
update-modules

NOTE: consider backing up your old kernel-bzImage in /boot

after that we edit /etc/modules.autoload and comment out agpart, nvidia and nvnet
Code:
echo alias eth0 forcedeth > /etc/modules.d/nforce2
update-modules
reboot

NOTE: if you don't have a second network card you should 'emerge -f nforce-net' (the -f FLAG fetches the packages for nforce-net without compiling) before you reboot so you can compile it and have a working network-device later

when the kernel has booted without probs do
Code:
emerge nforce-net
modprobe forcedeth

after that it should be possible to start
Code:
/etc/init.d/net.eth0


now
Code:
ACCEPT_KEYWORDS="~x86" emerge nvidia-glx

to compile the nvidia-driver. i guess you can also emerge the stable nvidia drivers but i've done it with the newest and had no probs yet.
uncomment agpart and nvidia in /etc/modules.autoload and
Code:
update-modules
opengl-update nvidia


X should work now.

to configure your sound device i refer to the alsa-guide - just follow the steps after 'Configuration of ALSA', the nforce-snd-card is called snd-intel8x0
i had problems with xmms finding the snd-device so i reemerged xmms and choose the 'ALSA 1.2.10 output plugin' under 'preferences'(i only had two plugins before i reemerged and neither worked). unfortunately the sound seems a bit poor and "flat", the original nvidia-audio driver was definitely better, hope nvidia releases a native audio driver soon... :?

i hope i've recognized everything correctly - not sure about that :wink: - and people with this widely spread mobo can upgrade faster to the new kernel...
if something is unclear or to complicated don't hesitate to ask...

Main Sources:
https://forums.gentoo.org/viewtopic.php?t=146879
https://forums.gentoo.org/viewtopic.php?t=156523
http://www.gentoo.org/doc/en/alsa-guide.xml#doc_chap2
https://forums.gentoo.org/viewtopic.php?t=31096&start=0&postdays=0&postorder=asc&highlight=4200+agpart&sid=8619977c867a2017a36c9dee933993dd


Last edited by stillman on Wed Apr 07, 2004 4:25 pm; edited 6 times in total
Back to top
View user's profile Send private message
krdp
n00b
n00b


Joined: 27 Feb 2004
Posts: 41
Location: Newfoundland, Canada

PostPosted: Wed Apr 07, 2004 2:57 pm    Post subject: Reply with quote

Nice doc. I was also thinking of doing something like this but not really specifect to the mm-kernel-sources, just some info and known problems with some nforce2 mobos. I also have the A7N8X mobo but mine is the 2.0ver. Also some nforce2 mobos have troubles with APIC causeing the whole system to lockup. I just added the following options to my kernel line in grub.conf acpi=off nolapic noapic and now my system is stable.
Back to top
View user's profile Send private message
stillman
Apprentice
Apprentice


Joined: 07 Dec 2002
Posts: 223
Location: Vienna, Austria

PostPosted: Wed Apr 07, 2004 3:08 pm    Post subject: Reply with quote

thanks for your reply.
i've read about those lockup probs but had none so far, even when i don't use the desktop for some hours, dunno if it even goes to sleep automatically(guess not) - however, i don't need anything except power off after halt...
Back to top
View user's profile Send private message
Guest






PostPosted: Sat Apr 10, 2004 5:11 pm    Post subject: Reply with quote

When trying to apply the first patch (4k patch) I get a message:

Code:
Unreversed patch detected!  Ignore -R? [n]


Am I supposed to ignore the -R, and if so, why include it in the first place? Thanks.

Hi - <added>

I simply ignored and applied, and it worked great. Thanks for the research here and great post.
Back to top
servo888
Apprentice
Apprentice


Joined: 22 Feb 2004
Posts: 293

PostPosted: Tue Apr 13, 2004 6:28 pm    Post subject: Reply with quote

I'm having this problem:

bash-2.05b# patch -R -p1 < 4k-stacks-always-on.patch
patching file arch/i386/Kconfig
Hunk #1 FAILED at 1496.
1 out of 1 hunk FAILED -- saving rejects to file arch/i386/Kconfig.rej

Hmm this is really strange. I'm running the patch in the 2.6.5 base.
Back to top
View user's profile Send private message
stillman
Apprentice
Apprentice


Joined: 07 Dec 2002
Posts: 223
Location: Vienna, Austria

PostPosted: Tue Apr 13, 2004 8:41 pm    Post subject: Reply with quote

hmm, maybe the patch failed to download correctly? try it with a fresh download...
Back to top
View user's profile Send private message
stephenv
n00b
n00b


Joined: 04 Nov 2003
Posts: 4
Location: Thornton, CO

PostPosted: Tue Apr 13, 2004 11:28 pm    Post subject: HOWTO: upgrade a7n8x/nforce2 to mm-kernel-sources Reply with quote

I'm quite certain the patches have already been removed if you are using the latest mm-sources. I base this on the fact that if you look inside the patches and then check them against whats in the files from mm-sources you'll find the patches already appear to be removed. I'm pretty sure you'll want to skip the patching step..
Back to top
View user's profile Send private message
provicemo
Apprentice
Apprentice


Joined: 12 Dec 2003
Posts: 201
Location: Detroit, MI

PostPosted: Wed Apr 14, 2004 3:21 am    Post subject: Reply with quote

I using 2.6.5-mm1 with no patching, with no problems so far, so i dont think the patches are nessesary
Back to top
View user's profile Send private message
Guest






PostPosted: Sat Apr 17, 2004 12:30 am    Post subject: Reply with quote

Yes, all the patches had become obsolete almost as soon as the threads had gone up it seems. Plain ~x86 mm-sources and ~x86 nvidia kernel, without any fiddling did the trick. I drove myself nutz a whole day with pre-setup planning and getting all my ducks in line only to find out the hard way, by the end of the day, that all of that was uneccessary as of, who know, that very morning. A first for me, frustrating as hell, but I guess sometimes it helps not to prepare!
Back to top
mroch
n00b
n00b


Joined: 08 Dec 2003
Posts: 74

PostPosted: Sat Jul 03, 2004 6:27 pm    Post subject: Reply with quote

NVidia just released drivers that support 4K stacks. It shouldn't be necessary to remove those patches from the kernel once nvidia-*-1.0.6106 become stable.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum