USB: fix usbmon and DMA mapping for scatter-gather URBs
[firefly-linux-kernel-4.4.55.git] / drivers / usb / mon / mon_text.c
index 4d0be130f49b5282af7b70654b94ead4e0cf2e9b..d56260280f54e38724a086643158d9dceb715b4f 100644 (file)
@@ -161,9 +161,7 @@ static inline char mon_text_get_data(struct mon_event_text *ep, struct urb *urb,
        } else {
                struct scatterlist *sg = urb->sg->sg;
 
-               /* If IOMMU coalescing occurred, we cannot trust sg_page */
-               if (urb->sg->nents != urb->num_sgs ||
-                               PageHighMem(sg_page(sg)))
+               if (PageHighMem(sg_page(sg)))
                        return 'D';
 
                /* For the text interface we copy only the first sg buffer */