aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/firewire
diff options
context:
space:
mode:
authorJarod Wilson <jwilson@redhat.com>2008-04-03 17:18:23 -0400
committerStefan Richter <stefanr@s5r6.in-berlin.de>2008-04-18 11:55:34 -0400
commit75f7832e3b032c6e4a83c14b58341abd9f2d81ef (patch)
tree25ee08f7433450ed1b85362c8fe5b244567217de /drivers/firewire
parent022147242ff6e4b7ab770f00716063f48c088391 (diff)
firewire: fw-ohci: log regAccessFail events
While trying to debug this piece of crap JMicron PCI-e controller in my possession, one thought was that perhaps I was encountering register access failures. I'm not, but logging them would be good, so we can see if they are a real problem we should be taking into account anywhere in the code. Signed-off-by: Jarod Wilson <jwilson@redhat.com> Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> (added list contact)
Diffstat (limited to 'drivers/firewire')
-rw-r--r--drivers/firewire/fw-ohci.c13
-rw-r--r--drivers/firewire/fw-ohci.h1
2 files changed, 11 insertions, 3 deletions
diff --git a/drivers/firewire/fw-ohci.c b/drivers/firewire/fw-ohci.c
index e88260b67611..ce18bab3f9d5 100644
--- a/drivers/firewire/fw-ohci.c
+++ b/drivers/firewire/fw-ohci.c
@@ -257,7 +257,7 @@ static void log_irqs(u32 evt)
257 if (likely(!(param_debug & OHCI_PARAM_DEBUG_IRQS))) 257 if (likely(!(param_debug & OHCI_PARAM_DEBUG_IRQS)))
258 return; 258 return;
259 259
260 printk(KERN_DEBUG KBUILD_MODNAME ": IRQ %08x%s%s%s%s%s%s%s%s%s%s%s\n", 260 printk(KERN_DEBUG KBUILD_MODNAME ": IRQ %08x%s%s%s%s%s%s%s%s%s%s%s%s\n",
261 evt, 261 evt,
262 evt & OHCI1394_selfIDComplete ? " selfID" : "", 262 evt & OHCI1394_selfIDComplete ? " selfID" : "",
263 evt & OHCI1394_RQPkt ? " AR_req" : "", 263 evt & OHCI1394_RQPkt ? " AR_req" : "",
@@ -269,11 +269,13 @@ static void log_irqs(u32 evt)
269 evt & OHCI1394_postedWriteErr ? " postedWriteErr" : "", 269 evt & OHCI1394_postedWriteErr ? " postedWriteErr" : "",
270 evt & OHCI1394_cycleTooLong ? " cycleTooLong" : "", 270 evt & OHCI1394_cycleTooLong ? " cycleTooLong" : "",
271 evt & OHCI1394_cycle64Seconds ? " cycle64Seconds" : "", 271 evt & OHCI1394_cycle64Seconds ? " cycle64Seconds" : "",
272 evt & OHCI1394_regAccessFail ? " regAccessFail" : "",
272 evt & ~(OHCI1394_selfIDComplete | OHCI1394_RQPkt | 273 evt & ~(OHCI1394_selfIDComplete | OHCI1394_RQPkt |
273 OHCI1394_RSPkt | OHCI1394_reqTxComplete | 274 OHCI1394_RSPkt | OHCI1394_reqTxComplete |
274 OHCI1394_respTxComplete | OHCI1394_isochRx | 275 OHCI1394_respTxComplete | OHCI1394_isochRx |
275 OHCI1394_isochTx | OHCI1394_postedWriteErr | 276 OHCI1394_isochTx | OHCI1394_postedWriteErr |
276 OHCI1394_cycleTooLong | OHCI1394_cycle64Seconds) 277 OHCI1394_cycleTooLong | OHCI1394_cycle64Seconds |
278 OHCI1394_regAccessFail)
277 ? " ?" : ""); 279 ? " ?" : "");
278} 280}
279 281
@@ -1351,6 +1353,10 @@ static irqreturn_t irq_handler(int irq, void *data)
1351 iso_event &= ~(1 << i); 1353 iso_event &= ~(1 << i);
1352 } 1354 }
1353 1355
1356 if (unlikely(event & OHCI1394_regAccessFail))
1357 fw_error("Register access failure - "
1358 "please notify linux1394-devel@lists.sf.net\n");
1359
1354 if (unlikely(event & OHCI1394_postedWriteErr)) 1360 if (unlikely(event & OHCI1394_postedWriteErr))
1355 fw_error("PCI posted write error\n"); 1361 fw_error("PCI posted write error\n");
1356 1362
@@ -1448,7 +1454,8 @@ static int ohci_enable(struct fw_card *card, u32 *config_rom, size_t length)
1448 OHCI1394_reqTxComplete | OHCI1394_respTxComplete | 1454 OHCI1394_reqTxComplete | OHCI1394_respTxComplete |
1449 OHCI1394_isochRx | OHCI1394_isochTx | 1455 OHCI1394_isochRx | OHCI1394_isochTx |
1450 OHCI1394_postedWriteErr | OHCI1394_cycleTooLong | 1456 OHCI1394_postedWriteErr | OHCI1394_cycleTooLong |
1451 OHCI1394_cycle64Seconds | OHCI1394_masterIntEnable); 1457 OHCI1394_cycle64Seconds | OHCI1394_regAccessFail |
1458 OHCI1394_masterIntEnable);
1452 1459
1453 /* Activate link_on bit and contender bit in our self ID packets.*/ 1460 /* Activate link_on bit and contender bit in our self ID packets.*/
1454 if (ohci_update_phy_reg(card, 4, 0, 1461 if (ohci_update_phy_reg(card, 4, 0,
diff --git a/drivers/firewire/fw-ohci.h b/drivers/firewire/fw-ohci.h
index 5754c6e9d595..a2fbb6240ca7 100644
--- a/drivers/firewire/fw-ohci.h
+++ b/drivers/firewire/fw-ohci.h
@@ -125,6 +125,7 @@
125#define OHCI1394_lockRespErr 0x00000200 125#define OHCI1394_lockRespErr 0x00000200
126#define OHCI1394_selfIDComplete 0x00010000 126#define OHCI1394_selfIDComplete 0x00010000
127#define OHCI1394_busReset 0x00020000 127#define OHCI1394_busReset 0x00020000
128#define OHCI1394_regAccessFail 0x00040000
128#define OHCI1394_phy 0x00080000 129#define OHCI1394_phy 0x00080000
129#define OHCI1394_cycleSynch 0x00100000 130#define OHCI1394_cycleSynch 0x00100000
130#define OHCI1394_cycle64Seconds 0x00200000 131#define OHCI1394_cycle64Seconds 0x00200000