[Libdlo] [PATCH] Fix displaylink-mod with 2.6.32

Bernie Thompson bernie at plugable.com
Thu Dec 9 13:32:18 PST 2010


Hi Jonathan,

Thank you for this patch submission!  Here's some background on what
you were seeing:

On Wed, Dec 8, 2010 at 7:56 PM, Jonathan McDowell <noodles at earth.li> wrote:
>
> I noticed a shiny toy on my office mate's desk today, so I borrowed it.
> It's an HP "USB DOCK" featuring a DisplayLink DVI device. The box claims
> it does 1600x1200 and I have a spare 1680x1050 monitor, so I figured I'd
> try it out.

This sounds like a DisplayLink DL-160 chip

>
> I'm running Debian Squeeze, so a 2.6.32 kernel and Xorg 7.5
>
> First I tried the udlfb driver from http://git.plugable.com/webdav/udlfb
> That detected the device/monitor fine, showed the expected monitor
> modes, but then picked 1280x1024 and provided a fetching green screen.
> Compiling up xf86-video-displaylink 0.3 gave working X, but again only
> 1280x1024.

In all recent versions of udlfb the mode is selected this way:

1) We start from the monitor's preferred mode (assuming this monitor's
EDID reported 1680x1050)
2) We look at a DisplayLink-specific USB descriptor (in the device's
firmware) to read the device's maximum mode
3) If the device can't do the monitor's preferred mode, we (call fbdev
functions to) pick the best lower alternative mode listed in the EDID

There are actually chips out there that can successfully set modes
higher than what the firmware says.  So if we didn't do #2 we would
be, kind-of "overclocking" the chip.  But there are other chips who go
blank in the same situation - so in order to make things
plug-and-play, udlfb does not try those beyond-spec modes.

That could be what you saw, but there's one thing confusing -- the
DL-160 should be able to do 1680x1050 as a mode.  So something doesn't
seem right.  If you'd be willing, could you install the latest udlfb
again:

git clone http://git.plugable.com/webdav/udlfb/
cd udlfb
make
sudo make install
sudo depmod -a

and post the udlfb output relevant to the mode it chooses, shown in
dmesg or /var/log/kern.log ?

>
> I found displaylink-mod from
> http://git.plugable.com/webdav/displaylink-mod/ which seemed to suggest
> it could do up to 1920x1200, but wouldn't compile. The attached patch
> makes it compile for me, it detects 1680x1050 on the monitor fine and I
> now have a triple head configuration running (nouveau providing the
> other 2 heads).
>
> I'm posting this in case it helps anybody else; I found several queries
> about getting displaylink-mod to compile while looking for a solution,
> but no answers.

Thanks for this patch - even though it's against an unmaintained older
codeline, I'm sure it will be useful to someone.

> (I don't know if the driver in most recent upstream kernels would have
> worked fine; that would have been my next try if displaylink-mod hadn't
> worked. It looks like udlfb is the more maintained driver? Are there
> patches to make it work in higher resolutions I can try?)

Yes, udlfb is the maintained driver. The "master copy" has been at
http://git.plugable.com/ and the version in kernel has been getting
periodically updated from that, but now as the driver is mature, we're
transitioning to the version in the latest kernel tree being the most
up to date.

In 2.6.37, udlfb is in staging
We're working to have the driver promoted out of staging in 2.6.38/39.

> J.

Thanks,
Bernie
http://plugable.com/


More information about the Libdlo mailing list