meth: pass struct device to DMA API functions
authorChristoph Hellwig <hch@lst.de>
Mon, 11 Feb 2019 13:20:03 +0000 (14:20 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 12 Feb 2019 17:09:24 +0000 (12:09 -0500)
commit8d4c28fbc284bf2dee08afff146def47cafbc227
treec47ea54dbbb93f0046da2476e9e6d5cfc91f6d1d
parent5dac33ad6f0d1dbc20736fa13d833250e7f12a26
meth: pass struct device to DMA API functions

The DMA API generally relies on a struct device to work properly, and
only barely works without one for legacy reasons.  Pass the easily
available struct device from the platform_device to remedy this.

Also use GFP_KERNEL instead of GFP_ATOMIC as the gfp_t for the memory
allocation, as we aren't in interrupt context or under a lock.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sgi/meth.c