We already check 'len' above to make sure it already isn't
negative here, so indeed, (addr + len < addr) should never be happened.

Signed-off-by: Tiejun Chen <[email protected]>
---
 virt/kvm/coalesced_mmio.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/virt/kvm/coalesced_mmio.c b/virt/kvm/coalesced_mmio.c
index 00d8642..60f59cd 100644
--- a/virt/kvm/coalesced_mmio.c
+++ b/virt/kvm/coalesced_mmio.c
@@ -30,8 +30,6 @@ static int coalesced_mmio_in_range(struct 
kvm_coalesced_mmio_dev *dev,
         */
        if (len < 0)
                return 0;
-       if (addr + len < addr)
-               return 0;
        if (addr < dev->zone.addr)
                return 0;
        if (addr + len > dev->zone.addr + dev->zone.size)
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to