Powered by
Movable Type 5.2.7

 August 2010 Archives

2010, August 11 (Wed)

Linux consolekit & sound card control

to move control over sound card in case you have applied some dirty hacks you have to refer to root powers.

First, remove all access to the sound card from current user (user1):

setfacl -x u:user1     /dev/*dsp /dev/audio /dev/mixer* /dev/snd/*(^/)

Then add it back to for another user (user2):

setfacl -m u:user2:rw- /dev/*dsp /dev/audio /dev/mixer* /dev/snd/*(^/)

pulseaudio -k will reload the resp. pulseaudio and will not find any card for user1, but find the cards for user2. I only did this with no client connected, maybe needs more investigation.


2010, August 13 (Fri)

Linux Direct Rendering 32bit vs. 64bit

Problem: You believe you have your Linux set up correctly, graphics driver is a good one, direct rendering works as is confirmed by glxgears (64bit) works fine, and glxinfo says direct rendering: Yes

However, some 32bit software (e.g. wine) causes errors. WINEDEBUG=+wgl will reveal:

 Direct rendering enabled: False

although driver etc. are recognized properly. Further debugging of the problem can be done with LIBGL_DEBUG=verbose. The 32bit app will say

libGL: OpenDriver: trying /usr/lib/dri/r600_dri.so
libGL error: failed to create dri screen

This shows two things:

1. the driver is the correct one (note lib = 32bit vs. lib64 = 64bit as would be the output given by glxgears). If the driver were wrong, there would be an elf class error (you can set the driver path explicitly with LIBGL_DRIVERS_PATH)
2. cannot create dri screen :/

The 64bit one will have OpenDriver: trying /usr/lib64/dri/r600_dri.so (for example) and no error.

This instance of the problem was caused by the following: the 32bit and 64bit versions of libdrm and/or Mesa were different _. This happened due to an X.org upgrade which upgraded the 64bit parts, but the 32bit stuff installed in parallel with an older version (can I blame the package manager for not marking this as a conflict?)

Making sure the various package.x86_64 and package-32bit versions were exactly the same, this problem resolved.

Linux Xephyr fixed font not found

The input method doesn’t work inside Xephyr? Sometime you find out that .xsession-errors says

 Preparation of font set "fixed" for XIM failed.

The font path could be wrong. Make sure that the path to misc is the first one in row.

 xset +fp /usr/share/fonts/misc

would fix it for the moment (path might vary).

Compiling Xephyr I missed the following switches:

./configure --enable-xephyr --enable-kdrive-evdev --enable-kdrive-mouse --enable-kdrive-kbd --enable-kdrive --prefix=/usr --with-fontrootdir=/usr/share/fonts --libdir=/usr/lib64

Thanks for paying attention!


2010, August 15 (Sun)

 Vodafone 845/Huawei u8120 (on Mac OS X)

The Vodafone 845 is using the same ZeroCD crap as other UMTS hardware by Huawei. For Linux (or libusb), usb_modeswitch exists, but this did not work for me.

So here is how to toggle the device itself without any special driver.

su -c 'echo 1035 > /sys/devices/platform/msm_hsusb_periphera/composition'

This will not hide the Mobile Partner CD drive but its USB product id changes, which allows now to use the osx-pl2303 driver and also adb from the android SDK to be used.

See here for how to load the pl2303 driver. Note that OS X is using decimal representation of vendor id and product id (0x12d1 -> 4817, 0x1035 -> 4149).

This should also work with the T-Mobile Pulse Mini and maybe with other Android devices built by Huawei.

Edit: You need to have root on your device.

If you have root, you can try this small application:
ToggleUSB.apk

Google hints: Vodafone 845 u8120 0x12d1 0x1031 0x12d1 0x1035 Mobile Partner Pulse Mini


2010, August 25 (Wed)

Linux nvidia sucks

Unfortunately the open-source nouveau driver is not there yet, and their proprietary shit doesn't even do RandR 1.2, which means no sane way for multiple-display setup with single-display fullscreen gaming, or rotation if you need that.

Thanks for listening.

On openSUSE at least, you can use the proprietary driver after installation by adding nouveau.modeset=1 to the kernel command line (no other hackery was necessary for me). Unfortunately, the installation breaks the OpenGL driver of nouveau.