We see the following when building arm kernel:
arch/arm/mm/dma-mapping.c:738:52: warning: Using plain integer as NULL
pointer
The function starts with:
static void *__dma_alloc(struct device *dev, size_t size, dma_addr_t
*handle,
gfp_t gfp, pgprot_t prot, bool is_coherent,
unsigned long attrs, const void *caller)
{
u64 mask = get_coherent_dma_mask(dev);
struct page *page = NULL;
void *addr;
bool allowblock, cma;
The line at 738 is:
cma = allowblock ? dev_get_cma_area(dev) : false;
Which looks fine, dev_get_cma_area() takes a "struct device *" so not
sure where sparse can be finding an integer, as cma and allowblock are
both "bool" types.
--
Ben Dooks http://www.codethink.co.uk/
Senior Engineer Codethink - Providing Genius
https://www.codethink.co.uk/privacy.html