public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* Git tree updated to 2.6.19-rc2
@ 2006-10-23 20:39 Tony Lindgren
  2006-10-24  7:53 ` Komal Shah
                   ` (3 more replies)
  0 siblings, 4 replies; 14+ messages in thread
From: Tony Lindgren @ 2006-10-23 20:39 UTC (permalink / raw)
  To: linux-omap-open-source

Hi all,

I've updated our git tree to 2.6.19-rc2. At least following have
problems on omap1 (OSK):

- CONFIG_DEBUG_LL hangs system
- BUG in omap1_mbox_enable_irq
- Aic23 NULL pointer exception

So YMMV :) Anybody got patches for these issues already?

Tony

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-23 20:39 Git tree updated to 2.6.19-rc2 Tony Lindgren
@ 2006-10-24  7:53 ` Komal Shah
  2006-10-28  6:31   ` Aic23 NULL pointer exception, was: " Dirk Behme
  2006-10-24 11:05 ` [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2) Jonathan McDowell
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 14+ messages in thread
From: Komal Shah @ 2006-10-24  7:53 UTC (permalink / raw)
  To: Tony Lindgren, linux-omap-open-source

--- Tony Lindgren <tony@atomide.com> wrote:

> Hi all,
> 
> I've updated our git tree to 2.6.19-rc2. At least following have
> problems on omap1 (OSK):
> 
..

> - Aic23 NULL pointer exception
> 

Anything related to as discussed on davinci mailing list for I2C?

http://linux.omap.com/pipermail/davinci-linux-open-source/2006-October/001312.html

If that is the case, then please try adding zero-length transaction and
SMBUS_QUICK code as temporary hack.

---Komal Shah
http://komalshah.blogspot.com/

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2)
  2006-10-23 20:39 Git tree updated to 2.6.19-rc2 Tony Lindgren
  2006-10-24  7:53 ` Komal Shah
@ 2006-10-24 11:05 ` Jonathan McDowell
  2006-10-24 17:57   ` David Brownell
  2006-10-27 16:16   ` omap-keypad issues with 2.6.19-rc? Jonathan McDowell
  2006-10-24 16:16 ` Git tree updated to 2.6.19-rc2 Dirk Behme
  2006-10-26 20:22 ` David Brownell
  3 siblings, 2 replies; 14+ messages in thread
From: Jonathan McDowell @ 2006-10-24 11:05 UTC (permalink / raw)
  To: linux-omap-open-source

On Mon, Oct 23, 2006 at 11:39:26PM +0300, Tony Lindgren wrote:
> I've updated our git tree to 2.6.19-rc2. At least following have
> problems on omap1 (OSK):
> 
> - CONFIG_DEBUG_LL hangs system
> - BUG in omap1_mbox_enable_irq
> - Aic23 NULL pointer exception
> 
> So YMMV :) Anybody got patches for these issues already?

Haven't hit any of these with the Amstrad Delta defconfig so far (just
done a compile and boot so far), but did need the patch below to get
omap-rtc to compile.

Signed-Off-By: Jonathan McDowell <noodles@earth.li>

-----
diff --git a/drivers/char/omap-rtc.c b/drivers/char/omap-rtc.c
index f48563f..d57402f 100644
--- a/drivers/char/omap-rtc.c
+++ b/drivers/char/omap-rtc.c
@@ -120,7 +120,7 @@ static const unsigned char days_in_mo[] 
  *	A very tiny interrupt handler. It runs with SA_INTERRUPT set.
  */
 
-irqreturn_t rtc_interrupt(int irq, void *dev_id, struct pt_regs *regs)
+irqreturn_t rtc_interrupt(int irq, void *dev_id)
 {
 	/*
 	 *	Either an alarm interrupt or update complete interrupt.
-----

J.

-- 
] http://www.earth.li/~noodles/ []   How does it work?  I don't know   [
]  PGP/GPG Key @ the.earth.li   []            but it does!             [
] via keyserver, web or email.  []                                     [
] RSA: 4DC4E7FD / DSA: 5B430367 []                                     [

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-23 20:39 Git tree updated to 2.6.19-rc2 Tony Lindgren
  2006-10-24  7:53 ` Komal Shah
  2006-10-24 11:05 ` [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2) Jonathan McDowell
@ 2006-10-24 16:16 ` Dirk Behme
  2006-10-27 12:50   ` tony
  2006-10-26 20:22 ` David Brownell
  3 siblings, 1 reply; 14+ messages in thread
From: Dirk Behme @ 2006-10-24 16:16 UTC (permalink / raw)
  To: Tony Lindgren; +Cc: linux-omap-open-source

[-- Attachment #1: Type: text/plain, Size: 1142 bytes --]

Tony Lindgren wrote:
> - CONFIG_DEBUG_LL hangs system

For reference see

http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008025.html

and

http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008054.html

for an ugly workaround if you really need it. I really have
no clue what is broken here.

> - BUG in omap1_mbox_enable_irq

I think you mean

Unbalanced enable for IRQ 10
BUG: warning at kernel/irq/manage.c:118/enable_irq()

printed in bootmessages.

I spent some minutes for this as well. It is MPU "dsp"
interrupt which is enabled in omap1_mbox_enable_irq() by

enable_irq(mbox->irq);

In kernel/irq/manage.c function enable_irq() checks for
desc->depth and if it is 0 it prints above message. Seems
that desc->depth has to be >= 1.

The comment tells us

*	Undoes the effect of one call to disable_irq().  If this
*	matches the last disable, processing of interrupts on this
*	IRQ line is re-enabled.

so seems that before calling enable_irq() at least one
disable_irq() is needed.

I don't know if patch in attachment is a valid patch or only
a workaround. What do you think?

Best regards

Dirk


[-- Attachment #2: mailbox_irq_patch.txt --]
[-- Type: text/plain, Size: 385 bytes --]

--- arch/arm/plat-omap/mailbox.c_orig	2006-10-24 18:08:06.000000000 +0200
+++ arch/arm/plat-omap/mailbox.c	2006-10-24 18:10:58.000000000 +0200
@@ -237,6 +237,7 @@ static int omap_mbox_init(struct omap_mb
 		       "failed to register mailbox interrupt:%d\n", ret);
 		goto fail1;
 	}
+	disable_mbox_irq(mbox, IRQ_RX);
 	enable_mbox_irq(mbox, IRQ_RX);
 
 	spin_lock_init(&mbox->lock);


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2)
  2006-10-24 11:05 ` [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2) Jonathan McDowell
@ 2006-10-24 17:57   ` David Brownell
  2006-10-27 12:45     ` tony
  2006-10-27 16:16   ` omap-keypad issues with 2.6.19-rc? Jonathan McDowell
  1 sibling, 1 reply; 14+ messages in thread
From: David Brownell @ 2006-10-24 17:57 UTC (permalink / raw)
  To: linux-omap-open-source

On Tuesday 24 October 2006 4:05 am, Jonathan McDowell wrote:

> Haven't hit any of these with the Amstrad Delta defconfig so far (just
> done a compile and boot so far), but did need the patch below to get
> omap-rtc to compile.
> 
> Signed-Off-By: Jonathan McDowell <noodles@earth.li>

Looks right.  In fact, that RTC should IMO be added to defconfig
for all the OMAP platforms ...

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-23 20:39 Git tree updated to 2.6.19-rc2 Tony Lindgren
                   ` (2 preceding siblings ...)
  2006-10-24 16:16 ` Git tree updated to 2.6.19-rc2 Dirk Behme
@ 2006-10-26 20:22 ` David Brownell
  2006-10-27 12:53   ` tony
  3 siblings, 1 reply; 14+ messages in thread
From: David Brownell @ 2006-10-26 20:22 UTC (permalink / raw)
  To: linux-omap-open-source

I measured it at "rc3", myself ... :)

Here's an update to the musb/tusb code fixing, among other things,
compile glitches that have recently joined us.  Like removing pt_regs
in all the IRQ paths, and a rename to <linux/usb/otg.h> ...

It's possible that (finally) removing the MIN_DMA_REQUEST thing would
make trouble; best way to test that is probably with g_file_storage.
If that fails, the obvious (temporary) workaround is disabling DMA.

- Dave


Various bugfixes:
    - gadget side does dma_sync_single_for_*() if the buffer
      was mapped by the gadget driver (none do that just yet)
    - host side rx, always force dma request off "just in case",
      instead of just for Mentor's DMA (i.e. not just OMAP2430)
    - complain louder about the board needing different driver config
    - iounmap() registers on rmmod
    - fault handling fixes in tusb_start()
    - (from TI) save dma mask so modprobe after use_dma=n can use dma
    - (from TI) gadget side zero-length IN likes TXPKTRDY before status stage

Other updates:
    - catch up to pt_regs finally leaving the irq path, other build fixes
    - remove pointless headers like <linux/pci.h>
    - RemoveMoreCamelCaseNastiness
    - resolve some config-specific compiler warning/error messages
    - dump tusb irq status register too
    - remove that MIN_DMA thing; dma logic must now handle zlps
      in all cases, not just to terminate a transfer
    - comment fixes

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>

Index: h4/drivers/usb/musb/musbdefs.h
===================================================================
--- h4.orig/drivers/usb/musb/musbdefs.h	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/musbdefs.h	2006-10-26 04:16:50.000000000 -0700
@@ -43,7 +43,7 @@
 #include <linux/usb_ch9.h>
 #include <linux/usb_gadget.h>
 #include <linux/usb.h>
-#include <linux/usb_otg.h>
+#include <linux/usb/otg.h>
 #include <linux/usb/musb.h>
 
 struct musb;
@@ -75,9 +75,6 @@ struct musb_ep;
 #include "otg.h"
 
 
-/* REVISIT tune this */
-#define	MIN_DMA_REQUEST		1	/* use PIO below this xfer size */
-
 
 #ifdef CONFIG_USB_MUSB_OTG
 
@@ -374,7 +371,7 @@ static inline struct usb_request *next_o
 struct musb {
 	spinlock_t		Lock;
 	struct clk		*clock;
-	irqreturn_t		(*isr)(int, void *, struct pt_regs *);
+	irqreturn_t		(*isr)(int, void *);
 	struct work_struct	irq_work;
 
 #ifdef CONFIG_USB_MUSB_HDRC_HCD
@@ -418,7 +415,6 @@ struct musb {
 	u8			int_usb;
 	u16			int_rx;
 	u16			int_tx;
-	struct pt_regs		*int_regs;
 
 	struct otg_transceiver	xceiv;
 
Index: h4/drivers/usb/musb/g_ep0.c
===================================================================
--- h4.orig/drivers/usb/musb/g_ep0.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/g_ep0.c	2006-10-25 22:28:31.000000000 -0700
@@ -556,9 +556,11 @@ musb_read_setup(struct musb *pThis, stru
 	 */
 	pThis->bSetAddress = FALSE;
 	pThis->ackpend = MGC_M_CSR0_P_SVDRXPKTRDY;
-	if (req->wLength == 0)
+	if (req->wLength == 0) {
+		if (req->bRequestType & USB_DIR_IN)
+			pThis->ackpend |= MGC_M_CSR0_TXPKTRDY;
 		pThis->ep0_state = MGC_END0_STAGE_ACKWAIT;
-	else if (req->bRequestType & USB_DIR_IN) {
+	} else if (req->bRequestType & USB_DIR_IN) {
 		pThis->ep0_state = MGC_END0_STAGE_TX;
 		musb_writew(regs, MGC_O_HDRC_CSR0, MGC_M_CSR0_P_SVDRXPKTRDY);
 		while ((musb_readw(regs, MGC_O_HDRC_CSR0)
Index: h4/drivers/usb/musb/musb_gadget.h
===================================================================
--- h4.orig/drivers/usb/musb/musb_gadget.h	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/musb_gadget.h	2006-10-25 22:28:31.000000000 -0700
@@ -74,6 +74,7 @@ struct musb_ep {
 	/* later things are modified based on usage */
 	struct list_head		req_list;
 
+	/* true if lock must be dropped but req_list may not be advanced */
 	u8				busy;
 };
 
Index: h4/drivers/usb/musb/musb_gadget.c
===================================================================
--- h4.orig/drivers/usb/musb/musb_gadget.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/musb_gadget.c	2006-10-25 22:28:31.000000000 -0700
@@ -118,15 +118,23 @@ __acquires(ep->musb->Lock)
 
 	ep->busy = 1;
 	spin_unlock(&musb->Lock);
-	if (is_dma_capable() && req->mapped) {
-		dma_unmap_single(musb->controller,
-				req->request.dma,
-				req->request.length,
-				req->bTx
-					? DMA_TO_DEVICE
-					: DMA_FROM_DEVICE);
-		req->request.dma = DMA_ADDR_INVALID;
-		req->mapped = 0;
+	if (is_dma_capable()) {
+		if (req->mapped) {
+			dma_unmap_single(musb->controller,
+					req->request.dma,
+					req->request.length,
+					req->bTx
+						? DMA_TO_DEVICE
+						: DMA_FROM_DEVICE);
+			req->request.dma = DMA_ADDR_INVALID;
+			req->mapped = 0;
+		} else
+			dma_sync_single_for_cpu(musb->controller,
+					req->request.dma,
+					req->request.length,
+					req->bTx
+						? DMA_TO_DEVICE
+						: DMA_FROM_DEVICE);
 	}
 	if (pRequest->status == 0)
 		DBG(5, "%s done request %p,  %d/%d\n",
@@ -1135,7 +1143,7 @@ static int musb_gadget_queue(struct usb_
 {
 	struct musb_ep		*pEnd;
 	struct musb_request	*pRequest;
-	struct musb		*pThis;
+	struct musb		*musb;
 	int			status = 0;
 	unsigned long		lockflags;
 
@@ -1143,10 +1151,10 @@ static int musb_gadget_queue(struct usb_
 		return -EINVAL;
 
 	pEnd = to_musb_ep(ep);
-	pThis = pEnd->pThis;
+	musb = pEnd->pThis;
 
 	pRequest = to_musb_request(req);
-	pRequest->musb = pThis;
+	pRequest->musb = musb;
 
 	if (pRequest->ep != pEnd)
 		return -EINVAL;
@@ -1159,23 +1167,31 @@ static int musb_gadget_queue(struct usb_
 	pRequest->bEnd = pEnd->bEndNumber;
 	pRequest->bTx = pEnd->is_in;
 
-	if (is_dma_capable()
-			&& pRequest->request.dma == DMA_ADDR_INVALID
-			&& pRequest->request.length >= MIN_DMA_REQUEST
-			&& pEnd->dma) {
-		pRequest->request.dma = dma_map_single(pThis->controller,
-				pRequest->request.buf,
-				pRequest->request.length,
-				pRequest->bTx
-					? DMA_TO_DEVICE
-					: DMA_FROM_DEVICE);
-		pRequest->mapped = 1;
+	if (is_dma_capable() && pEnd->dma) {
+		if (pRequest->request.dma == DMA_ADDR_INVALID) {
+			pRequest->request.dma = dma_map_single(
+					musb->controller,
+					pRequest->request.buf,
+					pRequest->request.length,
+					pRequest->bTx
+						? DMA_TO_DEVICE
+						: DMA_FROM_DEVICE);
+			pRequest->mapped = 1;
+		} else {
+			dma_sync_single_for_device(musb->controller,
+					pRequest->request.dma,
+					pRequest->request.length,
+					pRequest->bTx
+						? DMA_TO_DEVICE
+						: DMA_FROM_DEVICE);
+			pRequest->mapped = 0;
+		}
 	} else if (!req->buf) {
 		return -ENODATA;
 	} else
 		pRequest->mapped = 0;
 
-	spin_lock_irqsave(&pThis->Lock, lockflags);
+	spin_lock_irqsave(&musb->Lock, lockflags);
 
 	/* don't queue if the ep is down */
 	if (!pEnd->desc) {
@@ -1190,10 +1206,10 @@ static int musb_gadget_queue(struct usb_
 
 	/* it this is the head of the queue, start i/o ... */
 	if (!pEnd->busy && &pRequest->request.list == pEnd->req_list.next)
-		musb_ep_restart(pThis, pRequest);
+		musb_ep_restart(musb, pRequest);
 
 cleanup:
-	spin_unlock_irqrestore(&pThis->Lock, lockflags);
+	spin_unlock_irqrestore(&musb->Lock, lockflags);
 	return status;
 }
 
Index: h4/drivers/usb/musb/musb_host.c
===================================================================
--- h4.orig/drivers/usb/musb/musb_host.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/musb_host.c	2006-10-26 04:16:36.000000000 -0700
@@ -33,7 +33,6 @@
  ******************************************************************/
 
 #include <linux/module.h>
-#include <linux/pci.h>
 #include <linux/kernel.h>
 #include <linux/delay.h>
 #include <linux/sched.h>
@@ -284,7 +283,7 @@ __acquires(musb->Lock)
 			);
 
 	spin_unlock(&musb->Lock);
-	usb_hcd_giveback_urb(musb_to_hcd(musb), urb, musb->int_regs);
+	usb_hcd_giveback_urb(musb_to_hcd(musb), urb);
 	spin_lock(&musb->Lock);
 }
 
@@ -1485,8 +1484,8 @@ void musb_host_rx(struct musb *pThis, u8
 	}
 
 	if (unlikely(dma_channel_status(dma) == MGC_DMA_STATUS_BUSY)) {
-		/* SHOULD NEVER HAPPEN */
-		ERR("RX%d dma busy\n", bEnd);
+		/* SHOULD NEVER HAPPEN ... but at least DaVinci has done it */
+		ERR("RX%d dma busy, csr %04x\n", bEnd, wRxCsrVal);
 		goto finish;
 	}
 
@@ -1521,9 +1520,15 @@ void musb_host_rx(struct musb *pThis, u8
 	}
 #endif
 	if (dma && (wRxCsrVal & MGC_M_RXCSR_DMAENAB)) {
+		xfer_len = dma->dwActualLength;
+
+		wVal &= ~(MGC_M_RXCSR_DMAENAB
+			| MGC_M_RXCSR_H_AUTOREQ
+			| MGC_M_RXCSR_AUTOCLEAR
+			| MGC_M_RXCSR_RXPKTRDY);
+		musb_writew(pEnd->regs, MGC_O_HDRC_RXCSR, wVal);
 
 #ifdef CONFIG_USB_INVENTRA_DMA
-		xfer_len = dma->dwActualLength;
 		pUrb->actual_length += xfer_len;
 		qh->offset += xfer_len;
 
@@ -1531,14 +1536,6 @@ void musb_host_rx(struct musb *pThis, u8
 		bDone = (pUrb->actual_length >= pUrb->transfer_buffer_length)
 			|| (dma->dwActualLength & (qh->maxpacket - 1));
 
-		wVal &= ~(MGC_M_RXCSR_DMAENAB
-			| MGC_M_RXCSR_H_AUTOREQ
-			| MGC_M_RXCSR_AUTOCLEAR
-			| MGC_M_RXCSR_RXPKTRDY);
-
-		MGC_WriteCsr16(pBase, MGC_O_HDRC_RXCSR, bEnd, wVal);
-		MGC_WriteCsr16(pBase, MGC_O_HDRC_RXCSR, bEnd, wVal);
-
 		/* send IN token for next packet, without AUTOREQ */
 		if (!bDone) {
 			wVal |= MGC_M_RXCSR_H_REQPKT;
@@ -1552,7 +1549,6 @@ void musb_host_rx(struct musb *pThis, u8
 			MGC_ReadCsr16(pBase, MGC_O_HDRC_RXCOUNT, bEnd));
 #else
 		bDone = TRUE;
-		xfer_len = dma->dwActualLength;
 #endif
 	} else if (pUrb->status == -EINPROGRESS) {
 		/* if no errors, be sure a packet is ready for unloading */
@@ -1682,7 +1678,7 @@ static int musb_schedule(
 	int			idle;
 	int			wBestDiff;
 	int			nBestEnd, nEnd;
-	struct musb_hw_ep	*hw_ep;
+	struct musb_hw_ep	*hw_ep = NULL;
 	struct list_head	*head = NULL;
 
 	/* use fixed hardware for control and bulk */
Index: h4/drivers/usb/musb/plat_uds.c
===================================================================
--- h4.orig/drivers/usb/musb/plat_uds.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/plat_uds.c	2006-10-26 04:23:29.000000000 -0700
@@ -94,7 +94,6 @@
  */
 
 #include <linux/module.h>
-#include <linux/pci.h>
 #include <linux/kernel.h>
 #include <linux/sched.h>
 #include <linux/slab.h>
@@ -665,6 +664,7 @@ void musb_start(struct musb *musb)
 	musb_writeb(regs, MGC_O_HDRC_POWER, MGC_M_POWER_ISOUPDATE
 						| MGC_M_POWER_SOFTCONN
 						| MGC_M_POWER_HSENAB
+						/* ENSUSPEND wedges tusb */
 						// | MGC_M_POWER_ENSUSPEND
 						);
 
@@ -672,7 +672,7 @@ void musb_start(struct musb *musb)
 	devctl = musb_readb(regs, MGC_O_HDRC_DEVCTL);
 	devctl &= ~MGC_M_DEVCTL_SESSION;
 
-	if (is_otg_enabled(pThis)) {
+	if (is_otg_enabled(musb)) {
 		/* session started after:
 		 * (a) ID-grounded irq, host mode;
 		 * (b) vbus present/connect IRQ, peripheral mode;
@@ -683,7 +683,7 @@ void musb_start(struct musb *musb)
 		else
 			devctl |= MGC_M_DEVCTL_SESSION;
 
-	} else if (is_host_enabled(pThis)) {
+	} else if (is_host_enabled(musb)) {
 		/* assume ID pin is hard-wired to ground */
 		devctl |= MGC_M_DEVCTL_SESSION;
 
@@ -1276,7 +1276,7 @@ static int __devinit musb_core_init(u16 
 
 #ifdef CONFIG_ARCH_OMAP243X
 
-static irqreturn_t generic_interrupt(int irq, void *__hci, struct pt_regs *r)
+static irqreturn_t generic_interrupt(int irq, void *__hci)
 {
 	unsigned long	flags;
 	irqreturn_t	retval = IRQ_NONE;
@@ -1287,7 +1287,6 @@ static irqreturn_t generic_interrupt(int
 	musb->int_usb = musb_readb(musb->pRegs, MGC_O_HDRC_INTRUSB);
 	musb->int_tx = musb_readw(musb->pRegs, MGC_O_HDRC_INTRTX);
 	musb->int_rx = musb_readw(musb->pRegs, MGC_O_HDRC_INTRRX);
-	musb->int_regs = r;
 
 	if (musb->int_usb || musb->int_tx || musb->int_rx)
 		retval = musb_interrupt(musb);
@@ -1604,7 +1603,6 @@ static void musb_free(struct musb *musb)
 	if (is_dma_capable() && musb->pDmaController) {
 		struct dma_controller	*c = musb->pDmaController;
 
-//
 		(void) c->stop(c->pPrivateData);
 		dma_controller_factory.destroy(c);
 	}
@@ -1667,7 +1665,7 @@ musb_init_controller(struct device *dev,
 	bad_config:
 #endif
 	default:
-		dev_dbg(dev, "incompatible Kconfig role setting\n");
+		dev_err(dev, "incompatible Kconfig role setting\n");
 		return -EINVAL;
 	}
 
@@ -1811,8 +1809,9 @@ fail:
 	INIT_WORK(&pThis->irq_work, musb_irq_work, pThis);
 
 #ifdef CONFIG_SYSFS
-	device_create_file(dev, &dev_attr_mode);
-	device_create_file(dev, &dev_attr_cable);
+	status = device_create_file(dev, &dev_attr_mode);
+	status = device_create_file(dev, &dev_attr_cable);
+	status = 0;
 #endif
 
 	return status;
@@ -1828,6 +1827,10 @@ fail2:
  * bridge to a platform device; this driver then suffices.
  */
 
+#ifndef CONFIG_USB_INVENTRA_FIFO
+static u64	*orig_dma_mask;
+#endif
+
 static int __devinit musb_probe(struct platform_device *pdev)
 {
 	struct device	*dev = &pdev->dev;
@@ -1845,12 +1848,17 @@ static int __devinit musb_probe(struct p
 		return -ENOMEM;
 	}
 
+#ifndef CONFIG_USB_INVENTRA_FIFO
+	/* clobbered by use_dma=n */
+	orig_dma_mask = dev->dma_mask;
+#endif
 	return musb_init_controller(dev, irq, base);
 }
 
 static int __devexit musb_remove(struct platform_device *pdev)
 {
 	struct musb	*musb = dev_to_musb(&pdev->dev);
+	void __iomem	*ctrl_base = musb->ctrl_base;
 
 	/* this gets called on rmmod.
 	 *  - Host mode: host may still be active
@@ -1864,7 +1872,11 @@ static int __devexit musb_remove(struct 
 		usb_remove_hcd(musb_to_hcd(musb));
 #endif
 	musb_free(musb);
+	iounmap(ctrl_base);
 	device_init_wakeup(&pdev->dev, 0);
+#ifndef CONFIG_USB_INVENTRA_FIFO
+	dev->dma_mask = orig_dma_mask;
+#endif
 	return 0;
 }
 
Index: h4/drivers/usb/musb/musb_procfs.c
===================================================================
--- h4.orig/drivers/usb/musb/musb_procfs.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/musb_procfs.c	2006-10-25 22:28:31.000000000 -0700
@@ -558,7 +558,7 @@ static int dump_header_stats(struct musb
 	code = sprintf(buffer,
 			"TUSB6010: devconf %08x, phy enable %08x drive %08x"
 			"\n\totg %03x timer %08x"
-			"\n\tprcm conf %08x mgmt %08x; intmask %08x"
+			"\n\tprcm conf %08x mgmt %08x; int src %08x mask %08x"
 			"\n",
 			musb_readl(pThis->ctrl_base, TUSB_DEV_CONF),
 			musb_readl(pThis->ctrl_base, TUSB_PHY_OTG_CTRL_ENABLE),
@@ -567,6 +567,7 @@ static int dump_header_stats(struct musb
 			musb_readl(pThis->ctrl_base, TUSB_DEV_OTG_TIMER),
 			musb_readl(pThis->ctrl_base, TUSB_PRCM_CONF),
 			musb_readl(pThis->ctrl_base, TUSB_PRCM_MNGMT),
+			musb_readl(pThis->ctrl_base, TUSB_INT_SRC),
 			musb_readl(pThis->ctrl_base, TUSB_INT_MASK));
 	if (code <= 0)
 		goto done;
Index: h4/drivers/usb/musb/tusb6010.c
===================================================================
--- h4.orig/drivers/usb/musb/tusb6010.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/tusb6010.c	2006-10-26 13:16:59.000000000 -0700
@@ -146,6 +146,7 @@ void musb_read_fifo(struct musb_hw_ep *h
  * at most mA current to be drawn from VBUS during a Default-B session
  * (that is, while VBUS exceeds 4.4V).  In Default-A (including pure host
  * mode), or low power Default-B sessions, something else supplies power.
+ * Caller must take care of locking.
  */
 static int tusb_set_power(struct otg_transceiver *x, unsigned mA)
 {
@@ -178,7 +179,7 @@ static int tusb_set_power(struct otg_tra
  * (to be fixed in rev3 silicon) ... symptoms include disconnect
  * or looping suspend/resume cycles
  */
-static void tusb_set_clock_source(struct musb *musb, int mode)
+static void tusb_set_clock_source(struct musb *musb, unsigned mode)
 {
 	void __iomem	*base = musb->ctrl_base;
 	u32		reg;
@@ -186,10 +187,17 @@ static void tusb_set_clock_source(struct
 	reg = musb_readl(base, TUSB_PRCM_CONF);
 	reg &= ~TUSB_PRCM_CONF_SYS_CLKSEL(0x3);
 
+	/* 0 = refclk (clkin, XI)
+	 * 1 = PHY 60 MHz (internal PLL)
+	 * 2 = not supported
+	 * 3 = NOR clock (huh?)
+	 */
 	if (mode > 0)
 		reg |= TUSB_PRCM_CONF_SYS_CLKSEL(mode & 0x3);
 
 	musb_writel(base, TUSB_PRCM_CONF, reg);
+
+	// FIXME tusb6010_platform_retime(mode == 0);
 }
 
 /*
@@ -477,7 +485,7 @@ tusb_otg_ints(struct musb *musb, u32 int
 	}
 }
 
-static irqreturn_t tusb_interrupt(int irq, void *__hci, struct pt_regs *r)
+static irqreturn_t tusb_interrupt(int irq, void *__hci)
 {
 	struct musb	*musb = __hci;
 	void __iomem	*base = musb->ctrl_base;
@@ -489,7 +497,6 @@ static irqreturn_t tusb_interrupt(int ir
 	int_src = musb_readl(base, TUSB_INT_SRC) & ~TUSB_INT_SRC_RESERVED_BITS;
 	DBG(3, "TUSB IRQ %08x\n", int_src);
 
-	musb->int_regs = r;
 	musb->int_usb = (u8) int_src;
 
 	/* Acknowledge wake-up source interrupts */
@@ -570,7 +577,6 @@ static irqreturn_t tusb_interrupt(int ir
 	musb_writel(base, TUSB_INT_SRC_CLEAR,
 		int_src & ~TUSB_INT_MASK_RESERVED_BITS);
 
-	musb->int_regs = NULL;
 	musb_platform_try_idle(musb);
 	spin_unlock_irqrestore(&musb->Lock, flags);
 
@@ -690,10 +696,10 @@ static int tusb_print_revision(struct mu
 	return TUSB_REV_MAJOR(musb_readl(base, TUSB_INT_CTRL_REV));
 }
 
-static int tusb_start(struct musb *musb)
+static int __devinit tusb_start(struct musb *musb)
 {
 	void __iomem	*base = musb->ctrl_base;
-	int		ret = -1;
+	int		ret = 0;
 	unsigned long	flags;
 	u32		reg;
 
@@ -701,7 +707,7 @@ static int tusb_start(struct musb *musb)
 		ret = musb->board_set_power(1);
 	if (ret != 0) {
 		printk(KERN_ERR "tusb: Cannot enable TUSB6010\n");
-		goto err;
+		return ret;
 	}
 
 	spin_lock_irqsave(&musb->Lock, flags);
@@ -752,6 +758,8 @@ static int tusb_start(struct musb *musb)
 	return 0;
 
 err:
+	spin_unlock_irqrestore(&musb->Lock, flags);
+
 	if (musb->board_set_power)
 		musb->board_set_power(0);
 
Index: h4/drivers/usb/musb/omap2430.c
===================================================================
--- h4.orig/drivers/usb/musb/omap2430.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/omap2430.c	2006-10-25 22:28:31.000000000 -0700
@@ -21,7 +21,6 @@
  *
  */
 #include <linux/module.h>
-#include <linux/pci.h>
 #include <linux/kernel.h>
 #include <linux/sched.h>
 #include <linux/slab.h>
@@ -29,9 +28,6 @@
 #include <linux/list.h>
 #include <linux/clk.h>
 
-#include <linux/module.h>
-#include <linux/kernel.h>
-#include <linux/init.h>
 #include <asm/io.h>
 #include <asm/mach-types.h>
 #include <asm/arch/hardware.h>
Index: h4/drivers/usb/musb/davinci.c
===================================================================
--- h4.orig/drivers/usb/musb/davinci.c	2006-10-25 22:24:14.000000000 -0700
+++ h4/drivers/usb/musb/davinci.c	2006-10-26 04:18:04.000000000 -0700
@@ -22,7 +22,6 @@
  */
 
 #include <linux/module.h>
-#include <linux/pci.h>
 #include <linux/kernel.h>
 #include <linux/sched.h>
 #include <linux/slab.h>
@@ -246,7 +245,7 @@ static void davinci_set_vbus(struct musb
 	return davinci_vbus_power(musb, is_on, 0);
 }
 
-static irqreturn_t davinci_interrupt(int irq, void *__hci, struct pt_regs *r)
+static irqreturn_t davinci_interrupt(int irq, void *__hci)
 {
 	unsigned long	flags;
 	irqreturn_t	retval = IRQ_NONE;
@@ -289,7 +288,6 @@ static irqreturn_t davinci_interrupt(int
 			>> DAVINCI_USB_TXINT_SHIFT;
 	musb->int_usb = (tmp & DAVINCI_USB_USBINT_MASK)
 			>> DAVINCI_USB_USBINT_SHIFT;
-	musb->int_regs = r;
 
 	/* treat DRVVBUS irq like an ID change IRQ (for now) */
 	if (tmp & (1 << (8 + DAVINCI_USB_USBINT_SHIFT))) {
@@ -317,7 +315,6 @@ static irqreturn_t davinci_interrupt(int
 	/* irq stays asserted until EOI is written */
 	musb_writel(tibase, DAVINCI_USB_EOI_REG, 0);
 
-	musb->int_regs = NULL;
 	spin_unlock_irqrestore(&musb->Lock, flags);
 
 	/* REVISIT we sometimes get unhandled IRQs

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2)
  2006-10-24 17:57   ` David Brownell
@ 2006-10-27 12:45     ` tony
  0 siblings, 0 replies; 14+ messages in thread
From: tony @ 2006-10-27 12:45 UTC (permalink / raw)
  To: David Brownell; +Cc: linux-omap-open-source

* David Brownell <david-b@pacbell.net> [061024 21:54]:
> On Tuesday 24 October 2006 4:05 am, Jonathan McDowell wrote:
> 
> > Haven't hit any of these with the Amstrad Delta defconfig so far (just
> > done a compile and boot so far), but did need the patch below to get
> > omap-rtc to compile.
> > 
> > Signed-Off-By: Jonathan McDowell <noodles@earth.li>
> 
> Looks right.  In fact, that RTC should IMO be added to defconfig
> for all the OMAP platforms ...

OK, I've pushed Jonathan's patch and also removed other unnecessary
pt_regs.

Some boards use external RTC, but I agree we should add it in general.

Tony

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-24 16:16 ` Git tree updated to 2.6.19-rc2 Dirk Behme
@ 2006-10-27 12:50   ` tony
  2006-10-27 15:30     ` Dirk Behme
  2006-10-29 22:09     ` Hiroshi DOYU
  0 siblings, 2 replies; 14+ messages in thread
From: tony @ 2006-10-27 12:50 UTC (permalink / raw)
  To: Dirk Behme, Toshihiro Kobayashi, Hiroshi DOYU; +Cc: linux-omap-open-source

* Dirk Behme <dirk.behme@googlemail.com> [061024 19:16]:
> Tony Lindgren wrote:
> >- CONFIG_DEBUG_LL hangs system
> 
> For reference see
> 
> http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008025.html
> 
> and
> 
> http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008054.html
> 
> for an ugly workaround if you really need it. I really have
> no clue what is broken here.

Sounds like some clock is not enabled somewhere and serial write hangs.
 
> >- BUG in omap1_mbox_enable_irq
> 
> I think you mean
> 
> Unbalanced enable for IRQ 10
> BUG: warning at kernel/irq/manage.c:118/enable_irq()
> 
> printed in bootmessages.
> 
> I spent some minutes for this as well. It is MPU "dsp"
> interrupt which is enabled in omap1_mbox_enable_irq() by
> 
> enable_irq(mbox->irq);
> 
> In kernel/irq/manage.c function enable_irq() checks for
> desc->depth and if it is 0 it prints above message. Seems
> that desc->depth has to be >= 1.
> 
> The comment tells us
> 
> *	Undoes the effect of one call to disable_irq().  If this
> *	matches the last disable, processing of interrupts on this
> *	IRQ line is re-enabled.
> 
> so seems that before calling enable_irq() at least one
> disable_irq() is needed.
> 
> I don't know if patch in attachment is a valid patch or only
> a workaround. What do you think?
> 
> Best regards
> 
> Dirk
> 

> --- arch/arm/plat-omap/mailbox.c_orig	2006-10-24 18:08:06.000000000 +0200
> +++ arch/arm/plat-omap/mailbox.c	2006-10-24 18:10:58.000000000 +0200
> @@ -237,6 +237,7 @@ static int omap_mbox_init(struct omap_mb
>  		       "failed to register mailbox interrupt:%d\n", ret);
>  		goto fail1;
>  	}
> +	disable_mbox_irq(mbox, IRQ_RX);
>  	enable_mbox_irq(mbox, IRQ_RX);
>  
>  	spin_lock_init(&mbox->lock);
> 

Let's see what Toshihiro and Hiroshi think.

Tony

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-26 20:22 ` David Brownell
@ 2006-10-27 12:53   ` tony
  0 siblings, 0 replies; 14+ messages in thread
From: tony @ 2006-10-27 12:53 UTC (permalink / raw)
  To: David Brownell; +Cc: linux-omap-open-source

* David Brownell <david-b@pacbell.net> [061026 23:22]:
> I measured it at "rc3", myself ... :)
> 
> Here's an update to the musb/tusb code fixing, among other things,
> compile glitches that have recently joined us.  Like removing pt_regs
> in all the IRQ paths, and a rename to <linux/usb/otg.h> ...
> 
> It's possible that (finally) removing the MIN_DMA_REQUEST thing would
> make trouble; best way to test that is probably with g_file_storage.
> If that fails, the obvious (temporary) workaround is disabling DMA.
> 
> - Dave
> 
> 
> Various bugfixes:
>     - gadget side does dma_sync_single_for_*() if the buffer
>       was mapped by the gadget driver (none do that just yet)
>     - host side rx, always force dma request off "just in case",
>       instead of just for Mentor's DMA (i.e. not just OMAP2430)
>     - complain louder about the board needing different driver config
>     - iounmap() registers on rmmod
>     - fault handling fixes in tusb_start()
>     - (from TI) save dma mask so modprobe after use_dma=n can use dma
>     - (from TI) gadget side zero-length IN likes TXPKTRDY before status stage
> 
> Other updates:
>     - catch up to pt_regs finally leaving the irq path, other build fixes
>     - remove pointless headers like <linux/pci.h>
>     - RemoveMoreCamelCaseNastiness
>     - resolve some config-specific compiler warning/error messages
>     - dump tusb irq status register too
>     - remove that MIN_DMA thing; dma logic must now handle zlps
>       in all cases, not just to terminate a transfer
>     - comment fixes

Pushing today.

Tony

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-27 12:50   ` tony
@ 2006-10-27 15:30     ` Dirk Behme
  2006-10-29 22:09     ` Hiroshi DOYU
  1 sibling, 0 replies; 14+ messages in thread
From: Dirk Behme @ 2006-10-27 15:30 UTC (permalink / raw)
  To: linux-omap-open-source

tony@atomide.com wrote:
> * Dirk Behme <dirk.behme@googlemail.com> [061024 19:16]:
> 
>>Tony Lindgren wrote:
>>
>>>- CONFIG_DEBUG_LL hangs system
>>
>>For reference see
>>
>>http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008025.html
>>
>>and
>>
>>http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008054.html
>>
>>for an ugly workaround if you really need it. I really have
>>no clue what is broken here.
> 
> 
> Sounds like some clock is not enabled somewhere and serial write hangs.

Good idea! I think we had some clock rework meanwhile. Maybe 
we have to move a clock enable to some earlier point if 
using CONFIG_DEBUG_LL. Any idea which clock is worth looking at?

Best regards

Dirk

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: omap-keypad issues with 2.6.19-rc?
  2006-10-24 11:05 ` [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2) Jonathan McDowell
  2006-10-24 17:57   ` David Brownell
@ 2006-10-27 16:16   ` Jonathan McDowell
  2006-10-27 16:49     ` [PATCH] ARM: OMAP: Fix Amstrad Delta omap-keypad usage Jonathan McDowell
  1 sibling, 1 reply; 14+ messages in thread
From: Jonathan McDowell @ 2006-10-27 16:16 UTC (permalink / raw)
  To: linux-omap-open-source

On Tue, Oct 24, 2006 at 12:05:02PM +0100, Jonathan McDowell wrote:
> On Mon, Oct 23, 2006 at 11:39:26PM +0300, Tony Lindgren wrote:
> > I've updated our git tree to 2.6.19-rc2. At least following have
> > problems on omap1 (OSK):
> > 
> > - CONFIG_DEBUG_LL hangs system
> > - BUG in omap1_mbox_enable_irq
> > - Aic23 NULL pointer exception
> > 
> > So YMMV :) Anybody got patches for these issues already?
> 
> Haven't hit any of these with the Amstrad Delta defconfig so far (just
> done a compile and boot so far), 

However having prodded further I'm seeing incorrect key parsing with
the omap-keypad driver under both -rc2 and -rc3 (works fine in
2.6.18-omap1). Numerous keys now returns strings of characters rather
than the single expected character. A few keys still work as expected
however. Before I dig in further is anyone else seeing anything similar?

J.

-- 
 After a number of decimal places,  |       Black Cat Networks Ltd
       nobody gives a damn.         | http://www.blackcatnetworks.co.uk/
                                    |  UK Web, domain and email hosting

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [PATCH] ARM: OMAP: Fix Amstrad Delta omap-keypad usage.
  2006-10-27 16:16   ` omap-keypad issues with 2.6.19-rc? Jonathan McDowell
@ 2006-10-27 16:49     ` Jonathan McDowell
  0 siblings, 0 replies; 14+ messages in thread
From: Jonathan McDowell @ 2006-10-27 16:49 UTC (permalink / raw)
  To: linux-omap-open-source

On Fri, Oct 27, 2006 at 05:16:59PM +0100, Jonathan McDowell wrote:
> However having prodded further I'm seeing incorrect key parsing with
> the omap-keypad driver under both -rc2 and -rc3 (works fine in
> 2.6.18-omap1). Numerous keys now returns strings of characters rather
> than the single expected character. A few keys still work as expected
> however. Before I dig in further is anyone else seeing anything similar?

This appears to be due to the addition of keymapsize to the
omap_kp_platform_data structure. The patch below fixes things up for
the Delta; other boards appear to have already had this done.

Signed-Off-By: Jonathan McDowell <noodles@earth.li>

-----
diff --git a/arch/arm/mach-omap1/board-ams-delta.c b/arch/arm/mach-omap1/board-ams-delta.c
index 0a0c06f..c73ca61 100644
--- a/arch/arm/mach-omap1/board-ams-delta.c
+++ b/arch/arm/mach-omap1/board-ams-delta.c
@@ -187,10 +187,11 @@ static struct resource ams_delta_kp_reso
 };
 
 static struct omap_kp_platform_data ams_delta_kp_data = {
-	.rows	= 8,
-	.cols	= 8,
-	.keymap = ams_delta_keymap,
-	.rep	= 1,
+	.rows		= 8,
+	.cols		= 8,
+	.keymap 	= ams_delta_keymap,
+	.keymapsize	= ARRAY_SIZE(ams_delta_keymap),
+	.delay		= 9,
 };
 
 static struct platform_device ams_delta_kp_device = {
-----

J.

-- 
   101 things you can't have too   |  .''`.  Debian GNU/Linux Developer
  much of : 9 - Processing power.  | : :' :  Happy to accept PGP signed
                                   | `. `'   or encrypted mail - RSA +
                                   |   `-    DSA keys on the keyservers.

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Aic23 NULL pointer exception, was: Git tree updated to 2.6.19-rc2
  2006-10-24  7:53 ` Komal Shah
@ 2006-10-28  6:31   ` Dirk Behme
  0 siblings, 0 replies; 14+ messages in thread
From: Dirk Behme @ 2006-10-28  6:31 UTC (permalink / raw)
  To: Komal Shah, linux-omap-open-source

Komal Shah wrote:
>>- Aic23 NULL pointer exception
> 
> Anything related to as discussed on davinci mailing list for I2C?

Oops is

Unable to handle kernel NULL pointer dereference at virtual 
address 00000004
PC is at i2c_smbus_write_byte_data+0x10/0x50
LR is at aic23_write_value+0x40/0x50

> http://linux.omap.com/pipermail/davinci-linux-open-source/2006-October/001312.html

I think this is the same?

> If that is the case, then please try adding zero-length transaction and
> SMBUS_QUICK code as temporary hack.

Anywhere a (hackish) patch for this available? Would be nice 
to have sound working again, even if a hack, until clean 
solution is available.

Best regards

Dirk

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Git tree updated to 2.6.19-rc2
  2006-10-27 12:50   ` tony
  2006-10-27 15:30     ` Dirk Behme
@ 2006-10-29 22:09     ` Hiroshi DOYU
  1 sibling, 0 replies; 14+ messages in thread
From: Hiroshi DOYU @ 2006-10-29 22:09 UTC (permalink / raw)
  To: tony; +Cc: linux-omap-open-source

From: "ext tony@atomide.com" <tony@atomide.com>
Subject: Re: Git tree updated to 2.6.19-rc2
Date: Fri, 27 Oct 2006 15:50:17 +0300

> * Dirk Behme <dirk.behme@googlemail.com> [061024 19:16]:
> > Tony Lindgren wrote:
> > >- CONFIG_DEBUG_LL hangs system
> > 
> > For reference see
> > 
> > http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008025.html
> > 
> > and
> > 
> > http://linux.omap.com/pipermail/linux-omap-open-source/2006-October/008054.html
> > 
> > for an ugly workaround if you really need it. I really have
> > no clue what is broken here.
> 
> Sounds like some clock is not enabled somewhere and serial write hangs.
>  
> > >- BUG in omap1_mbox_enable_irq
> > 
> > I think you mean
> > 
> > Unbalanced enable for IRQ 10
> > BUG: warning at kernel/irq/manage.c:118/enable_irq()
> > 
> > printed in bootmessages.
> > 
> > I spent some minutes for this as well. It is MPU "dsp"
> > interrupt which is enabled in omap1_mbox_enable_irq() by
> > 
> > enable_irq(mbox->irq);
> > 
> > In kernel/irq/manage.c function enable_irq() checks for
> > desc->depth and if it is 0 it prints above message. Seems
> > that desc->depth has to be >= 1.
> > 
> > The comment tells us
> > 
> > *	Undoes the effect of one call to disable_irq().  If this
> > *	matches the last disable, processing of interrupts on this
> > *	IRQ line is re-enabled.
> > 
> > so seems that before calling enable_irq() at least one
> > disable_irq() is needed.
> > 
> > I don't know if patch in attachment is a valid patch or only
> > a workaround. What do you think?
> > 
> > Best regards
> > 
> > Dirk
> > 
> 
> > --- arch/arm/plat-omap/mailbox.c_orig	2006-10-24 18:08:06.000000000 +0200
> > +++ arch/arm/plat-omap/mailbox.c	2006-10-24 18:10:58.000000000 +0200
> > @@ -237,6 +237,7 @@ static int omap_mbox_init(struct omap_mb
> >  		       "failed to register mailbox interrupt:%d\n", ret);
> >  		goto fail1;
> >  	}
> > +	disable_mbox_irq(mbox, IRQ_RX);
> >  	enable_mbox_irq(mbox, IRQ_RX);
> >  
> >  	spin_lock_init(&mbox->lock);
> > 
> 
> Let's see what Toshihiro and Hiroshi think.

I guess that the above should work for now but I think that there's
another way, for example, I can have initialization flag in
enable_mbox_irq() in omap1, though I am sure that there's better way.

    Hiroshi DOYU

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2006-10-29 22:09 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-10-23 20:39 Git tree updated to 2.6.19-rc2 Tony Lindgren
2006-10-24  7:53 ` Komal Shah
2006-10-28  6:31   ` Aic23 NULL pointer exception, was: " Dirk Behme
2006-10-24 11:05 ` [PATCH] ARM: OMAP: Fixup omap-rtc (was: Git tree updated to 2.6.19-rc2) Jonathan McDowell
2006-10-24 17:57   ` David Brownell
2006-10-27 12:45     ` tony
2006-10-27 16:16   ` omap-keypad issues with 2.6.19-rc? Jonathan McDowell
2006-10-27 16:49     ` [PATCH] ARM: OMAP: Fix Amstrad Delta omap-keypad usage Jonathan McDowell
2006-10-24 16:16 ` Git tree updated to 2.6.19-rc2 Dirk Behme
2006-10-27 12:50   ` tony
2006-10-27 15:30     ` Dirk Behme
2006-10-29 22:09     ` Hiroshi DOYU
2006-10-26 20:22 ` David Brownell
2006-10-27 12:53   ` tony

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox