[PATCH] powerpc: Add of_platform support for OHCI/Bigendian HC

Sylvain Munaut tnt at 246tNt.com
Wed Nov 8 04:32:14 EST 2006


>>>> This patch use of_platform device to probe and install OHCI big
>>>> endian HC.
>>>>
>>>> PS: I did not success to properly inline the file using thrunderbird.
>>>>
>>>
>>> You really copy the USB maintainers on this.  Also, why bother with
>>> the Kconfig for USB_OHCI_HCD_PPC_OF_BE/USB_OHCI_HCD_PPC_OF_LE?
>>>
>> I think it's a good idea to use those :
>>  - Just including both when PPC_OF is used is overkill because it makes
>> all USB
>> perform useless tests if you never intend to use the LE version for
>> example.
>>  - Using the already defined symbol USB_OHCI_BIG_ENDIAN would force
>> other ohci user to select BE/LE and they may not want to expose this.
>
> Maybe I'm missing something, but it looks like the _OF_LE & _OF_BE are
> just configuring what matches may occur.  This seems like a one time
> event.

+
+config USB_OHCI_HCD_PPC_OF_BE
+	bool "Support big endian HC"
+	depends on USB_OHCI_HCD_PPC_OF
+	default y
+	select USB_OHCI_BIG_ENDIAN
+
+config USB_OHCI_HCD_PPC_OF_LE
+	bool "Support little endian HC"
+	depends on USB_OHCI_HCD_PPC_OF
+	default n
+	select USB_OHCI_LITTLE_ENDIAN

What's important is the USB_OHCI_BIG_ENDIAN and USB_OHCI_LITTLE_ENDIAN symbols that are selected when you choose these options.
When both are active, each usb mmio access will test either to access in BE mode or LE mode. If only one is active, the test is hardcoded.



    Sylvain




More information about the Linuxppc-dev mailing list