[PATCH] nvme/pci: Print invalid SGL only once

Christoph Hellwig hch at lst.de
Fri Sep 15 07:55:53 PDT 2017


On Thu, Sep 14, 2017 at 03:06:14PM -0400, Keith Busch wrote:
> The WARN_ONCE macro returns true if the condition is true, not if the
> warn was raised, so we're printing the scatter list every time it's
> invalid. This is excessive and makes debugging harder, so this patch
> prints it just once.

Please use the printk_ratelimited() helper instead.



More information about the Linux-nvme mailing list