Page MenuHomeFreeBSD

Add mmc_fdt_helpers

Authored by manu on Jan 19 2020, 7:54 PM.



Those functions are here to help fdt mmc controller drivers to parse
the dts to find the supported speeds and the regulators.
Not all DTS have every settings properly defined so host controller
will still have to add some caps themselves.
It also add a mmc_fdt_gpio_setup function which will read the cd-gpios
property and register it as the CD pin. If the pin support interrupts one will
be registered and the cd_helper function will be called. If the pin doesn't
support interrupts the internal taskqueue will poll for change and call the same
cd_helper function.

TODO: manpages.

Test Plan

Tested on different allwinner boards.

Diff Detail

rS FreeBSD src repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

manu created this revision.Jan 19 2020, 7:54 PM
manu updated this revision to Diff 69011.Feb 29 2020, 9:26 PM

Add the cd_handler as an argument of mmc_fdt_gpio_setup.

kibab added a subscriber: kibab.Mar 12 2020, 8:37 PM
This revision was not accepted when it landed; it landed in state Needs Review.Apr 14 2020, 4:31 PM
This revision was automatically updated to reflect the committed changes.