Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8d64f42a authored by Liam Mark's avatar Liam Mark Committed by Patrick Daly
Browse files

arm64: mm: dma: panic on dummy dma alloc



On the 4.4 kernel non platform devices now have to call
arch_setup_dma_ops to setup their dma ops otherwise the
dummy dma opts will be used.
This because of change the following change:
1dccb598 arm64: simplify dma_get_ops

Introduce a panic if a the dummy dma alloc is used to
help clients more easily identify why their dma allocations
are failing.

This patch can later be reverted once all non platform devices
have fixed their code.

Change-Id: I2dd7eb0694c8c403da21133601eb7e831ead2dfd
Signed-off-by: default avatarLiam Mark <lmark@codeaurora.org>
Signed-off-by: default avatarPatrick Daly <pdaly@codeaurora.org>
parent 36e8282d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -554,6 +554,7 @@ static void *__dummy_alloc(struct device *dev, size_t size,
			   dma_addr_t *dma_handle, gfp_t flags,
			   unsigned long attrs)
{
	WARN(1, "dma alloc failure, device may be missing a call to arch_setup_dma_ops");
	return NULL;
}