From patchwork Tue Sep 22 14:32:43 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "C.A, Subramaniam" X-Patchwork-Id: 49315 X-Patchwork-Delegate: tony@atomide.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n8MEX72o028058 for ; Tue, 22 Sep 2009 14:33:07 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756670AbZIVOcn (ORCPT ); Tue, 22 Sep 2009 10:32:43 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756659AbZIVOcn (ORCPT ); Tue, 22 Sep 2009 10:32:43 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:39803 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756656AbZIVOcm convert rfc822-to-8bit (ORCPT ); Tue, 22 Sep 2009 10:32:42 -0400 Received: from dbdp20.itg.ti.com ([172.24.170.38]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id n8MEWaob023580; Tue, 22 Sep 2009 09:32:37 -0500 Received: from dbde70.ent.ti.com (localhost [127.0.0.1]) by dbdp20.itg.ti.com (8.13.8/8.13.8) with ESMTP id n8MEWZYb028776; Tue, 22 Sep 2009 20:02:35 +0530 (IST) Received: from dbde02.ent.ti.com ([172.24.170.145]) by dbde70.ent.ti.com ([172.24.170.148]) with mapi; Tue, 22 Sep 2009 20:02:35 +0530 From: "C.A, Subramaniam" To: "linux-omap@vger.kernel.org" CC: "tony@atomide.com" , "rmk@arm.linux.org.uk" , Hiroshi DOYU , "Kanigeri, Hari" , "Gupta, Ramesh" Date: Tue, 22 Sep 2009 20:02:43 +0530 Subject: [PATCH 7/10] omap mailbox: expose omap_mbox_enable()/disable_irq() Thread-Topic: [PATCH 7/10] omap mailbox: expose omap_mbox_enable()/disable_irq() Thread-Index: Aco7kYulsQUyjXocRcq7qmhf9mJ3eQ== Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org From 1ba55e567917b48afc64a14202fd860b3332056d Mon Sep 17 00:00:00 2001 From: Hiroshi DOYU Date: Wed, 2 Sep 2009 20:18:53 +0530 Subject: [PATCH 7/10] omap mailbox: expose omap_mbox_enable()/disable_irq() Signed-off-by: Hiroshi DOYU --- arch/arm/plat-omap/include/mach/mailbox.h | 12 ++++++++++++ arch/arm/plat-omap/mailbox.c | 12 ++---------- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/arch/arm/plat-omap/include/mach/mailbox.h b/arch/arm/plat-omap/include/mach/mailbox.h index 8260a3f..bf06953 100644 --- a/arch/arm/plat-omap/include/mach/mailbox.h +++ b/arch/arm/plat-omap/include/mach/mailbox.h @@ -92,4 +92,16 @@ static inline void omap_mbox_restore_ctx(struct omap_mbox *mbox) mbox->ops->restore_ctx(mbox); } +static inline void omap_mbox_enable_irq(struct omap_mbox *mbox, + omap_mbox_irq_t irq) +{ + mbox->ops->enable_irq(mbox, irq); +} + +static inline void omap_mbox_disable_irq(struct omap_mbox *mbox, + omap_mbox_irq_t irq) +{ + mbox->ops->disable_irq(mbox, irq); +} + #endif /* MAILBOX_H */ diff --git a/arch/arm/plat-omap/mailbox.c b/arch/arm/plat-omap/mailbox.c index 2899255..032f1fe 100644 --- a/arch/arm/plat-omap/mailbox.c +++ b/arch/arm/plat-omap/mailbox.c @@ -50,14 +50,6 @@ static inline int mbox_fifo_full(struct omap_mbox *mbox) } /* Mailbox IRQ handle functions */ -static inline void enable_mbox_irq(struct omap_mbox *mbox, omap_mbox_irq_t irq) -{ - mbox->ops->enable_irq(mbox, irq); -} -static inline void disable_mbox_irq(struct omap_mbox *mbox, omap_mbox_irq_t irq) -{ - mbox->ops->disable_irq(mbox, irq); -} static inline void ack_mbox_irq(struct omap_mbox *mbox, omap_mbox_irq_t irq) { if (mbox->ops->ack_irq) @@ -144,7 +136,7 @@ static void mbox_tx_work(struct work_struct *work) ret = __mbox_msg_send(mbox, tx_data->msg); if (ret) { - enable_mbox_irq(mbox, IRQ_TX); + omap_mbox_enable_irq(mbox, IRQ_TX); spin_lock(q->queue_lock); blk_requeue_request(q, rq); spin_unlock(q->queue_lock); @@ -196,7 +188,7 @@ static void mbox_rxq_fn(struct request_queue *q) static void __mbox_tx_interrupt(struct omap_mbox *mbox) { - disable_mbox_irq(mbox, IRQ_TX); + omap_mbox_disable_irq(mbox, IRQ_TX); ack_mbox_irq(mbox, IRQ_TX); schedule_work(&mbox->txq->work); }