static void virtio_setup(void)

{

    struct irb irb;

    int i;

    int r;

    bool found = false;



    blk_schid.one = 1;



    for (i = 0; i < 0x10000; i++) {

        blk_schid.sch_no = i;

        r = tsch(blk_schid, &irb);

        if (r != 3) {

            if (virtio_is_blk(blk_schid)) {

                found = true;

                break;

            }

        }

    }



    if (!found) {

        virtio_panic("No virtio-blk device found!\n");

    }



    virtio_setup_block(blk_schid);

}

static void virtio_setup(void)

{

    struct irb irb;

    int i;

    int r;

    bool found = false;



    blk_schid.one = 1;



    for (i = 0; i < 0x10000; i++) {

        blk_schid.sch_no = i;

        r = tsch(blk_schid, &irb);

        if (r != 3) {

            if (virtio_is_blk(blk_schid)) {

                found = true;

                break;

            }

        }

    }



    if (!found) {

        virtio_panic("No virtio-blk device found!\n");

    }



    virtio_setup_block(blk_schid);

}

static void FUNC_0(void)

{

    struct VAR_0 VAR_0;

    int VAR_1;

    int VAR_2;

    bool found = false;



    blk_schid.one = 1;



    for (VAR_1 = 0; VAR_1 < 0x10000; VAR_1++) {

        blk_schid.sch_no = VAR_1;

        VAR_2 = tsch(blk_schid, &VAR_0);

        if (VAR_2 != 3) {

            if (virtio_is_blk(blk_schid)) {

                found = true;

                break;

            }

        }

    }



    if (!found) {

        virtio_panic("No virtio-blk device found!\n");

    }



    virtio_setup_block(blk_schid);

}

static void FUNC_0(void)
{ struct VAR_0 VAR_0; int VAR_1; int VAR_2; bool found = false; blk_schid.one = 1; for (VAR_1 = 0; VAR_1 < 0x10000; VAR_1++) { blk_schid.sch_no = VAR_1; VAR_2 = tsch(blk_schid, &VAR_0); if (VAR_2 != 3) { if (virtio_is_blk(blk_schid)) { found = true; break; } } } if (!found) { virtio_panic("No virtio-blk device found!\n"); } virtio_setup_block(blk_schid); }