HP 2133

The HP 2133 is HP an inexpensive sub-notebook with the marketed intent of targeting the educational sector. It is an obvious competitor to similarly-designed notebooks such as the ASUS Eee PC. It is small (10.04" x 6.5" x 1.05"), comes with a VIA C7-M processor and a 1280 x 768 8.9" WXGA display, and has either ample hard drive storage or 4 GB of Flash-based storage.

News
After upgrade to x11-base/xorg-server-1.6.3.901-r2 previously noticed problem with openchrome driver is fixed. Working driver (x11-drivers/xf86-video-openchrome-0.2.904) can be emerged now in a usual way.

After recent stabilization of x11-base/xorg-server-1.5.3-r5 the latest stable release of openchrome (available in portage) stopped working (freezes the Xserver). You have the following options to counter this problem: I'll try to include some basic instructions for the two latter options in the text HP_2133.
 * Run the vesa driver (definitely not recommened)
 * Use a current SVN version of the openchrome driver (tested here and working)
 * Use the VIA half-baked half-binary driver (tested here and kinda working mostly including 3D acceleration)

Essential Specifications

 * Processor: 1.0, 1.2, or 1.6 GHz VIA C7-M ULV processor with VIA padlock
 * Memory: 512 MB, 1 GB, or 2 GB 667 MHz DDR2
 * Storage: 120 or 160 GB hard drive at 5400 or 7200 RPM, or 4 GB Flash drive
 * Display: 8.9" diagonal capable of a maximum of 1024 x 600 (WSVGA) or 1280 x 768 (WXGA)
 * Graphics: VIA Chrome 9 (with mpeg2 and mpeg4 decoder to reduce power consumption), VGA output up to 2048 x 1536
 * Audio: ADI1984HD, stereo speakers/headphones/line out, integrated microphone
 * Networking: Broadcom BCM5788M Gigabit (10/100/1000) NIC, Broadcom 4311AG (802.11a/b/g) or 4311BG (802.11b/g) wireless, Bluetooth optional
 * Touchpad
 * Integrated webcam
 * 3 or 6 cell battery

Installation
The HP 2133 has no optical drive, so slight deviations from the usual install process may be needed. To install, you can either use an external optical drive (in which case, you can proceed as normal.) or build a LiveUSB disc. A script for creating a LiveUSB disc from a LiveDVD iso can be found here: Gentoo bug #208499, however you can do this manually.

Creating a LiveUSB disc
You will need a USB drive of at least 4GB if you are using the LiveCD / LiveDVD iso, but this can be performed perfectly well using a 128MB USB drive if you are prepared to use the minimal install disc.

Using liveusb.sh
Partition your usb disc fdisk /dev/sdX

delete (d) all partitions on the disc, then add (n) a new primary partition of type FAT32 (b), marked active (a), then write the partition table (w)

Download the script linked earlier and run it with the path to both the liveCD and the usb disc you wish to use.

./liveusb.sh --format livedvd-i686-installer-2008.0_beta1.iso /dev/sdX1

This will go through the long process of copying the necessary files to your USB disk.

Your USB disk should now be bootable. Plug it into the side of your HP 2133, turn it on, and press F9 to get to the boot menu. Select the USB drive (it will be named as the device, but it is likely the middle option of the three) and you should see the familiar grub shell.

You must enter the grub commands to boot by hand, unfortunately: kernel /boot/gentoo root=/dev/ram0 init=/linuxrc dokeymap looptype=squashfs \ loop=/image.squashfs cdroot vga=791 initrd /boot/gentoo.igz boot

Manually
Follow the Gentoo Linux LiveUSB HOWTO.

Core Gentoo Installation
You should follow the Gentoo x86 handbook for the install, and any deviations from the handbook, or information specific for this machine will be shown below.

Chapter 3: Networking
The live/install media may not support the broadcom (b43/b43xx) wireless, so you must either install using the wired connection or by using the networkless install.

Chapter 4: Preparing the discs
The internal hard disc of this machine is /dev/sda, which may be partitioned as desired.

Chapter 5: Installing the Gentoo Installation Files
The HP 2133's processor is a VIA C7-M, and the following options in /etc/make.conf are appropriate:

Chapter 7: Kernel
It is recommended that you use at least gentoo-sources-2.6.25-r2, as this has better support for the wireless driver and a compatibility fix for b43 on VIA hardware.

Finishing
Other than noted above, there are few differences between a standard install and an install on this laptop. The remaining step is to reboot into your new install.

Sound
If you have a 2.6.26-rc5 or later kernel, support is included, however it is limited to Master and PCM channels. Input is untested. For older kernels or more functionality, use the version provided by media-sound/alsa-driver.

Kernel
With kernel 2.6.26-rc5 and later, you can use the included Intel HD Audio driver.

Then, configure the ALSA modules:

update-modules /etc/init.d/alsasound start

media-sound/alsa-driver
The card is an HDA VIA VT82xx and is supported by ALSA in the kernel, but seemingly only by the generic Intel HDA driver, so not much is available. However, the ALSA drivers provide more functionality. (You may need to unmask them if needed.)

emerge media-sound/alsa-driver /etc/init.d/alsasound start This should enable master, PCM, microphone, and speaker mixers, with a couple of input sources. See general ALSA/sound documentation to proceed.

Touchpad
The touchpad is a basic synaptics touchpad, and you can use the Synaptics Touchpad guide to configure it. The button under the keyboard, to disable the touchpad while typing, works without configuration.

Framebuffer
VIA has their own open source drivers supporting the chipset in the HP 2133 (VN896), but the author could not get them to work, and they may conflict with the openChrome drivers (which may be significant if planning on running X). The generic vesafb driver in the kernel will suffice; vga=791 is a suitable argument in this case.

x.org, WXGA (1280x768) models
The 2D portion of the graphics chipset is supported in X by, so go and install openChrome. Not that your xorg.conf should use openchrome as it's driver, and an appropriate modeline for the 1280x768 screen. Please note that the version of openchrome in portage (latest stable release) does *not* work with current stable release of xorg-server (1.5.3-r5), workarounds further down. (An example xorg.conf is shown below)

These three options ensure that the screen is not blank, and that the mouse pointer is visible. If you are using the latest gentoo-sources kernel you can go ahead with using EXA acceleration method. It Works! NOTE: EXA does not work with both solutions in the sections below (openchrome from svn and the via 3D-enabled driver) causing screen corruption or X-server hangs.

Option    "AccelMethod" "XAA"       	#There are some issues with EXA and openchrome, have raised bug report with openchrome Option    "SWCursor"  "On"         	# [ ] Option    "ForcePanel" "On"        	# [ ]

Fix for openchrome on xorg-server-1.5.3
You'll need to fetch the current release of the openchrome driver from the project's SVN repository, repackage it as a new source tarball for the driver, copy the ebuild to a local overlay of yours and make it use the new tarball. The simplistic way I did it goes more or less along these lines:

Now, mv your new tarball to your ${DISTDIR} (typically /usr/portage/distfiles), copy the original ebuild a local overlay of yours (if you don't know how to do that, consult relevant Gentoo documentation), create a digest and emerge the driver.

Please note that this solution does not require an xorg.conf file. You may set your keyboard layout, mouse behaviour and such via either HAL configuration and/or xset, setxkbmap. You may also add fontpaths via xset. If you intend to use an xorg.conf file the Option "SWCursor" "true" option is not necessary anymore with this version of openchrome.

A more elegant solution would be to create a proper SVN ebuild for the openchrome driver – contributions welcome.

xf86-video-openchrome-0.2.904
This version of the OpenChrome driver was included in the portage tree on 09 October 2009. Currently it compiles and runs fine with xorg-server-1.6.3.901-r2 on the HP 2133.

Running the half-baked VIA driver with 3D acceleration
This is a bit of a late-night hack that has not been well tested and may eat your cat's catfood, stop working, source files may disappear without notice from the VIA website and all the other usual disclaimers apply.

Anyway, the author of this section is using it this very moment and would like to share it with the community for further testing and perhaps some better ideas (perhaps an ebuild with proper eselect opengl support -- contributions welcome again).

These will be just rough instructions with the assumption that those who are willing to test this hack on their systems can deal with the sparse notes provided.

Added 2009-06-25

As mentioned in HP Mini Guide forum, there are kernel patches which can be used instead of the downloaded source. To apply the patches, go to your kernel directory (f.ex. /usr/src/linux) and issue:

for each patch. After this you'll have a new kernel menu entry at Device Drivers > Graphics Support > Direct Rendering Manager (XFree86 4.1.0 and higher DRI support) > Via chrome9 video cards. Set this option and recompile the kernel. Remember to load the module if drm wasn't compiled into the kernel. After this, all you need is the ugly part from below.

Note for kernels >2.6.28-r3

The obsolete dri_library_name sysfs attribute (see this link) remains in the code (either from the patch or downloaded from VIA). Hence, either modify the according patch or simply comment out line 165 of drivers/gpu/drm/via_chrome9_drv.c in order to be able to compile the kernel module.

So far, the VIA drivers compiled this way (with the pre-complied libGL from below) have worked like a charm leading to >>200 FPS with glxgears.

The original text continues below.

You need to go to linux.via.com.tw, select Ubuntu 8.10 from the Distro drop-down menu and CN896+VT8251 (default in the hardware dropdown menu). Now, please download the source code for "Chrome9 DRM source for kernel 2.6.27(12Dec08) (31.2K)", and the "Unified GFX driver Ver 85a-44597 for Ubuntu 8.10(02Dec08) (3.4M)" driver from the "Driver" section. Save these two files to a convenient location and untar both tarballs.

Now, in that convenient location, after unpacking, please do:

This will build the DRM kernel module and copy it over to your module dir. Don't be scared by the 2.6.27 designation. This kernel module builds, loads and seems to work correctly when built against my vanilla 2.6.29.1 kernel.

That was the elegant part. Now comes the uglier one; you need to do some manual copying of files from the other downloaded package to your live system (while making a backup of the original files in case you'd like to come back to the good old-new openchrome driver).

Back to the convenient location:

After this step you'll have copied the pre-built dri shared library to the DRI dir and will have replaced the openchrome libGL shared library with the pre-built VIA-provided one which should be sufficient to run X with the new driver (obviously, you also need to have loaded the chrome9 kernel module as well).

Simply changing the driver from openchrome to via in /etc/X11/xorg.conf didn't work for me, a working xorg.conf (it's for the high-resolution display, lores users please experiment and contribute) is available here.

The author has noticed some minor issues when using this driver:


 * terminal drawing updates delayed in rxvt-unicode (seems to affect some apps like mutt on other terminals, too), workaround: use xterm for now
 * ugly, irregularly blinking cursor in xterm, workaround: set the cursorUnderLine resource to true (or use the -uc commandline option)

x.org, WSGA (1024x600) models
The xf86-video-openchrome-0.2.903 driver in gentoo portage does not yet support 1024x600. Please check frequently the difference between portage and svn and the date of this text

Emerge the stable xorg-server-1.5.3-r5. Install openchrome svn revision 743 or later as described in the previous section or on the openChrome wiki.

With this combination there is no need for xorg.conf.

x.org, VGA-output
The HP-specifications declare:


 * Up to 32-bit per pixel color depth
 * VGA port supports resolutions up to 2048 x 1536 at 75 Hz, and lower resolutions at up to 100 Hz

To get VGA-output install the same as in section x.org, WSGA (1024x600) models. Then create a xorg.conf file:

Then edit the xorg.conf file and add (1280x1024 or your resolution):

To the Section "Device" Option     "PanelSize" "1280x1024" And to the Section "Screen"

SubSection "Display" .       .      Virtual   1280  1024

If you installed the svn-version you now have a new man page (still also in the source directory). Read it for the options.

Webcam
The webcam is reported to work correctly with the current releases of the Linuc UVC driver from. This driver is included in current kernels, you if you're running a recent kernel, you don't have to do anything.

Wireless
The wireless is a Broadcom 43xx and is reported to work satisfactorily with the b43 driver.

Those with integrated HP-module that has both bluetooth and wlan check:

If you see something like:

02:00.0 Network controller [0280]: Broadcom Corporation BCM4312 802.11b/g [14e4:4315] (rev ff) (prog-if ff)

As in linuxwireless.org reads: 14e4:4315 not supported chip=BCM4312 - low power driver=b43

The BCM4312 - low power is unsuported. You need the broadcom driver from broadcom.

It can be used till kernel 2.6.28 but not for 2.6.29 because of renaming /lib/modules/2.6.29-gentoo-r1/kernel/net/wireless/lib80211_crypt_tkip.ko to /lib/modules/2.6.28-gentoo-r4/kernel/net/ieee80211/ieee80211_crypt_tkip.ko

Suspend
Suspend to disk works out of the box on gentoo-sources-2.6.26-r1 and gentoo-sources-2.6.25-r7. Use hibernate-script.

RAM
If you are using a non-framebuffer console, emerge vbetool and configure hibernate-ram to use it.

Ensure b43 is compiled as a module. This will prevent the kernel from crashing on resume. Add irqpoll to the kernel command line (i.e. in grub.conf) so wireless will work on resume. Tested on gentoo-sources-2.6.26-rc1.

ST LIS3LV02Dx accelerometer
STMicroeletronics LIS3LV02Dx three-axis digital accelerometer is inside the computer. The kernel kernel modules:


 * gentoo 2.6.28-r2 lis3lv02d
 * gentoo 2.6.29 hp_accel

The accelerometer data is readable via /sys/devices/platform/lis3lv02d. To see the values:

Read the kernel documentation how to use it. Most useful it may be when trying different x-server configurations that freeze the keyboard and mouse. Just tilt the computer a bit and it stops the x-server, tilting other direction shuts down or restarts the computer.

This driver provide 2 devices: "joystick" input device and (most useful) /dev/freefall (be sure your kernel is SMP or supporting local APIC). Most simple way to use /dev/freefall as HDD protection - "hpfall" daemon, shipping with kernel sources - Documentation/hwmon/hpfall.c, may be compiling as:

Then:

Video

 * Never got official VIA framebuffer driver to work
 * X.org openChrome driver does not support DRI/DRM.
 * Non-framebuffer console corrupted after using X. Fix using vbetool post

To run viafb as module required (1024x600, kernel 2.6.36): vmalloc=162148800 kernel option (or more); viafb_active_dev=LCD viafb_lcd_panel_id=17 module options.