static block_number_t eckd_block_num(BootMapPointer *p)

{

    const uint64_t sectors = virtio_get_sectors();

    const uint64_t heads = virtio_get_heads();

    const uint64_t cylinder = p->eckd.cylinder

                            + ((p->eckd.head & 0xfff0) << 12);

    const uint64_t head = p->eckd.head & 0x000f;

    const block_number_t block = sectors * heads * cylinder

                               + sectors * head

                               + p->eckd.sector

                               - 1; /* block nr starts with zero */

    return block;

}

static block_number_t eckd_block_num(BootMapPointer *p)

{

    const uint64_t sectors = virtio_get_sectors();

    const uint64_t heads = virtio_get_heads();

    const uint64_t cylinder = p->eckd.cylinder

                            + ((p->eckd.head & 0xfff0) << 12);

    const uint64_t head = p->eckd.head & 0x000f;

    const block_number_t block = sectors * heads * cylinder

                               + sectors * head

                               + p->eckd.sector

                               - 1; 

    return block;

}

static block_number_t FUNC_0(BootMapPointer *p)

{

    const uint64_t VAR_0 = virtio_get_sectors();

    const uint64_t VAR_1 = virtio_get_heads();

    const uint64_t VAR_2 = p->eckd.VAR_2

                            + ((p->eckd.VAR_3 & 0xfff0) << 12);

    const uint64_t VAR_3 = p->eckd.VAR_3 & 0x000f;

    const block_number_t VAR_4 = VAR_0 * VAR_1 * VAR_2

                               + VAR_0 * VAR_3

                               + p->eckd.sector

                               - 1; 

    return VAR_4;

}

static block_number_t FUNC_0(BootMapPointer *p)
{ const uint64_t VAR_0 = virtio_get_sectors(); const uint64_t VAR_1 = virtio_get_heads(); const uint64_t VAR_2 = p->eckd.VAR_2
+ ((p->eckd.VAR_3 & 0xfff0) << 12); const uint64_t VAR_3 = p->eckd.VAR_3 & 0x000f; const block_number_t VAR_4 = VAR_0 * VAR_1 * VAR_2
+ VAR_0 * VAR_3
+ p->eckd.sector
- 1; return VAR_4; }