Re: [PATCH 1/2] firewire: endianess fix

From: Stefan Richter
Date: Sat Feb 23 2008 - 07:13:35 EST


I wrote:
This needs to be tested on different big endian PCs, if possible with
the Apple Uninorth FireWire controller and other types of controllers.
One test which involves ohci->request_generation is simply with an SBP-2
device (harddisk, CD-ROM...). Does SBP-2 login etc. work?

Hmm, no, tests with SBP-2 devices won't trigger that problem at all.
All of the requests from the device will be:
- read requests to the host's config ROM, handled by the controller's
physical response unit instead of the driver stack's response
handlers,
- read requests to ORBs and read and write requests to SCSI data
buffers which are DMA-mapped at bus addresses below 4G, hence be
handled by the physical response unit as well,
- write requests to firewire-sbp2's status FIFO which is mapped into
a FireWire address range for which PCI write posting is enabled,
hence no response subaction will be generated (unified transaction)
and therefore ohci->request_generation remain unused.

Alas I have no idea how to create a simple test setup which really triggers the questionable code. Or wait, it should be triggered by replacing
&fw_high_memory_region
by
&fw_private_region
in drivers/firewire/fw-sbp2.c and testing with any SBP-2 device which is _not_ based on the PL3507 bridge chip. This moves the status FIFO into an area outside of PCI write posting and forces the driver stack to generate response packets. (Some PL-3507 only accept unified transactions, hence this test needs to be performed with other bridge chips.)
--
Stefan Richter
-=====-==--- --=- =-===
http://arcgraph.de/sr/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/