package qcow

  1. Overview
  2. Docs
type t = {
  1. l1_index : int64;
  2. l2_index : int64;
  3. cluster : int64;
}

A virtual address in a qcow image is broken into 3 levels:

  • an index in the L1 table, pointing to
  • an index in the L2 table, pointing to
  • a cluster within which we need an offset
include Sexplib0.Sexpable.S with type t := t
val t_of_sexp : Sexplib0__.Sexp.t -> t
val sexp_of_t : t -> Sexplib0__.Sexp.t
val make : cluster_bits:int -> int64 -> t

make cluster_bits byte computes the address within the file of the virtual byte offset

val to_offset : cluster_bits:int -> t -> int64

to_offset cluster_bits address computes the virtual byte offset of the virtual address

include Qcow_s.PRINTABLE with type t := t
val to_string : t -> string

Produce a pretty human-readable string from a value

OCaml

Innovation. Community. Security.