From 9bb83e8fe252f15ad30430e80eb7f9da66cacbb9 Mon Sep 17 00:00:00 2001 From: Thomas Gleixner Date: Tue, 13 Oct 2020 16:26:17 +0200 Subject: media: Bulk remove BUG_ON(in_interrupt()) None of these BUG_ON()'s is justified. BUG_ON() should only be used when there is really no way to survive. If at all these could be replaced by lockdep_assert_preemption_enabled() to cover all invalid caller context and not just those covered by in_interrupt(). But all functions which are invoked from those places contain already debug mechanisms to catch wrong context, so having these extra checks is not having any advantage. Signed-off-by: Thomas Gleixner Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- drivers/media/pci/cx25821/cx25821-core.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers/media/pci/cx25821/cx25821-core.c') diff --git a/drivers/media/pci/cx25821/cx25821-core.c b/drivers/media/pci/cx25821/cx25821-core.c index 55018d9e439f..6f8ffab8840f 100644 --- a/drivers/media/pci/cx25821/cx25821-core.c +++ b/drivers/media/pci/cx25821/cx25821-core.c @@ -1198,7 +1198,6 @@ EXPORT_SYMBOL(cx25821_risc_databuffer_audio); void cx25821_free_buffer(struct cx25821_dev *dev, struct cx25821_buffer *buf) { - BUG_ON(in_interrupt()); if (WARN_ON(buf->risc.size == 0)) return; pci_free_consistent(dev->pci, -- cgit v1.2.3