From: Sven Luther <sven.luther@wanadoo.fr>
To: Sven Luther <sven.luther@wanadoo.fr>
Cc: Alan Cox <alan@www.pagan.org.uk>, Nicolas DET <nd@bplan-gmbh.de>,
linux-usb-devel@lists.sourceforge.net,
linuxppc-dev@lists.linuxppc.org
Subject: Re: [linux-usb-devel] [Patch] for UHCI driver (from kernel 2.6.6).
Date: Fri, 18 Jun 2004 12:20:44 +0200 [thread overview]
Message-ID: <20040618102044.GA32161@pegasos> (raw)
In-Reply-To: <20040617173454.GA5971@pegasos>
On Thu, Jun 17, 2004 at 07:34:54PM +0200, Sven Luther wrote:
> On Mon, Jun 14, 2004 at 08:38:52PM +0100, Alan Cox wrote:
> > On Llu, 2004-06-14 at 16:12, Nicolas DET wrote:
> > > Also, we replace spin_lock_irqxxx/spin_unlock_irq by spin_lock/unlock
> > > (for SMP/PREEMPT kernel) + stop/start_interrupt.
> >
> > This requires a lot of care to do right. Remember that on PC systems
> > interrupts can be substantially posted. A "stop_interrupt" may prevent
> > IRQ issue but if an IRQ is already on the PC APIC bus it will kill you
> > later on because the IRQ delivery and PCI bus access on the PC class
> > machines are totally asynchronous
>
> And what about the other part of the patch ? The one about the
> alignement of the buffer descriptors ? Does it seem sound, should we
> ward it with ppc specific stuff ? Is it fit to be included in the main
> kernel ?
Mmm, it seems that inversing the remove_list and the list also makes the
problem go away, or at least be less important, in :
struct uhci_td {
/* Hardware fields */
__u32 link;
__u32 status;
__u32 token;
__u32 buffer;
/* Software fields */
dma_addr_t dma_handle;
struct usb_device *dev;
struct urb *urb;
struct list_head list; /* P: urb->lock */
struct list_head remove_list; /* P: uhci->td_remove_list_lock */
int frame; /* for iso: what frame? */
struct list_head fl_list; /* P: uhci->frame_list_lock */
} __attribute__((aligned(16)));
Could it be possible that the warning in :
/*
* The documentation says "4 words for hardware, 4 words for software".
*
* That's silly, the hardware doesn't care. The hardware only cares that
* the hardware words are 16-byte aligned, and we can have any amount of
* sw space after the TD entry as far as I can tell.
be still important, at least on G4 powerpc ? remove_list is the 5th
software word here. Strange, because supposedly it works on x86 and
other uhci using arches, and it works on the G3, but not on the G4.
Friendly,
Sven Luther
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
next parent reply other threads:[~2004-06-18 10:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <40CDC05B.9020708@bplan-gmbh.de>
[not found] ` <1087241757.5996.3.camel@localhost.localdomain>
[not found] ` <20040617173454.GA5971@pegasos>
2004-06-18 10:20 ` Sven Luther [this message]
2004-06-18 21:31 ` [linux-usb-devel] [Patch] for UHCI driver (from kernel 2.6.6) Benjamin Herrenschmidt
2004-06-18 21:41 ` Alan Stern
2004-06-18 21:43 ` Benjamin Herrenschmidt
2004-06-19 13:59 ` Alan Stern
2004-06-19 14:16 ` Sven Luther
2004-06-21 8:18 ` Segher Boessenkool
2004-06-21 8:57 ` Sven Luther
2004-06-19 6:53 ` Oliver Neukum
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040618102044.GA32161@pegasos \
--to=sven.luther@wanadoo.fr \
--cc=alan@www.pagan.org.uk \
--cc=linux-usb-devel@lists.sourceforge.net \
--cc=linuxppc-dev@lists.linuxppc.org \
--cc=nd@bplan-gmbh.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).