2 * (C) Copyright 2013 Inc.
4 * Xilinx Zynq SD Host Controller Interface
6 * This program is free software; you can redistribute it and/or modify it under
7 * the terms of the GNU General Public License version 2 as published by the
8 * Free Software Foundation; either version 2 of the License, or (at your
9 * option) any later version.
11 * You should have received a copy of the GNU General Public License along with
12 * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
13 * Place, Suite 330, Boston, MA 02111-1307 USA
19 #include <asm/arch/sys_proto.h>
21 int zynq_sdhci_init(u32 regbase
)
23 struct sdhci_host
*host
= NULL
;
25 host
= (struct sdhci_host
*)malloc(sizeof(struct sdhci_host
));
27 printf("zynq_sdhci_init: sdhci_host malloc fail\n");
31 host
->name
= "zynq_sdhci";
32 host
->ioaddr
= (void *)regbase
;
33 host
->quirks
= SDHCI_QUIRK_NO_CD
| SDHCI_QUIRK_WAIT_SEND_CMD
;
34 host
->version
= sdhci_readw(host
, SDHCI_HOST_VERSION
);
36 host
->host_caps
= MMC_MODE_HC
;
38 add_sdhci(host
, 52000000, 52000000 >> 9);