>From 148b8adc207e8726895b1b0d84311a3e5ece3dc0 Mon Sep 17 00:00:00 2001 From: Fernando Guzman Lugo <x0095840@xxxxxx> Date: Wed, 27 Jan 2010 20:04:02 -0600 Subject: [PATCH] Mailbox: Check valid registered callback before calling This patch checks if the mailbox user has assinged a valid callback fuction before calling it. Signed-off-by: Fernando Guzman Lugo <x0095840@xxxxxx> --- arch/arm/plat-omap/mailbox.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/arch/arm/plat-omap/mailbox.c b/arch/arm/plat-omap/mailbox.c index 3e2f961..8136ee3 100644 --- a/arch/arm/plat-omap/mailbox.c +++ b/arch/arm/plat-omap/mailbox.c @@ -144,7 +144,8 @@ static void mbox_rx_work(struct work_struct *work) msg = (mbox_msg_t)rq->special; blk_end_request_all(rq, 0); - mbox->rxq->callback((void *)msg); + if (mbox->rxq->callback) + mbox->rxq->callback((void *)msg); } } -- 1.6.0.4 -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html