qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Potential Bug in vIOMMU which may result in memory wast


From: no-reply
Subject: Re: [Qemu-devel] Potential Bug in vIOMMU which may result in memory wasting
Date: Tue, 11 Oct 2016 17:56:07 -0700 (PDT)

Hi,

Your series seems to have some coding style problems. See output below for
more information:

Message-id: address@hidden
Subject: [Qemu-devel] Potential Bug in vIOMMU which may result in memory wasting
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash

BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0

# Useful git options
git config --local diff.renamelimit 0
git config --local diff.renames True

commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
    echo "Checking PATCH $n/$total: $(git show --no-patch --format=%s $c)..."
    if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
        failed=1
        echo
    fi
    n=$((n+1))
done

exit $failed
=== TEST SCRIPT END ===

Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
Switched to a new branch 'test'
21c104d Potential Bug in vIOMMU which may result in memory wasting

=== OUTPUT BEGIN ===
Checking PATCH 1/1: Potential Bug in vIOMMU which may result in memory 
wasting...
ERROR: do not use C99 // comments
#166: FILE: hw/i386/intel_iommu.c:1990:
+       // exit(1);//Yi: comment out for test purpose

ERROR: do not use C99 // comments
#174: FILE: hw/i386/intel_iommu.c:2325:
+    //Yi: add for debug

ERROR: __func__ should be used instead of gcc specific __FUNCTION__
#181: FILE: hw/i386/intel_iommu.c:2332:
+                    __FUNCTION__,

ERROR: do not use C99 // comments
#210: FILE: hw/i386/intel_iommu.c:2373:
+      //Yi: code snippet for debug, dump the vtd_as_by_buspt

ERROR: do not use C99 // comments
#211: FILE: hw/i386/intel_iommu.c:2374:
+      // r to see if all the allocated vtd_bus are still there

ERROR: suspect code indent for conditional statements (6, 9)
#214: FILE: hw/i386/intel_iommu.c:2377:
+      while (g_hash_table_iter_next (&iter, NULL, (void**)&vtd_bus)) {
+         if (pci_bus_num(vtd_bus->bus) == pci_bus_num(bus)) {

ERROR: "(foo**)" should be "(foo **)"
#214: FILE: hw/i386/intel_iommu.c:2377:
+      while (g_hash_table_iter_next (&iter, NULL, (void**)&vtd_bus)) {

ERROR: space prohibited between function name and open parenthesis '('
#214: FILE: hw/i386/intel_iommu.c:2377:
+      while (g_hash_table_iter_next (&iter, NULL, (void**)&vtd_bus)) {

ERROR: suspect code indent for conditional statements (9, 13)
#215: FILE: hw/i386/intel_iommu.c:2378:
+         if (pci_bus_num(vtd_bus->bus) == pci_bus_num(bus)) {
+             printf("  vtd_bus in s->vtd_as_by_busptr: 0x%llx\n",

ERROR: do not use C99 // comments
#220: FILE: hw/i386/intel_iommu.c:2383:
+      // look up hash table again see if the result is the same with the

ERROR: do not use C99 // comments
#221: FILE: hw/i386/intel_iommu.c:2384:
+     //  beginning one.

ERROR: do not use C99 // comments
#240: FILE: hw/pci/pcie.c:686:
+        //assert(prev >= PCI_CONFIG_SPACE_SIZE);

ERROR: do not use C99 // comments
#253: FILE: hw/vfio/common.c:460:
+        //memory_region_iommu_replay(giommu->iommu, &giommu->n, false);

total: 13 errors, 0 warnings, 83 lines checked

Your patch has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

=== OUTPUT END ===

Test command exited with code: 1


---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]