There is no need for that so lets use ratelimiting.
Also add some extra information to be helpful.
Acked-by: Stefano Stabellini <[email protected]>
[v2: s/ld/zs on the printk]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
not_found:
spin_unlock_irqrestore(&io_tlb_lock, flags);
- dev_warn(hwdev, "swiotlb buffer is full\n");
+ if (printk_ratelimit())
+ dev_warn(hwdev, "swiotlb buffer is full (sz: %zd bytes)\n", size);
return SWIOTLB_MAP_ERROR;
found:
spin_unlock_irqrestore(&io_tlb_lock, flags);