8f2535d numa_conf: Introduce virDomainNumaGetMaxCPUID

Authored and Committed by mprivozn 8 years ago
    numa_conf: Introduce virDomainNumaGetMaxCPUID
    
    This function should return the greatest CPU number set in
    /domain/cpu/numa/cell/@cpus. The idea is that we should compare
    the returned value against /domain/vcpu value. Yes, there exist
    users who think the following is a good idea:
    
      <vcpu placement='static'>4</vcpu>
      <cpu mode='host-model'>
        <model fallback='allow'/>
        <numa>
          <cell id='0' cpus='0-1' memory='1048576' unit='KiB'/>
          <cell id='1' cpus='9-10' memory='2097152' unit='KiB'/>
        </numa>
      </cpu>
    
    Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
    
        
file modified
+17 -0
file modified
+3 -0
file modified
+1 -0