State of the mm20 in Linux (Debian tested) as of December 2006:
- Xorg: works, DRI on, AGP
- Wireless: works perfectly (b and g), even with WPA
- Synaptics Touchpad: Works, specialty driver
- Longrun: installed, works with some effort
- acpi: working
- Suspend: sleeps, but doesn't recover to a useable state
- Hibernation: Working, fairly easy setup
- Framebuffer: working at 1024x768 with a bootsplash
News
News (08 May 07): A few months ago both my server and laptop hard drives crashed. Because of this I no longer have any of the old conf files for the laptop. I also cannot test with my mm20, since I've been having issues with Sharp's extended warranty people. I've done some minor updates that needed adding.
News (26 Sept 05): I've switched to Debian. And so I'm updating this page to reflect the state of my machine before my switch. I will put up a page reflecting using Debian on the mm20 in the near future. Please also note that some of the install steps may not be accurate (as Gentoo has changed in some areas), but most of this page should be independant of that. Sound is working in the newer kernels too.
News (11 Mar 05): Updated, much information. Prism54 is updated and has a new method in Gentoo. Sound is still unworking in 2.6.11 so far, but I've got some things to try yet. Important changes in the X configuration if running 2.6.11, no not enable DRI!
News (17 Nov): Submitted the prism54 ebuild to Gentoo's bugzilla. See my blog post on the topic.
News (12 Nov): I've done a bit of hacking at my prism54 ebuild. Since 1.2 is included in the the kernel as of 2.6.8, it's a tad redundant to rebuild for those cases. This new ebuild will check your kernel version and build the driver only if necessary. Very cool stuff. If you're running a new enough kernel, it will only install the firmware. I hope this is usefull, I'm going to submit it to portage in a little while, so feedback would be appreciated. Take note that the version number makes it older than the current ebuild, so you have to specify the version by hand.
Introduction
I recently got a Sharp mm20, and have since installed gentoo on it. Here are my tips and tricks. A lot of information comes from David C.'s howto for the mm20. His howto is an invaluble read, and without it I probably wouldn't have half this stuff working.
You'll probably notice that the laptop gets very warm while compiling, and ACPI will tell you the processor is at 70-some-odd degrees C. Don't worry, you're still within opperating tempuratures of an efficeon processor, it's max is 100 C. Previously I mentioned how compiling takes a longer time than on my AMD Athlon 1 GHz, but it turns out all that was due to the lack of DMA on my hard drive (see above).
A note from a fellow mm20 user: Dock the mm20 in the cradle, mount the drive, and chroot into it. Then compile and take advantage of the faster processor. Of course my desktop's processor is the same speed as the mm20.
Follow the Gentoo Handbook installation instructions. There's a reason they're there.
Also note that I installed Fedora Core 2 first following the above mentioned howto. I got a lot of help from this, along with most of my xorg.conf
Gentoo Handbook Items
Initial Live CD
I just hit enter and watched the pretty framebuffer bootsplash load up. No hang ups.
Stages
Updated 9/4/04
I did a stage 1 install. Bootstrapping took more than 3 hours. I went to
be first. In stage 2 (emerge system) I was a little smarter and
started in the morning after bootstrapping and left for school/work after that.
I have no idea when this finished, but 10 hours later it was done. You can view
my USE flags if you want to see how that affected this
portion.
Compiler flags: These are my current flags. I've experienced no problems with them.
CFLAGS="-O1 -mcpu=pentium4 -msse2 -mfpmath=sse -pipe -fomit-frame-pointer"Please take note that I have tried to compile with
-O2, but
compiling failed with this set on perl and freetype. (Both with compiler errors
that stopped happening when I set my CFLAGS to -O1)
Kernel
Updated: 3/11/05
I'm runing the 2.6.11 kernel, it's a vanilla kernel
(development-sources in Gentoo). There's a number of patches that
I have applied to the kernel. First is the swsusp2 (software suspend
2), more information can be found at Nathan's howto.
One this to take note of is if you're seeing "spurious 8259A interrupt: IRQ7", you'll need to change some settings, otherwise you may experience hardware lockups. (information to return in near future)
I've also been informed that if you want to get the pcmcia modem to work you'll need to compile ppp and the serial_cs driver. (kudos to Jason for letting me know)
udev
udev was a fairly easy install. I kept devfs support in the kernel, just in
case. It looks like I may remove it come next time. The main thing that gentoo
users must do is emerge udev before rebooting. Also in your
grub.conf you need on the kernel line to add devfs=nomount to have
sysfs mount instead. With that you've got udev all set and ready to go
Grub
My grub.conf looks something like this: (this doesn't reflect swsusp2)
default 0 timeout 10 splashimage=(hd0,0)/grub/splash.xpm.gz title=Gentoo Linx 2.6.6-7.1.04 root (hd0,0) kernel /kernel-2.6.6-7.1.04 root=/dev/hda3 video=vesafb:ywrap,mtrr vga=0x317 i8042.nomux devfs=nomount splash=silent initrd=/boot/initrd-gentoo-1024x768Please note that the statement
i8042.nomux is required.
Without this your touchpad will not work. A fellow mm20 owner
was having trouble with his touchpad (didn't show up at all), and it turned out
he didn't have this enabled. So if your touchpad is not working with the 2.6
kernel, be sure to enable i8042.nomux on the kernel line in grub
(or lilo). See David C.'s howto.
i8042.nomux is not needed in recent kernels.
Final Gentoo Handbook Steps
Ensure that you remember to make a net.eth1 symlink in
/etc/init.d and in my case while the livecd had the ethernet as
eth1, it became eth0 in my own system. Otherwise you should be ready for
reboot
Post Install
Xorg
Updated 9/26/05
Xorg is now stable in gentoo, so just emerge xorg-x11, and
you're good to go. Update: the xterm bug (not working outside
of root) is related to the ssh bug, the permissions on /dev/tty
please see that section on how to fix it. More of an Update:
The xterm bug should no longer occur.
Note: the special ati-radeon drivers (fglrx) will not work . You should use the radeon driver.
If you're running the 2.6.11 (up to 2.6.19), X will not start without disabling DRI. My xorg.conf reflects this situation. Though if you disable AGP you can have DRI running again, though I have not tested this (Thanks to David C. on this tip, his page should reflect this information).
Wireless
Gentoo has a new system for providing the prism54 driver. If you're running
a fairly recent kernel, it has the most recent driver, and all you need is the
firmware. Simply emerge prism54-firmware and you're ready to go.
If you run an older kernel you'll need to set ~x86 for the net-wireless/prism54
ebuild and then emerge prism54 (which should get the firmware).
Now simply just modprobe that sucker in, and you've got running wireless.
Longrun
First of all ensure that your kernel has:
CONFIG_X86_MSR=(y|m) CONFIG_X86_CPUID=(y|m)Ensure they load at boot. With these in place you're ready to use longrun. The first step is to ensure you have
/dev/cpu/0/ in this directory
should be the devices cpuid and msr.
If they are missing you will need to manualy create them. Run
these commands to make the nodes:
mkdir -p /dev/cpu/0
mknod -m 444 /dev/cpu/0/msr c 202 0
mknod -m 444 /dev/cpu/0/cpuid c 203 0
You'll only need to create them once if you're using the Gentoo udev tarball.
It'll save them for future use.
Longrun has finally been updated in portage! Feel free to emerge longrun and you should have a working version. longrun -h should help out in use.
ACPI
ACPI works very well on the mm20. To take advantage I went a slightly
different route, as described in this
howto. To take advantage of longrun whenever you're running on
battery add this script: (pm.cpu)
#!/sbin/runscript
start () {
ebegin "Activating Lonrun"
longrun -s 0 36 -f economy
eend $?
}
stop () {
ebegin "Deactivating Longrun"
longrun -s 0 100 -f performance
eend $?
}
Put this in /etc/init.d/ make sure it's executible (chomd +x
/etc/init.d/pm.cpu) and then add it to the battery runlevel
rc-update -a pm.cpu battery. Now whenever you take out the
ac-adapter longrun will start.
As for sleeping, I have yet to get even close to having it work as well as
David C.
does. Currently passing echo -n "mem" > /sys/power/state will
put the laptop to sleep, with a nice apple-ish flashing power light. To come
out of sleep I press the power button, and it starts to do stuff. With no
screen, and the hardware buttons no longer work (wireless, screen brightness,
etc). If done from the console, restarting X will give you X working, but no
console, and if you do a reboot, you won't see the boot at all. Only a hard
reboot wil bring things back to their proper state. So I'm just going to go
without for now.
I sent an email off to the Emperor
Linux guys, and asked how they get the mm20 to sleep. They were nice enough
to respond that they use the swsusp2 patch to the kernel. I'm going to try this
during summer break and I'll put up a good howto for this.
Nathan, a fellow mm20 owner, got swsusp2 working on his machine. Check out
his howto. I followed those steps
and have the laptop hibernating like a charm.
Framebuffer
Framebuffer is working great, you just need to follow the steps provided on
this Gentoo Forum
howto, and for your vga settings, use the same as mine, found in the grub
section. (16M colors doesn't work in fb). Works like a charm.
tty permission problems
These have been resolved in Gentoo. Mainly because they're doing the permission edit for you.
Synaptics Touchpad
ACCEPT_KEYWORDS="~x86" emerge synaptics will give you the
driver, and then you should just need to edit your xorg.conf file. For
information on what settings do, read about it in the synaptics directory of
/usr/share/docs/. Also once you have the driver as your mouse
driver in xorg.conf, you'll need to have it be it's own device, and set up
/dev/input/mice as a second input device for an external usb
mouse. Please note that before starting X if you use my xorg.conf, ensure that
the synaptics driver is installed.
For finding values you enjoy, try the synclient utility to edit
settings on the fly, till you get what you want.
Don't forget to add i8042.nomux to your grub kernel line! Else you won't have a working touchpad! (not needed on newer kernels)
Thanks and links
I owe my current state of affairs to many people and their help, David C.'s
howto, and my correspondance with him have helped greatly. The Gentoo Handbook,
especially with xorg and udev. The Gentoo Forums in general are a great
blessing of information. My thanks also to the Fedora project as I used many of their
settings to assist in this process, the mm20 is supported wonderfully under
FC2, I recommend it to those who don't want to wait for 3 days to use their
mm20. My thanks to these people and all the help that they have provided. I
also thank the BYU-UUG, PLUG, and various individuals who have helped me
reach where I am today in my understanding of linux
I'd also like to add thanks to the many people who have contacted me in
result of this page, I'm glad to know that It's helpful. Don't hesitate to ask
me questions, I'm glad to help out, and as often as not learn a thing or
two.

