struct omap_mmc_s *omap_mmc_init(hwaddr base,

                MemoryRegion *sysmem,

                BlockDriverState *bd,

                qemu_irq irq, qemu_irq dma[], omap_clk clk)

{

    struct omap_mmc_s *s = (struct omap_mmc_s *)

            g_malloc0(sizeof(struct omap_mmc_s));



    s->irq = irq;

    s->dma = dma;

    s->clk = clk;

    s->lines = 1;	/* TODO: needs to be settable per-board */

    s->rev = 1;



    omap_mmc_reset(s);



    memory_region_init_io(&s->iomem, NULL, &omap_mmc_ops, s, "omap.mmc", 0x800);

    memory_region_add_subregion(sysmem, base, &s->iomem);



    /* Instantiate the storage */

    s->card = sd_init(bd, false);

    if (s->card == NULL) {

        exit(1);

    }



    return s;

}

struct omap_mmc_s *omap_mmc_init(hwaddr base,

                MemoryRegion *sysmem,

                BlockDriverState *bd,

                qemu_irq irq, qemu_irq dma[], omap_clk clk)

{

    struct omap_mmc_s *s = (struct omap_mmc_s *)

            g_malloc0(sizeof(struct omap_mmc_s));



    s->irq = irq;

    s->dma = dma;

    s->clk = clk;

    s->lines = 1;	

    s->rev = 1;



    omap_mmc_reset(s);



    memory_region_init_io(&s->iomem, NULL, &omap_mmc_ops, s, "omap.mmc", 0x800);

    memory_region_add_subregion(sysmem, base, &s->iomem);



    

    s->card = sd_init(bd, false);

    if (s->card == NULL) {

        exit(1);

    }



    return s;

}

struct omap_mmc_s *FUNC_0(hwaddr VAR_0,

                MemoryRegion *VAR_1,

                BlockDriverState *VAR_2,

                qemu_irq VAR_3, qemu_irq VAR_4[], omap_clk VAR_5)

{

    struct omap_mmc_s *VAR_6 = (struct omap_mmc_s *)

            g_malloc0(sizeof(struct omap_mmc_s));



    VAR_6->VAR_3 = VAR_3;

    VAR_6->VAR_4 = VAR_4;

    VAR_6->VAR_5 = VAR_5;

    VAR_6->lines = 1;	

    VAR_6->rev = 1;



    omap_mmc_reset(VAR_6);



    memory_region_init_io(&VAR_6->iomem, NULL, &omap_mmc_ops, VAR_6, "omap.mmc", 0x800);

    memory_region_add_subregion(VAR_1, VAR_0, &VAR_6->iomem);



    

    VAR_6->card = sd_init(VAR_2, false);

    if (VAR_6->card == NULL) {

        exit(1);

    }



    return VAR_6;

}

struct omap_mmc_s *FUNC_0(hwaddr VAR_0,
MemoryRegion *VAR_1,
BlockDriverState *VAR_2,
qemu_irq VAR_3, qemu_irq VAR_4[], omap_clk VAR_5)
{ struct omap_mmc_s *VAR_6 = (struct omap_mmc_s *)
g_malloc0(sizeof(struct omap_mmc_s)); VAR_6->VAR_3 = VAR_3; VAR_6->VAR_4 = VAR_4; VAR_6->VAR_5 = VAR_5; VAR_6->lines = 1; VAR_6->rev = 1; omap_mmc_reset(VAR_6); memory_region_init_io(&VAR_6->iomem, NULL, &omap_mmc_ops, VAR_6, "omap.mmc", 0x800); memory_region_add_subregion(VAR_1, VAR_0, &VAR_6->iomem); VAR_6->card = sd_init(VAR_2, false); if (VAR_6->card == NULL) { exit(1); } return VAR_6; }