[cm-x255] USB Gadget (usb slave)
I got linking errors when building usb gadget support into the kernel:
eth_unbind' referenced in section `.init.text' of drivers/built-in.o: defined
in discarded section `.exit.text' of drivers/built-in.o
I found a workaround but I dont understand why it was needed and why it works:
Remove the __exit from the eth_unbind function (ether.c:2137) and dont use
__exit_p in struct usb_gadget_driver (ether.c:2552). A similar workaround may
be needed for other gadget drivers.
[cm-x270] USB Gadget (usb slave)
PXA270 usb slave support is based on the handhelds.org 2.6 kernel CVS and
I had a little trouble getting this to work. All gadget drivers I tried failed to autoconfigure.
I noticed in the patch above that all gadget drivers were patched to call gadget->ops->ep_alloc
instead of using usb_ep_autoconfig. Instead of doing the same thing which would not work on the cm-x255,
I added the following two lines to epautoconf.c, which seems to work fine:
--- ../../../../linux-220.127.116.11/drivers/usb/gadget/epautoconf.c 2006-05-24 21:50:17.000000000 -0400
+++ epautoconf.c 2006-06-21 11:27:05.000000000 -0400
@@ -238,6 +239,9 @@
@@ -238,6 +239,9 @@
type = desc->bmAttributes > USB_ENDPOINT_XFERTYPE_MASK;
+ if (gadget_is_pxa27x (gadget))
+ return gadget->ops->ep_alloc(gadget, desc, epconfig, numconfigs);
/* First, apply chip-specific "best usage" knowledge.
* This might make a good usb_gadget_ops hook ...
[cm-x2xx] DM9000 Ethernet
I used the dm9000 driver from a vanilla kernel. Added platform data in cm-x270.c and cm-x255.c
to make it work. However, there is a small bug: The MAC address is NULL! In Compulab's version of the driver,
they read the MAC address differently. For the moment, I added calls to machine_is_cm_x270() and
machine_is_cm_x255() and use the Compulab way to get the MAC address, which works.
[cm-x2xx] IT8152 PCI Controller
Those boards use the it8152 pci controller (I think there are other peripherals integrated
in this chip but I cannot find any documentation and ITE does not respond to my mails).
Compulab's patch touches/creates the following files:
For the cm-x255, I combined IT8152-pci.c and IT8152-pcistruct.c into one file named it8152.c. I also
renamed some interrupt names in include/asm-arm/arch-pxa/irqs.h. All this stuff needs to be reworked
to be cleaner.
I have not yet started working on the cm-x270 PCI support.
[cm-x2xx] UCB1400 (For touchscren controller function)
an AC97 codec with an integrated 4 wire touchscreen controller used on CM-X255 and CM-X270 when
they are built with touchscreen support.
The most recent patches I could find for this chip were posted by Nicolas Pitre
on the linux-arm-kernel mailing list on Wed Mar 30 2005:
Some modifications were necessary since those patches were originally for 2.6.12. Here
is how I applied them on 2.6.17-rc6:
- alsa_pxa.patch-0001: Already present in 2.6.17-rc6.
- ac97_bus.patch-0001: All parts were already present 2.6.17-rc6, except the changes
to sound/pci/ac97/ac97_codec.c which I applied.
- ucb1400_ts.patch-0001: Applied but code fixes were needed to cope with small API changes.
- ucb1x00.patch-0001: Applied but code fixes were needed to cope with small API changes.
For your convenience, here are the patches updated for 2.6.17-rc6:
Back to the
Drivers and patches for Compulab cm-x255 and cm-x270w boards