There is no need for that so lets use ratelimiting. Also add some extra information to be helpful.
Unified · Split
| @@ -505,7 +505,8 @@ phys_addr_t swiotlb_tbl_map_single(struct device *hwdev, · 504 unmodified lines | ||
| 505 | 505 | |
| 506 | 506 | not_found: |
| 507 | 507 | spin_unlock_irqrestore(&io_tlb_lock, flags); |
| 508 | − dev_warn(hwdev, "swiotlb buffer is full\n"); | |
| 508 | + if (printk_ratelimit()) | |
| 509 | + dev_warn(hwdev, "swiotlb buffer is full (sz: %zd bytes)\n", size); | |
| 509 | 510 | return SWIOTLB_MAP_ERROR; |
| 510 | 511 | found: |
| 511 | 512 | spin_unlock_irqrestore(&io_tlb_lock, flags); |