Bugfix: the attach routine needs to use the same table of fdt compat

strings that the probe routine used.
This commit is contained in:
Ian Lepore 2013-11-02 22:44:35 +00:00
parent d2f51fc343
commit 8310e9ea5d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=257561

View File

@ -558,13 +558,9 @@ imx_sdhci_attach(device_t dev)
sc->dev = dev;
if (ofw_bus_is_compatible(dev, "fsl,imx51-esdhc")) {
sc->hwtype = HWTYPE_ESDHC;
} else if (ofw_bus_is_compatible(dev, "fsl,imx-usdhc")) {
sc->hwtype = HWTYPE_USDHC;
} else {
sc->hwtype = ofw_bus_search_compatible(dev, compat_data)->ocd_data;
if (sc->hwtype == HWTYPE_NONE)
panic("Impossible: not compatible in imx_sdhci_attach()");
}
rid = 0;
sc->mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid,