aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ieee1394/csr1212.h
diff options
context:
space:
mode:
authorStefan Richter <stefanr@s5r6.in-berlin.de>2008-12-13 17:12:06 -0500
committerStefan Richter <stefanr@s5r6.in-berlin.de>2009-01-04 17:50:34 -0500
commit0bed1819687b50a769a1fee6d91cb0ef79b011b4 (patch)
treebc5c36dda1f8e8de697ca3bb2b4d170cb77183c6 /drivers/ieee1394/csr1212.h
parentc1fc58d63d754b82070881c62601551464afa19d (diff)
ieee1394: ignore nonzero Bus_Info_Block.max_rom, fetch config ROM in quadlets
It is already known that buggy firmwares exist which report a bogus link_spd in their config ROM bus info block. We now got the first report of a bogus max_rom too (Freecom FireWire Hard Drive 1TB, http://bugzilla.kernel.org/show_bug.cgi?id=12206). I suspect other OSs only use quadlet reads to fetch the config ROM, otherwise the firmware authors would have noticed their mistake. Hence limit ieee1394's config ROM fetching routine to quadlets as the safe minimum regardless of what the bus info block says. This will potentially slow the bus reset handling by nodemgr somewhat down. But most existing devices support only quadlet reads anyway, hence there will often be no actual difference to before this change. Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Diffstat (limited to 'drivers/ieee1394/csr1212.h')
-rw-r--r--drivers/ieee1394/csr1212.h7
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/ieee1394/csr1212.h b/drivers/ieee1394/csr1212.h
index 043039fc63e..aced168f1be 100644
--- a/drivers/ieee1394/csr1212.h
+++ b/drivers/ieee1394/csr1212.h
@@ -200,7 +200,7 @@ struct csr1212_bus_ops {
200 * entries located in the Units Space. Must return 0 on success 200 * entries located in the Units Space. Must return 0 on success
201 * anything else indicates an error. */ 201 * anything else indicates an error. */
202 int (*bus_read) (struct csr1212_csr *csr, u64 addr, 202 int (*bus_read) (struct csr1212_csr *csr, u64 addr,
203 u16 length, void *buffer, void *private); 203 void *buffer, void *private);
204 204
205 /* This function is used by csr1212 to allocate a region in units space 205 /* This function is used by csr1212 to allocate a region in units space
206 * in the event that Config ROM entries don't all fit in the predefined 206 * in the event that Config ROM entries don't all fit in the predefined
@@ -211,11 +211,6 @@ struct csr1212_bus_ops {
211 /* This function is used by csr1212 to release a region in units space 211 /* This function is used by csr1212 to release a region in units space
212 * that is no longer needed. */ 212 * that is no longer needed. */
213 void (*release_addr) (u64 addr, void *private); 213 void (*release_addr) (u64 addr, void *private);
214
215 /* This function is used by csr1212 to determine the max read request
216 * supported by a remote node when reading the ConfigROM space. Must
217 * return 0, 1, or 2 per IEEE 1212. */
218 int (*get_max_rom) (u32 *bus_info, void *private);
219}; 214};
220 215
221 216