]> git.proxmox.com Git - pve-qemu-kvm.git/blobdiff - debian/patches/fairsched.diff
update to v2.1.0-rc2
[pve-qemu-kvm.git] / debian / patches / fairsched.diff
index 796696daaabead44eb2e1a21110002cfc36ab84e..502038af0ddf4b06469599f657fe326a152144ef 100644 (file)
@@ -1,9 +1,9 @@
 Index: new/qemu-options.hx
 ===================================================================
---- new.orig/qemu-options.hx   2012-03-12 06:44:56.000000000 +0100
-+++ new/qemu-options.hx        2012-03-13 07:25:22.000000000 +0100
-@@ -95,6 +95,12 @@
- are split equally.
+--- new.orig/qemu-options.hx   2014-07-16 09:54:13.000000000 +0200
++++ new/qemu-options.hx        2014-07-16 09:55:58.000000000 +0200
+@@ -379,6 +379,12 @@
+ @table @option
  ETEXI
  
 +DEF("id", HAS_ARG, QEMU_OPTION_id,
@@ -17,49 +17,43 @@ Index: new/qemu-options.hx
  DEF("fdb", HAS_ARG, QEMU_OPTION_fdb, "", QEMU_ARCH_ALL)
 Index: new/vl.c
 ===================================================================
---- new.orig/vl.c      2012-03-12 06:44:56.000000000 +0100
-+++ new/vl.c   2012-03-13 07:25:22.000000000 +0100
-@@ -153,6 +153,8 @@
- #include "fsdev/qemu-fsdev.h"
+--- new.orig/vl.c      2014-07-16 09:54:13.000000000 +0200
++++ new/vl.c   2014-07-16 10:01:14.000000000 +0200
+@@ -101,6 +101,8 @@
  #endif
+ #include "sysemu/qtest.h"
  
 +#include "vzsyscalls.h"
 +
- #include "disas.h"
+ #include "disas/disas.h"
  
- #include "qemu_socket.h"
-@@ -203,6 +205,7 @@
+@@ -153,6 +155,7 @@
+ CharDriverState *sclp_hds[MAX_SCLP_CONSOLES];
  int win2k_install_hack = 0;
- int usb_enabled = 0;
  int singlestep = 0;
 +int fairsched_id = 0;
  int smp_cpus = 1;
  int max_cpus = 0;
  int smp_cores = 1;
-@@ -2045,7 +2048,7 @@
- }
- static int debugcon_parse(const char *devname)
--{   
-+{
-     QemuOpts *opts;
-     if (!qemu_chr_new("debugcon", devname, NULL)) {
-@@ -2258,6 +2261,7 @@
+@@ -2897,6 +2900,9 @@
  int main(int argc, char **argv, char **envp)
  {
      int i;
 +    int cpuunits = 0;
++    long int fairsched_id_long = 0;
++    char *ep;
      int snapshot, linux_boot;
      const char *icount_option = NULL;
      const char *initrd_filename;
-@@ -3022,6 +3026,20 @@
+@@ -3717,6 +3723,21 @@
                      exit(1);
                  }
                  break;
 +            case QEMU_OPTION_id:
-+                fairsched_id = atoi(optarg);
-+              if (fairsched_id < 100 || fairsched_id >= 1000000) {
++                fairsched_id_long = strtol(optarg, &ep, 10);
++                fairsched_id = fairsched_id_long;
++              if (*ep != 0 || fairsched_id_long < 100 || fairsched_id_long > INT_MAX) {
 +                  fprintf(stderr, "Invalid ID\n");
 +                  exit(1);
 +              }
@@ -74,24 +68,14 @@ Index: new/vl.c
            case QEMU_OPTION_vnc:
  #ifdef CONFIG_VNC
                  display_remote++;
-@@ -3093,8 +3111,8 @@
-                       }
-                       p += 8;
-                       os_set_proc_name(p);
--                   }  
--               }      
-+                   }
-+               }
-                 break;
-             case QEMU_OPTION_prom_env:
-                 if (nb_prom_envs >= MAX_PROM_ENVS) {
-@@ -3411,6 +3429,39 @@
-         }
-     }
+@@ -3992,6 +4013,40 @@
+                           OBJECT_CLASS(machine_class))));
+     object_property_add_child(object_get_root(), "machine",
+                               OBJECT(current_machine), &error_abort);
++
 +    if (cpuunits && !fairsched_id) {
-+      fprintf(stderr, "cpuunits specified without -id");
-+      exit (1);
++        fprintf(stderr, "cpuunits specified without -id");
++        exit(1);
 +    }
 +
 +    if (fairsched_id && cpuunits) {
@@ -124,11 +108,11 @@ Index: new/vl.c
 +
      cpu_exec_init_all();
  
-     bdrv_init_with_whitelist();
+     if (machine_class->hw_version) {
 Index: new/vzsyscalls.h
 ===================================================================
 --- /dev/null  1970-01-01 00:00:00.000000000 +0000
-+++ new/vzsyscalls.h   2012-03-13 07:25:22.000000000 +0100
++++ new/vzsyscalls.h   2014-07-16 09:55:58.000000000 +0200
 @@ -0,0 +1,47 @@
 +/*
 + *  Copyright (C) 2000-2008, Parallels, Inc. All rights reserved.