usb: gadget: mv_udc: avoid sleeping on spinlock
build_dtd() can be called when hold a spinlock, but GFP_KERNEL may cause dma_pool_alloc() sleep, So we need use GFP_ATOMIC instead of GFP_KERNEL. But using GFP_ATOMIC may cause failure when allocating memory, add error handler to handle it. Signed-off-by: NAlexey Khoroshilov <khoroshilov@ispras.ru> Signed-off-by: NNeil Zhang <zhangwm@marvell.com> Signed-off-by: NFelipe Balbi <balbi@ti.com>
Showing
想要评论请 注册 或 登录