1. 03 6月, 2020 8 次提交
  2. 02 6月, 2020 5 次提交
  3. 01 6月, 2020 1 次提交
  4. 30 5月, 2020 1 次提交
  5. 28 5月, 2020 1 次提交
  6. 27 5月, 2020 1 次提交
    • C
      security: don't fail if built without attr support · 55029d93
      Christian Ehrhardt 提交于
      If built without attr support removing any image will trigger
       qemuBlockRemoveImageMetadata (the one that emits the warning)
         -> qemuSecurityMoveImageMetadata
           -> virSecurityManagerMoveImageMetadata
             -> virSecurityDACMoveImageMetadata
               -> virSecurityDACMoveImageMetadataHelper
                 -> virProcessRunInFork (spawns subprocess)
                   -> virSecurityMoveRememberedLabel
      
      In there due to !HAVE_LIBATTR virFileGetXAttrQuiet will return
      ENOSYS and from there the chain will error out.
      
      That is wrong and looks like:
        libvirtd[6320]: internal error: child reported (status=125):
        libvirtd[6320]: Unable to remove disk metadata on vm testguest from
        /var/lib/uvtool/libvirt/images/testguest.qcow (disk target vda)
      
      This change makes virSecurityDACMoveImageMetadataHelper and
      virSecuritySELinuxMoveImageMetadataHelper accept that
      error code gracefully and in that sense it is an extension of:
      5214b2f1 "security: Don't skip label restore on file systems lacking XATTRs"
      which does the same for other call chains into the virFile*XAttr functions.
      Signed-off-by: NChristian Ehrhardt <christian.ehrhardt@canonical.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      55029d93
  7. 26 5月, 2020 8 次提交
  8. 25 5月, 2020 11 次提交
  9. 22 5月, 2020 4 次提交
    • H
      docs: Fix a typo in formatdomain.html · f7187094
      Han Han 提交于
      Signed-off-by: NHan Han <hhan@redhat.com>
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      f7187094
    • D
      scripts: emit raw enum value in API build description · 61fdc967
      Daniel P. Berrangé 提交于
      Currently the value for an enum is only emitted if it is a plain
      string. If the enum is an integer or hex value, or a complex code block,
      it is omitted from the API build. This fixes that by emitting the raw
      value if no string value is present.
      
      With this change:
      
        <macro name='LIBVIR_CHECK_VERSION'
               file='libvirt-common'
               params='major,minor,micro'>
        <macro name='LIBVIR_VERSION_NUMBER'
               file='libvirt-common'>
        <macro name='VIR_COPY_CPUMAP'
               file='libvirt-domain'
               params='cpumaps,maplen,vcpu,cpumap'>
        ...snip...
      
        <macro name='LIBVIR_CHECK_VERSION'
               file='libvirt-common'
               params='major,minor,micro'
               raw='((major) * 1000000 + (minor) * 1000 + (micro) <= LIBVIR_VERSION_NUMBER)'>
        <macro name='LIBVIR_VERSION_NUMBER'
               file='libvirt-common'
               raw='6004000'>
        <macro name='VIR_COPY_CPUMAP'
               file='libvirt-domain'
               params='cpumaps,maplen,vcpu,cpumap'
               raw='memcpy(cpumap, VIR_GET_CPUMAP(cpumaps, maplen, vcpu), maplen)'>
        ...snip...
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      61fdc967
    • D
      scripts: emit enum parameters in API build description · 38f3fa61
      Daniel P. Berrangé 提交于
      Currently the information about enums in the API document lacks any
      mention of parameters, so it is impossible to tell what kind of enum
      declaration is present in the libvirt API header. With this change
      
        <macro name='LIBVIR_CHECK_VERSION' file='libvirt-common'>
        <macro name='VIR_COPY_CPUMAP' file='libvirt-domain'>
        ...snip...
      
      becomes
      
        <macro name='LIBVIR_CHECK_VERSION' file='libvirt-common' params='major,minor,micro'>
        <macro name='VIR_COPY_CPUMAP' file='libvirt-domain' params='cpumaps,maplen,vcpu,cpumap'>
        ...snip...
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      38f3fa61
    • D
      scripts: fix tokenizing of enum parameters in API builder · 34204f99
      Daniel P. Berrangé 提交于
      The API build script tokenizes enums declarations by first splitting on
      whitespace. This is unhelpful as it means an enum
      
       # define VIR_USE_CPU(cpumap, cpu) ((cpumap)[(cpu) / 8] |= (1 << ((cpu) % 8)))
      
      Gets tokenized as
      
        #define
        VIR_USE_CPU(cpumap,
        cpu)
        ((cpumap)[(cpu)
        /
        8]
        |=
        (1
        <<
        ((cpu)
        %
        8)))
      
      With this change, the set of parameters are all merged into the first
      token:
      
        #define
        VIR_USE_CPU(cpumap,cpu)
        ((cpumap)[(cpu)
        /
        8]
        |=
        (1
        <<
        ((cpu)
        %
        8)))
      
      which is more convenient to process later on in the script.
      Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      34204f99