2 * Copyright (C) 2015 Google, Inc
3 * Written by Simon Glass <sjg@chromium.org>
5 * SPDX-License-Identifier: GPL-2.0+
14 struct mmc *mmc_get_mmc_dev(struct udevice *dev)
16 struct mmc_uclass_priv *upriv;
18 if (!device_active(dev))
20 upriv = dev_get_uclass_priv(dev);
24 U_BOOT_DRIVER(mmc) = {
29 UCLASS_DRIVER(mmc) = {
32 .flags = DM_UC_FLAG_SEQ_ALIAS,
33 .per_device_auto_alloc_size = sizeof(struct mmc_uclass_priv),