rpms/kernel/devel linux-2.6-firewire-git-pending.patch,1.25,1.26
Jarod Wilson (jwilson)
fedora-extras-commits at redhat.com
Mon Apr 7 13:49:46 UTC 2008
Author: jwilson
Update of /cvs/pkgs/rpms/kernel/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv25824
Modified Files:
linux-2.6-firewire-git-pending.patch
Log Message:
minor update to jmicron firewire controller work-around patch
linux-2.6-firewire-git-pending.patch:
Index: linux-2.6-firewire-git-pending.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/linux-2.6-firewire-git-pending.patch,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- linux-2.6-firewire-git-pending.patch 4 Apr 2008 21:07:22 -0000 1.25
+++ linux-2.6-firewire-git-pending.patch 7 Apr 2008 13:49:26 -0000 1.26
@@ -163,13 +163,15 @@
Signed-off-by: Jarod Wilson <jwilson at redhat.com>
+Update: remove some redundant code
+
---
- drivers/firewire/fw-ohci.c | 25 ++++++++++++++++++++++---
- 1 files changed, 22 insertions(+), 3 deletions(-)
+ drivers/firewire/fw-ohci.c | 23 ++++++++++++++++++-----
+ 1 files changed, 18 insertions(+), 5 deletions(-)
diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c
-index ad5accd..4bbc0a2 100644
+index ad5accd..916bfa7 100644
--- a/drivers/firewire/fw-ohci.c
+++ b/drivers/firewire/fw-ohci.c
@@ -257,7 +257,8 @@ static void log_irqs(u32 evt)
@@ -197,31 +199,29 @@
? " ?" : "");
}
-@@ -959,6 +961,23 @@ at_context_queue_packet(struct context *ctx, struct fw_packet *packet)
- return -1;
- }
+@@ -950,8 +952,19 @@ at_context_queue_packet(struct context *ctx, struct fw_packet *packet)
+ DESCRIPTOR_IRQ_ALWAYS |
+ DESCRIPTOR_BRANCH_ALWAYS);
+- /* FIXME: Document how the locking works. */
+- if (ohci->generation != packet->generation) {
+ /*
-+ * If IntEvent.busReset is set, the AT context is halted, so appending
-+ * to the context and trying to run it is futile. Most controllers do
-+ * the right thing and just flush the AT queue (per section 7.2.3.2 of
-+ * the OHCI 1.1 specification), but some controllers (like a JMicron
-+ * PCI-e) misbehave and wind up stalling out. So we just bail out
-+ * in software and try again later, and everyone is happy.
++ * If the controller and packet generations don't match, we need to
++ * bail out and try again. If IntEvent.busReset is set, the AT context
++ * is halted, so appending to the context and trying to run it is
++ * futile. Most controllers do the right thing and just flush the AT
++ * queue (per section 7.2.3.2 of the OHCI 1.1 specification), but
++ * some controllers (like a JMicron JM2380 PCI-e) misbehave and wind
++ * up stalling out. So we just bail out in software and try again
++ * later, and everyone is happy.
++ * FIXME: Document how the locking works.
+ */
-+ reg = reg_read(ohci, OHCI1394_IntEventClear);
-+ if (reg & OHCI1394_busReset) {
-+ if (packet->payload_length > 0)
-+ dma_unmap_single(ohci->card.device, payload_bus,
-+ packet->payload_length, DMA_TO_DEVICE);
-+ packet->ack = RCODE_GENERATION;
-+ return -1;
-+ }
-+
- context_append(ctx, d, z, 4 - z);
-
- /* If the context isn't already running, start it up. */
-@@ -1455,7 +1474,7 @@ static int ohci_enable(struct fw_card *card, u32 *config_rom, size_t length)
++ if (ohci->generation != packet->generation ||
++ reg_read(ohci, OHCI1394_IntEventClear) & OHCI1394_busReset) {
+ if (packet->payload_length > 0)
+ dma_unmap_single(ohci->card.device, payload_bus,
+ packet->payload_length, DMA_TO_DEVICE);
+@@ -1455,7 +1468,7 @@ static int ohci_enable(struct fw_card *card, u32 *config_rom, size_t length)
OHCI1394_isochRx | OHCI1394_isochTx |
OHCI1394_postedWriteErr | OHCI1394_cycleTooLong |
OHCI1394_cycle64Seconds | OHCI1394_regAccessFail |
More information about the fedora-extras-commits
mailing list