aboutsummaryrefslogtreecommitdiff
path: root/kernel/dma/debug.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2024-09-12 12:38:44 +0100
committerMark Brown <broonie@kernel.org>2024-09-12 12:38:44 +0100
commitf10d52087cbe85dcff2af3dc94c5b9d06e6d4b9a (patch)
treed07ff0a3767fbb6118505de85ad657f78f512c06 /kernel/dma/debug.c
parent740c1c84bfa3d8c63bd3b01fb570e7452f51fbd8 (diff)
parentb787a33864121a565aeb0e88561bf6062a19f99c (diff)
spi: Merge up fixes
A patch for Qualcomm depends on some fixes.
Diffstat (limited to 'kernel/dma/debug.c')
-rw-r--r--kernel/dma/debug.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/dma/debug.c b/kernel/dma/debug.c
index a6e3792b15f8..d570535342cb 100644
--- a/kernel/dma/debug.c
+++ b/kernel/dma/debug.c
@@ -416,8 +416,11 @@ static unsigned long long phys_addr(struct dma_debug_entry *entry)
* dma_active_cacheline entry to track per event. dma_map_sg(), on the
* other hand, consumes a single dma_debug_entry, but inserts 'nents'
* entries into the tree.
+ *
+ * Use __GFP_NOWARN because the printk from an OOM, to netconsole, could end
+ * up right back in the DMA debugging code, leading to a deadlock.
*/
-static RADIX_TREE(dma_active_cacheline, GFP_ATOMIC);
+static RADIX_TREE(dma_active_cacheline, GFP_ATOMIC | __GFP_NOWARN);
static DEFINE_SPINLOCK(radix_lock);
#define ACTIVE_CACHELINE_MAX_OVERLAP ((1 << RADIX_TREE_MAX_TAGS) - 1)
#define CACHELINE_PER_PAGE_SHIFT (PAGE_SHIFT - L1_CACHE_SHIFT)