]> xenbits.xensource.com Git - xenclient/toolstack.git/commitdiff
xenvm: add videoram
authorVincent Hanquez <vincent.hanquez@eu.citrix.com>
Sat, 16 May 2009 14:31:09 +0000 (15:31 +0100)
committerVincent Hanquez <vincent.hanquez@eu.citrix.com>
Sat, 16 May 2009 14:31:09 +0000 (15:31 +0100)
xenvm/vmconfig.ml

index 8d93e8b1218e28121f6c7e2d52d91224eae13e08..693976ea098d202f8afe8bc73330219e908929dc 100644 (file)
@@ -85,6 +85,7 @@ type config = {
        acpi_pt: bool;
        diskinfo_pt: bool;
        viridian: bool;
+       videoram: int option;
        on_halt: action;
        on_restart: action;
        on_crash: action;
@@ -248,6 +249,7 @@ let get cfg field =
        | "acpi"      -> string_of_bool cfg.acpi
        | "nx"        -> string_of_bool cfg.nx
        | "viridian"  -> string_of_bool cfg.viridian
+       | "videoram"  -> string_of_int_option cfg.videoram
        | "smbios-pt" -> string_of_bool cfg.smbios_pt
        | "acpi-pt"   -> string_of_bool cfg.acpi_pt
        | "diskinfo-pt" -> string_of_bool cfg.diskinfo_pt
@@ -277,6 +279,7 @@ let set cfg field value =
        | "acpi"      -> { cfg with acpi = bool_of_string value }
        | "nx"        -> { cfg with nx = bool_of_string value }
        | "viridian"  -> { cfg with viridian = bool_of_string value }
+       | "videoram"  -> { cfg with videoram = int_option_of_string value }
        | "smbios-pt" -> { cfg with smbios_pt = bool_of_string value }
        | "acpi-pt"   -> { cfg with acpi_pt = bool_of_string value }
        | "diskinfo-pt" -> { cfg with diskinfo_pt = bool_of_string value }
@@ -311,6 +314,7 @@ let of_file error_report file =
        and acpi_pt = ref false
        and diskinfo_pt = ref false
        and viridian = ref false
+       and videoram = ref None
        and disks = ref []
        and nics = ref []
        and pcis = ref []
@@ -446,6 +450,7 @@ let of_file error_report file =
                ("acpi-pt", Config.Set_bool acpi_pt);
                ("diskinfo-pt", Config.Set_bool diskinfo_pt);
                ("viridian", Config.Set_bool viridian);
+               ("videoram", Config.Int (fun i -> videoram := Some i));
                ("debug", Config.Set_bool debug);
                ("no_mem_check", Config.Set_bool no_mem_check);
                ("output", Config.Set_string output);
@@ -557,6 +562,7 @@ let of_file error_report file =
                acpi_pt = !acpi_pt;
                diskinfo_pt = !diskinfo_pt;
                viridian = !viridian;
+               videoram = !videoram;
                on_halt = !on_halt;
                on_restart = !on_restart;
                on_crash = !on_crash;