Messages in this thread | | | From | Jassi Brar <> | Date | Tue, 15 Dec 2020 15:20:54 -0600 | Subject | Re: [PATCH] add chan->cl check in mbox_chan_received_data() |
| |
On Tue, Dec 15, 2020 at 2:48 AM Haidong Yao <yaohaidong369@gmail.com> wrote:
> --- a/drivers/mailbox/mailbox.c > +++ b/drivers/mailbox/mailbox.c > @@ -152,7 +152,7 @@ static enum hrtimer_restart txdone_hrtimer(struct hrtimer *hrtimer) > void mbox_chan_received_data(struct mbox_chan *chan, void *mssg) > { > /* No buffering the received data */ > - if (chan->cl->rx_callback) > + if (chan->cl && chan->cl->rx_callback) > chan->cl->rx_callback(chan->cl, mssg); > } The proper fix is in the controller driver. Which should stop tx/rx when the channel is freed.
thnx.
| |