VIA CLE266 Epia M howto

                (as at 31 August 2003)

    Current support

 Linux kernel ( >= 2.4.21) supports processor (C3-2), chipset, IDE, USB2, IEEE1394, sound and network.
 ALSA 0.9.0rc6 or 0.9.2(has noise) snd-via82xx required for sound.
 Network support with via-rhine (in Linux kernel) or external rhinefet driver (VT8231_VT8233_VT8235v32MVIA.zip LINUX/).
 Hardware Monitoring requires LM_sensors from the latest debian package or down from http://www2.lm-sensors.nu/~lm78 for (vt8231 or vt1211). A graphics utility and sample program (using i2c-viapro) is available.
 Frequency scaling is experimental, a graphic utility program is available which uses /proc/sys/cpu. (uses Power Saver (was longhaul.o) kernel module)
 Nehemiah hardware random number generator support from 2.5.65 and a test program is available.
 FIR requires external device and driver.

    Linux config options

 * These options require a patch below and should be set as modules.

VIA C3-2
MTRR
disable SMP
ATA/IDE/MFM/RLL support
 ->IDE, ATA and ATAPI Block Devices
  ->VIA82CXXX chipset support
  ->Generic PCI busmaster DMA support
char
 ->via random number generator
 ->AGP support
  ->VIA *
 ->Direct Rendering Manager 4.1 (DRM)
  ->VIA CLE266 *
Video for Linux
 ->VIA CLE266 *
USB support
 ->USB host controller drivers
  ->EHCI HCD (USB2.0) support
  ->USB storage
ohci1394 (firewire)
via-rhine
Power management option (ACPI,APM)
 ->CPU Frequency Scaling
  ->/proc/sys/cpu interface (2.4./OLD)
i2c
soundcore

    Sound

 Analog output working (both ALSA and kernel drivers).
 Digital output working using ALSA9RC7. You have to set IEC958 Playback AC97-SPSA to 0, for example by issueing $> amixer sset 'IEC958 Playback AC97-SPSA' 0 AC3 output with mplayer is fine. Use -ac hwac3 or modify your codecs.conf so it is using hwac3 as first ac3 driver (and not a52 lib).

    Video

Via kernel support is in -ac patches and should be in 2.6.x
Via X windows support is in XFree86 4.3.99 cvs and should be in XFree86 4.4.x
-ac and XFree86 are both broken as at 31 Aug 2003

Redhat 8.0 uses XFree86 4.2.x so its binary drivers can be used with Debian testing/unstable.

X11 errors I have seen
 Failed to set up write-combining range (0xd8000000,0x2000000) in /var/log/syslog and /var/log/XFree86.0.log.
 !!!!!!!!!!Cap0_FieldSwap = 0 in /var/log/XFree86.0.log.
 Very mild screen corruption.

        Setup on Debian

How I got Debian Unstable working on an Epia M 10000 VIA C3-2(Nehemiah) with 512MB memory, 120GB Seagate hard drive, DVD rom.
This information should be useful for other distributions.

    /etc/modules.conf

Under Debian, just put all these files in /etc/modutils and execute update-modules.  For other distributions add the contents of these files to /etc/modules.conf.

 alsamine stops cracking sound
 1394conf for firewire support
 viaconf for video drivers

    /etc/modules

Comment out everything and then on separate lines add:
 via-rhine
 agpgart
 videodev
 via_v4l_drv
 via

On other distributions add to /etc/rc.d/rc.local:
 modprobe via-rhine
 modprobe agpgart agp_try_unsupported=1
 modprobe via_v4l_drv
 modprobe via

    /etc/X11/XF86Config-4

Copy XF86Config-4 to /etc/X11.  You will have to edit it to match your monitor.  You can also set CRT, TV or LCD as the display device and other display options.

    VIA binary drivers

Untar and make this package via-clexf40030-dri-debian.tar.bz2 .  This is an updated version of Matthias Müller's via-clexf40028-dri-debian.tar.bz2 and should work with all distributions using X windows 4.2.x.  You can uninstall with the make uninstall command.  This is the drivers from clexf40030-lite-bin_08012003.zip for c3, so you could use that instead.

    Kernel and Alsa

Debian people can install kernel-image-2.4.22-epiamn_dbox.2_i386.deb and alsa-modules-2.4.22-epiamn_0.9.6-2+dbox.2_i386.deb and reboot.

Other distributions will have to recompile a kernel and alsa 0.9.6.
I have used linux-2.4.22.tar.bz2 with patch-linux-2.4.22-cle266-paul.gz and config-2.4.22-epiamn.2 .  Much thanks to Matthias Müller for his patch and README. (For some reason I can't access his epia-m/ directory anymore.)  

    After reboot

Turn up the sound in alsa drivers.  Try this script.

To check for 3D DRI, execute glxinfo and see if the third line has direct rendering: Yes.  Execute glxgears and it should return greater than 300 frames per second for the default size.

Check for xv support with xvinfo.

I haven't tested the mpeg2-hw-decoding part yet.

    Other stuff

Try this utility from Via.

Here is mplayer_0.90_i386.deb (this is version 0.91 and not what the package says) and dotmplayer.tgz (untar this in the root of your home directory (~) to get a skin and fonts).  Try a video file with gmplayer -vo xv -ao oss file.avi .

Here is a sensors.conf that was on the VIA forum for Linux that I haven't tried.

Check out this site about the Epia M.

    Contact info

Please don't spam me. ;-)
p @ andreassen com au
Email me with any fixes, improvements or problems.