Apr 252011
 

I recently purchased an HP Pavilion dm1z laptop after reading how many people were thrilled with the small laptop. It’s been described as a netbook-killer, and I tend to agree with that sentiment. The dm1z is light, power-efficient, quick and runs Linux well. However, there were a few tweaks I needed to put in place to get 32-bit Ubuntu 10.10 running perfectly.

This post was last updated 2011-09-07

Other members in the Linux and Ubuntu communities had already taken care of the hard bits. But I did spend a bit of time comparing information from different message boards and solutions, particularly when it came to fixing the wifi. A helpful, thorough post is available on ubuntuforums.

WIFI

Once you have the correct driver, the wifi on HP’s dm1z works flawlessly. The built-in wireless enable/disable button and LED also work without any tweaking.

It has been reported that wifi works out-of-the-box with the latest Ubuntu 11.10.

However, Ubuntu 10.10 and 11.04 do not have native support and the stock driver from the manufacturer is buggy and spews too much to dmesg. The packages built for openSUSE work properly. At the time of writing, the working wifi driver was from openSUSE 11.3 or 11.4:

https://build.opensuse.org/package/binaries?package=rt5390sta&project=driver%3Awireless&repository=11.4-update

You’ll see 64-bit (x86_64) and 32-bit (i586) packages listed. Download the openSUSE driver package – the source RPM, not the binary package: rt5390sta-2.5.0.3-1.2.src.rpm

Open your web browser’s download directory and double-click the src RPM. Extract all files into a new directory named openSUSE_rt5390sta_driver

Open a terminal and sudo to root:

sudo su -
cd openSUSE_rt5390sta_driver
apt-get install xz-utils
tar Jxvf 2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO.tar.xz
cd 2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO/
patch -p0 < ../rt5390sta-2.5.0.3-config.patch
patch -p0 < ../rt5390sta-2.5.0.3-WPA-mixed.patch
patch -p0 < ../rt5390sta-2.5.0.3-convert-devicename-to-wlanX.patch
patch -p0 < ../rt5390sta-2.5.0.3-remove-potential-conflicts-with-rt2860sta.patch 
patch -p0 < ../rt5390sta-2.5.0.3-return_nonvoid_function.patch
patch -p0 < ../rt5390sta-2.5.0.3-reduce_debug_output.patch
mv RT2860STA.dat RT5390STA.dat
make
mkdir -p /etc/Wireless/RT5390STA
cp  RT5390STA.dat /etc/Wireless/RT5390STA/
cp -i os/linux/rt5390sta.ko /lib/modules/`uname -r`/kernel/drivers/net/wireless/
echo rt5390sta >> /etc/modules
echo "blacklist rt2800pci" >> /etc/modprobe.d/blacklist.conf
depmod -a

Reboot your dm1z and the wifi should come up properly on boot.

Touchpad (Clickpad)

I’m not a big fan of click pads, but it worked OK out of the box. There was no multi-touch support and I had a tendency to hit the pad with my wrist while typing. After a few tweaks and a bit of use, I’m very happy with it.

Adding multi-touch support was easy, as described here, and made me much more productive.

I mitigated the accidental wrist swipes by adding a large ‘Pointer Capture’ widget to the top panel. Move the cursor there and click to lock the mouse. Click again to free the mouse. You can change the size of the mouse lock widget by right clicking and changing the widget preferences. It’s a pity the built-in hardware mouse lock doesn’t work, but we can always hope for future support!

DM1Z Poweroff Issue – Draining Battery

An issue has been discovered which causes the battery to drain by ~10% for each day the dm1z is left off. It seems HP laptops are configured by default to support wake-on-lan via the wired ethernet port. Unfortunately, this requires that the port remain powered even when the laptop is off.

The forum thread is on ubuntuforum. A fix is listed in this post by Redblade20XX:

during start up when the bios screen boots, press the escape button and you’ll be in a menu with configurations such as boot order. Press the “F10″ key and immediately after press the “A” key. This will enable the advance bios option and unlock more menus for configuration. Under the advance tab, there is an option for “AMD PBS Option” and under that tab there will be options that will enable certain functions on the motherboard such as bluetooth, camera, wifi, etc. Look for an option called “external lan controller” and disable it (I think this has to due with wol). After wards, press “escape” key to return to the main bios configuration menu and move to a tab called “Power”. Under that menu look for an option called “Wake on PME” (also has something to do with wol) and disable it also. Afterwards, press the “F10″ key to save the bios.

If your BIOS does not support the advanced settings, you can manually force the laptop to fully power off. Edit the file /etc/default/halt to contain:

HALT=halt

This will ensure that when you shutdown the laptop, it will not actually perform the faulty power down. Instead, it will halt and wait for you to power off. After Ubuntu reports the laptop is halted, hold down the power button for 4 seconds.

  34 Responses to “HP DM1Z Laptop running Ubuntu 10.10”

Comments (34)
  1. Hi, did you test the DM1Z with Ubuntu 11.04? has better support or you need to do the same tweaks?

    • Unfortunately, Ubuntu 11.04 doesn’t seem to be any better. You need a Linux kernel version of 2.6.29 to natively support the WIFI on the HP DM1Z, but Ubuntu 11.04 only has kernel version 2.6.28.

      I also noticed that multi-touch was not working out of the box with 11.04.

      • I am confused here, perhaps because I am a Fedora user, looking for a replacement for my HP nc2400…

        You say that WiFi needs the 2.6.29 kernel, but Ubuntu ONLY has the 2.6.38 kernel? Shouldn’t a higher kernel number equate to better support?

        BTW, my Fedora 14 has the 2.6.35 kernel. (have not played with the F15 beta)

      • I am using Ubuntu 11.04, basically a plain install, no kernel upgrade.
        I have checked my kernel version using cat /proc/version

        Linux version 2.6.38-8-generic (buildd@vernadsky) (gcc version 4.5.2 (Ubuntu/Linaro 4.5.2-8ubuntu3) ) #42-Ubuntu SMP Mon Apr 11 03:31:50 UTC 2011

        I presume that if I use this on a HP dm1z it will work?

        I wonder because I am looking to buy one soon and would like to know about compatibility..

        Cheers,
        Will.

        • I’m runing Ubuntu 11.04 and have to compile the drivers from source, but I have just tried Linux Mint 12 which is based on Ubuntu 11.10 and the wifi on my HP dm1z works straight away without any problems.

  2. Eliot,

    Thanks so much for posting this. You’ve got the best write-up on how to solve this problem by a long shot.

    Matt

  3. Great post, but i have a problem when i “ifconfig wlan2 up”

    SIOCSIFFLAGS: Operation not permitted

    Any ideas?

    Thanks

    • Something about your setup doesn’t match mine. Do you have wlan0, wlan1 and wlan2? My DM1Z only has a single wireless device: wlan0.

      I have seen these types of error messages in the past when not using the correct driver (e.g. the driver was written for a slightly different revision of the chipset). But there are probably other potential causes.

  4. It looks like the versions of rt5390 have changed. Which one do you recommend now. BTW, I’m trying to setup LinuxMint 11. TIA.

    • Version 2.4.0.4-7.1 Looks OK

      I looked over the differences between release 6.2 and 7.1 of the rt5390sta-2.4.0.4 driver. It looks like minor improvements – nothing to be worried about. For the most part, I’d recommend sticking with the latest version available.

      I did notice that the config file has been patched to include HAS_ANTENNA_DIVERSITY_SUPPORT=y, so you shouldn’t need to go in and change that.

  5. Thank you so much for sharing the fix on the wifi problem .. i also purchased a dm1 a few days ago and had some problems with the wifi connection. :)

  6. Hi , thanks for your help. But do you know if there is an opened bug for the Poweroff problem?

    I have ubuntu 11.04 and everything is working propperly except the poweroff bug.

    I saw the power “down” graphic of the battery and with last updates (natty-propposed) I think the bug is still there.

    • I’m not aware of an open bug for this issue. It appears that many distributions are exhibiting the issue, so I don’t know if opening an Ubuntu bug would be productive. The bug either resides in the Linux kernel or – more likely – is a hardware issue the kernel would have to work around.

  7. This is amazing man.
    Appreciate the help you provided me on this topic.

  8. Hello,

    Thanks for your post, but can you ckeck your kern.log and messages? I have a lot of entries due to wifi.

    I readed somwhere to remove in the config.mk the -DDBG flag. ( this flag actives the debug mode)

    thanks,
    I’m now building the driver. I will see if this solution reduces my logs.

    • I did have a lot of kernel messages when I was using the un-patched driver. Since patching, I haven’t had any problems. But a newer kernel and/or newer driver version could certainly change that. A slightly different wifi chipset revision could, too.

  9. Hey thanks for this blog! I’m really tired of scouring the internet every few weeks to find fixes to Ubuntu on the HP dm1z. The wireless patch works fantastic on my Ubuntu 11.04, so today I thought I’d try the just-release Ubuntu 11.10 alpha2. I booted from a fresh alpha2 USB stick on the dm1z, and the screen works fine, but there is _no_ wireless. I didn’t try to patch with the opensuse drivers because I thought 11.10 was going to include the native ralink drivers. Evidently it doesn’t.

    Do you or anyone have any information about whether the dm1z will have native wireless support in an upcoming 11.10 release? Its a shame to have such a spiffy laptop and not be able to use simple things like the built in wireless. At least the power off is not draining the battery anymore after using your bios fix!

    Thanks again.

  10. One more thing. BLUETOOTH! I’ve seen several random internet posts about the broken built in bluetooth on the HP dm1z fusion pavillion when running any Ubuntu. I have never seen a reply to any such query, so I thought that here might be a good place. Has anyone ever gotten any bluetooth device to work with the hp dm1z pavillion when running any flavor of Ubuntu? I have never had it recognize a mouse or headset or any bluetooth device on Ubuntu 10.10, 11.04, or, now, 11.10 alpha2.

    Broken dm1z bluetooth is almost a show stopper for me, but if there is a fix out there, or a fix coming up from Ubuntu, or for that matter a fix on any linux distro, I would love to hear about it. I’m really encouraged now that the power bug and wireless have been fixed, so lets hear about bluetooth.

    Thanks again.

  11. Amazing, spot on guide for Ralink RT5390 wireless adapter!!

    Thank you sooooo much! I’m a total newb when it comes to the terminal let alone compiling. I’ve been searching for a guide to get the Ralink adapter working and thankfully stumbled onto your blog. It worked flawlessly on my ubuntu 11.04 install. Thanks for sharing!

  12. Thought I would add my thanks to the list as well ;)

  13. So I am completely new to Ubuntu. I’ve been on a Mac for a few years, and I decided to try out Ubuntu on my new HP DM1z. I came here to try to figure out the wifi problem, but I can’t do it.

    My first problem is at the beginning. I downloaded the file (rt5390sta-2.5.0.3-1.1.src.rpm) I extracted it to a new directory named “openSUSE_rt5390sta_driver” which is in the folder that has desktop, documents, downloads, etc. So when I get into Terminal, the first step (sudo su -) works, then when i type in cd openSUSE_rt5390sta_driver, it doesn’t work. So I figured it would work if I would just drag and drop the folder into terminal, giving it the full path. It changes directories after that, but when I type the next line “tar jxvf 2010_1216_RT5390_LinuxSTA_V2.4.0.4_WiFiBTCombo_DPO.tar.bz2″ I get a bunch of errors. I think it’s becaue the file I got is different than the one listed above.

    I’m completely at a loss, and just about to begin pulling my hair out. Without WiFi, this PC is basically worthless to me. Please help in any way you can.

    Thanks.

    • Yes, unfortunately this isn’t really a project for a Linux newb. If tar is spitting out “a bunch” of errors rather than a single line saying “file not found” then I’m not certain what you have wrong.

      To determine where you put that tar file, run this in the terminal:
      find ~ | grep “DPO.tar.bz2″

      It should spit a single line listing the directory (e.g. /home/carlos/Desktop/openSUSE_rt5390sta_driver/). Change into that directory and try tar again. If it doesn’t work, post the actual error messages.

    • First of all, I would like to thank Eliot for this excellent tutorial. I couldn’t have made my wireless work without your help. You’re the man!

      As of 9/7/2011, the latest driver is rt5390sta-2.5.0.3-1.2.src.rpm. When you extract this you no longer get a file with tar.bz2 extension. The new extension is tar.xz. To extract this do the following.

      apt-get install xz-utils
      xz -dv 2011_0406_RT5390_RT5392_Linux_STA_V2.5.0.3_DPO.tar.xz

      Then follow Eliot’s instructions. There is no need to execute “vi os/linux/config.mk” because the file is already updated.
      I hope someone will find this useful especially Carlos.

      Shuji

  14. Hello, and thanks for your post about getting the wifi to work on the dm1z. I have been following your advice step for step but have come to a hitch near the end.

    at the step:
    “cp -i os/linux/rt5390sta.ko /lib/modules/2.6.32-33-generic/kernel/drivers/net/wireless/”
    I’ve run into this error:
    “cannot stat ‘os/linux/rt5390sta.ko’ : No such file or directory”

    It is possible that if it is a file that I made I named it wrong. Where would that file usually be located? Thanks in advance for your help

    -repplile

    • The file rt5390sta.ko is the compiled kernel module. If it doesn’t exist, then the compile failed.

      To determine what is wrong, you’ll need to back up a step. Run the make command again and watch for error messages printed as that command runs. It may be something simple. If you can’t make sense of it, copy the entire contents into the Contact Me form and I’ll see if I can figure it out.

      • just a quick update but the latest kernel in the 11.10 build has native wifi support and it looks like multi-touch with the trackpad has been corrected also. i am reporting complete success at this point.

        • 11.10 does support Wi-Fi natively on rt53xx devices, but if you upgraded from 11.04 you’ll have to revert the changes you made to modules and blacklist.conf.

        • I now have my DM1Z working well with Ubuntu 11.10, but it’s worth mentioning that upgrading from 10.10 to 11.04 to 11.10 didn’t work that well. Everything booted up properly after the upgrade, but things like suspend were broken.

          A fresh install fixed the issues.

  15. Nice blog, it helped me quite a bit, thanks. However it looks like there is a problem that I just can’t seem to solve: the temperature. I’ve been trying to lower the idle temps by limiting CPU freq, trying other distros and even older kernels, and it still idles at ~65ºc, that’s a little hot considering that it idles at ~55ºc in Win7.

    • I certainly don’t have an immediate fix for this. I have noticed it idles a bit warm, but hadn’t checked the actual temperatures.

      I do know Phoronix reported some power regressions in the Linux kernel. Perhaps that’s playing a part here.

      • Aw dang, somehow I triggered spam filter so I’ll keep it brief this time.
        It was the graphic driver. I installed the propietary driver and now my lappy runs cool as win7.

 Leave a Reply

(to be displayed above your comment)

(for moderation; your e-mail address will not be made public)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>