Add and use a MMC_DECLARE_BRIDGE macro for declaring mmc(4) bridges
as kernel drivers and their dependency onto mmc(4); this allows for incrementing the mmc(4) module version but also for entire omission of these bridge declarations for mmccam(4) in a single place, i. e. in dev/mmc/bridge.h.
This commit is contained in:
parent
b06b52baac
commit
55dae242e6
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=314887
@ -918,5 +918,4 @@ static driver_t a10_mmc_driver = {
|
||||
|
||||
DRIVER_MODULE(a10_mmc, simplebus, a10_mmc_driver, a10_mmc_devclass, NULL,
|
||||
NULL);
|
||||
DRIVER_MODULE(mmc, a10_mmc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(a10_mmc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(a10_mmc);
|
||||
|
@ -1095,5 +1095,4 @@ static devclass_t aml8726_mmc_devclass;
|
||||
DRIVER_MODULE(aml8726_mmc, simplebus, aml8726_mmc_driver,
|
||||
aml8726_mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(aml8726_mmc, aml8726_gpio, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, aml8726_mmc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(aml8726_mmc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(aml8726_mmc);
|
||||
|
@ -1375,5 +1375,4 @@ static devclass_t aml8726_sdxc_devclass;
|
||||
DRIVER_MODULE(aml8726_sdxc, simplebus, aml8726_sdxc_driver,
|
||||
aml8726_sdxc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(aml8726_sdxc, aml8726_gpio, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, aml8726_sdxc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(aml8726_sdxc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(aml8726_sdxc);
|
||||
|
@ -1400,5 +1400,5 @@ DRIVER_MODULE(at91_mci, simplebus, at91_mci_driver, at91_mci_devclass, NULL,
|
||||
DRIVER_MODULE(at91_mci, atmelarm, at91_mci_driver, at91_mci_devclass, NULL,
|
||||
NULL);
|
||||
#endif
|
||||
DRIVER_MODULE(mmc, at91_mci, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(at91_mci, mmc, 1, 1, 1);
|
||||
|
||||
MMC_DECLARE_BRIDGE(at91_mci);
|
||||
|
@ -679,5 +679,4 @@ static driver_t bcm_sdhci_driver = {
|
||||
DRIVER_MODULE(sdhci_bcm, simplebus, bcm_sdhci_driver, bcm_sdhci_devclass,
|
||||
NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_bcm, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_bcm, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_bcm, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_bcm);
|
||||
|
@ -761,5 +761,4 @@ static driver_t lpc_mmc_driver = {
|
||||
};
|
||||
|
||||
DRIVER_MODULE(lpcmmc, simplebus, lpc_mmc_driver, lpc_mmc_devclass, NULL, NULL);
|
||||
DRIVER_MODULE(mmc, lpcmmc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(lpcmmc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(lpcmmc);
|
||||
|
@ -464,5 +464,4 @@ static DEFINE_CLASS_0(sdhci, tegra_sdhci_driver, tegra_sdhci_methods,
|
||||
DRIVER_MODULE(sdhci_tegra, simplebus, tegra_sdhci_driver, tegra_sdhci_devclass,
|
||||
NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_tegra, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_tegra, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_tegra);
|
||||
|
@ -725,5 +725,4 @@ static driver_t ti_sdhci_driver = {
|
||||
DRIVER_MODULE(sdhci_ti, simplebus, ti_sdhci_driver, ti_sdhci_devclass, NULL,
|
||||
NULL);
|
||||
MODULE_DEPEND(sdhci_ti, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_ti, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_ti, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_ti);
|
||||
|
@ -139,4 +139,10 @@ struct mmc_host {
|
||||
extern driver_t mmc_driver;
|
||||
extern devclass_t mmc_devclass;
|
||||
|
||||
#define MMC_VERSION 1
|
||||
|
||||
#define MMC_DECLARE_BRIDGE(name) \
|
||||
DRIVER_MODULE(mmc, name, mmc_driver, mmc_devclass, NULL, NULL); \
|
||||
MODULE_DEPEND(name, mmc, MMC_VERSION, MMC_VERSION, MMC_VERSION);
|
||||
|
||||
#endif /* DEV_MMC_BRIDGE_H */
|
||||
|
@ -1181,5 +1181,4 @@ static devclass_t dwmmc_devclass;
|
||||
|
||||
DRIVER_MODULE(dwmmc, simplebus, dwmmc_driver, dwmmc_devclass, NULL, NULL);
|
||||
DRIVER_MODULE(dwmmc, ofwbus, dwmmc_driver, dwmmc_devclass, NULL, NULL);
|
||||
DRIVER_MODULE(mmc, dwmmc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(dwmmc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(dwmmc);
|
||||
|
@ -994,5 +994,4 @@ static driver_t fsl_sdhci_driver = {
|
||||
DRIVER_MODULE(sdhci_fsl, simplebus, fsl_sdhci_driver, fsl_sdhci_devclass,
|
||||
NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_fsl, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_fsl, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_fsl, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_fsl);
|
||||
|
@ -368,5 +368,4 @@ static devclass_t sdhci_acpi_devclass;
|
||||
DRIVER_MODULE(sdhci_acpi, acpi, sdhci_acpi_driver, sdhci_acpi_devclass, NULL,
|
||||
NULL);
|
||||
MODULE_DEPEND(sdhci_acpi, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_acpi, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_acpi, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_acpi);
|
||||
|
@ -306,5 +306,4 @@ static devclass_t sdhci_fdt_devclass;
|
||||
DRIVER_MODULE(sdhci_fdt, simplebus, sdhci_fdt_driver, sdhci_fdt_devclass,
|
||||
NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_fdt, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_fdt, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_fdt, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_fdt);
|
||||
|
@ -486,5 +486,4 @@ static devclass_t sdhci_pci_devclass;
|
||||
DRIVER_MODULE(sdhci_pci, pci, sdhci_pci_driver, sdhci_pci_devclass, NULL,
|
||||
NULL);
|
||||
MODULE_DEPEND(sdhci_pci, sdhci, 1, 1, 1);
|
||||
DRIVER_MODULE(mmc, sdhci_pci, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(sdhci_pci, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(sdhci_pci);
|
||||
|
@ -989,5 +989,4 @@ static driver_t jz4780_mmc_driver = {
|
||||
|
||||
DRIVER_MODULE(jzmmc, simplebus, jz4780_mmc_driver, jz4780_mmc_devclass, NULL,
|
||||
NULL);
|
||||
DRIVER_MODULE(mmc, jzmmc, mmc_driver, mmc_devclass, NULL, NULL);
|
||||
MODULE_DEPEND(jzmmc, mmc, 1, 1, 1);
|
||||
MMC_DECLARE_BRIDGE(jzmmc);
|
||||
|
Loading…
Reference in New Issue
Block a user