Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755576AbaF3QWf (ORCPT ); Mon, 30 Jun 2014 12:22:35 -0400 Received: from mail-qc0-f173.google.com ([209.85.216.173]:38825 "EHLO mail-qc0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754147AbaF3QWc (ORCPT ); Mon, 30 Jun 2014 12:22:32 -0400 MIME-Version: 1.0 In-Reply-To: <1404144980.6148.6.camel@hobbes> References: <1402592317-7043-1-git-send-email-jaswinder.singh@linaro.org> <1404144980.6148.6.camel@hobbes> Date: Mon, 30 Jun 2014 21:52:27 +0530 Message-ID: Subject: Re: [PATCHv7 0/5] Common Mailbox Framework From: Jassi Brar To: Lubomir Rintel Cc: lkml , Devicetree List , Matt Porter , Patch Tracking , Bjorn Andersson , Ashwin Chaugule , Greg Kroah-Hartman , "Anna, Suman" , Loic Pallardy , LeyFoon Tan , Craig McGeachie , Courtney Cavin , pa@jasper.es Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 30 June 2014 21:46, Lubomir Rintel wrote: > Hi Jassi, > > On Thu, 2014-06-12 at 22:28 +0530, Jassi Brar wrote: >> Hello, >> Here is the next revision of Mailbox framwork. > > I'm wondering whether you keep a Git tree with the framework we could > keep the Raspberry Pi mailbox driver based on (bcm2835-mbox)? > > Also, from look at the API it does not seem to me that it's possible to > synchronously (that is without a tx_done callback) collect a response > when a message is sent with tx_block enabled. Equivalent to this: [1] > Thanks, good catch. Could you please give this a try... diff --git a/drivers/mailbox/mailbox.c b/drivers/mailbox/mailbox.c index afa63cd..4059602 100644 --- a/drivers/mailbox/mailbox.c +++ b/drivers/mailbox/mailbox.c @@ -101,10 +101,11 @@ static void tx_tick(struct mbox_chan *chan, int r) _msg_submit(chan); /* Notify the client */ + if (mssg && chan->cl->tx_done) + chan->cl->tx_done(chan->cl, mssg, r); + if (chan->cl->tx_block) complete(&chan->tx_complete); - else if (mssg && chan->cl->tx_done) - chan->cl->tx_done(chan->cl, mssg, r); } static void poll_txdone(unsigned long data) -jassi -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/