Page MenuHomeFreeBSD

Add support for Armada 3700 EHCI
ClosedPublic

Authored by mw on Sep 6 2017, 7:31 PM.
Tags
Referenced Files
F105709013: D12255.diff
Thu, Dec 19, 12:50 PM
Unknown Object (File)
Thu, Nov 28, 4:14 PM
Unknown Object (File)
Thu, Nov 28, 4:13 PM
Unknown Object (File)
Thu, Nov 28, 4:13 PM
Unknown Object (File)
Thu, Nov 28, 3:53 PM
Unknown Object (File)
Nov 1 2024, 2:49 PM
Unknown Object (File)
Oct 19 2024, 10:39 PM
Unknown Object (File)
Oct 12 2024, 9:44 PM

Details

Summary

This patch reuses ehci_mv driver by adding a support for the new
compatible string and adding ehci_mv.c to list of available options
for arm64 platforms.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

This revision was automatically updated to reflect the committed changes.
head/sys/dev/usb/controller/ehci_mv.c
180–181 ↗(On Diff #32834)

can we use ofw_bus_search_compatible here, as in D12258?

head/sys/dev/usb/controller/ehci_mv.c
180–181 ↗(On Diff #32834)

Actually this code should be executed only for legacy devices using "mrvl,usb-ehci" compatible string, so ofw_bus_search_compatible is imo not sufficient.

Would you like to invert the condition to:

if ((ofw_bus_is_compatible(self, "mrvl,usb-ehci")) {

or can we leave it as-is now?

head/sys/dev/usb/controller/ehci_mv.c
180–181 ↗(On Diff #32834)

The ocd_data field returned by ofw_bus_is_compatible() doesn't have to be just true/false. When you've got hardware that has a few small variations, you can use an enum with each compat string (see dev/sdhci/fsl_sdhci.c for an example). You could also do something like a set of bitmapped flags where different flag bits indicate different quirks.