usb: renesas_usbhs: fix NULL pointer dereference in dma_release_channel()
usb: renesas_usbhs: fix NULL pointer dereference in dma_release_channel()

This patch fixes an issue that the following commit causes NULL
pointer dereference in dma_release_channel().
 "usb: renesas_usbhs: add support for requesting DT DMA"
 (commit id abd2dbf6bb1b5f3a03a8c76b1a8879da1dd30caa)

The usbhsf_dma_init_dt() should set fifo->{t,r}x_chan to NULL if
dma_request_slave_channel_reason() returns IS_ERR value.
Otherwise, usbhsf_dma_quit() will call dma_release_channel(), and then
NULL pointer dereference happens.

Acked-by: Geert Uytterhoeven <0da414d9d963da4039c2a0525b1844228075aa58@linux-m68k.org>
Tested-by: Simon Horman <9662bddcc379be37df16f02a449c344b4718c1a1@verge.net.au>
Reported-by: Simon Horman <a105fd58f578dea0be108941d4c59d15396e1855@verge.net.au>
Signed-off-by: Yoshihiro Shimoda <de6fb888308c49c20838826baf4e7cc406af80ff@renesas.com>
Signed-off-by: Felipe Balbi <94dddeeef08b001e003cce128ddc162a4e2c6cd2@ti.com>

KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs