Wednesday, November 7, 2012

Linux USB host driver for Freescale's MPC83XX

Recently I got a project to set MPC8308RDB USB to host mode and support serial USB driver.
MPC8308RDB is evaluation board for PQII-Pro MPC8308 supplied by Freescale.

First of all I configured the Linuk kernel:

make ARCH=powerpc CROSS_COMPILE=ppc_6xx- mpc83xx_defconfig

Thus how I got the default .config file for my board.
Then I did:

make ARCH=powerpc CROSS_COMPILE=ppc_6xx- xconfig

And I changed the configuration according to my needs (USB, USB Host, USB Serial, etc.)

Then I burn this Kernel image to the flash - but got nothing...

I googled about it, tried to get answer in some related mailing list, ask for support request by Freescale - but no one really managed to help me solve this problem.

Eventually I checked my DTS file, and there were the answer - you must configure correctly the USB.
Unfortunately, there is no documentation for the DTS file (correct me if I am wrong).
Anyway, this is how USB Host should be configured in the DTS file for MPC83xx processors (I assume it is true also for other Freescale's processors):

        usb@23000 {
            compatible = "fsl-usb2-dr";
            reg = <0x23000 0x1000>;
            #address-cells = <1>;
            #size-cells = <0>;
            interrupt-parent = <&ipic>;
            interrupts = <38 0x8>;
            dr_mode = "host";
            phy_type = "ulpi";
        };

Good Luck

Avner

No comments:

Post a Comment