aboutsummaryrefslogtreecommitdiff
path: root/drivers/firewire/fw-topology.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-04-18 11:24:29 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-04-18 11:24:29 -0700
commiteddeb0e2d863e3941d8768e70cb50c6120e61fa0 (patch)
treee30f2b6654e6eb397f9d7fb23a08d717cc19b12d /drivers/firewire/fw-topology.c
parent855d854a33fca71cf68bad258bd5e66e5b265d10 (diff)
parentdb8be076cad4b843aa743ef462c75022cddd9c63 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6: (43 commits) firewire: cleanups firewire: fix synchronization of gap counts firewire: wait until PHY configuration packet was transmitted (fix bus reset loop) firewire: remove unused struct member firewire: use bitwise and to get reg in handle_registers firewire: replace more hex values with defined csr constants firewire: reread config ROM when device reset the bus firewire: replace static ROM cache by allocated cache firewire: fw-ohci: work around generation bug in TI controllers (fix AV/C and more) firewire: fw-ohci: extend logging of bus generations and node ID firewire: fw-ohci: conditionally log busReset interrupts firewire: fw-ohci: don't append to AT context when it's not active firewire: fw-ohci: log regAccessFail events firewire: fw-ohci: make sure HCControl register LPS bit is set firewire: fw-ohci: missing PPC PMac feature calls in failure path firewire: fw-ohci: untangle a mixed unsigned/signed expression firewire: debug interrupt events firewire: fw-ohci: catch self_id_count == 0 firewire: fw-ohci: add self ID error check firewire: fw-ohci: refactor probe, remove, suspend, resume ...
Diffstat (limited to 'drivers/firewire/fw-topology.c')
-rw-r--r--drivers/firewire/fw-topology.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/firewire/fw-topology.c b/drivers/firewire/fw-topology.c
index d2c7a3d7e1c..213b0ff8f3d 100644
--- a/drivers/firewire/fw-topology.c
+++ b/drivers/firewire/fw-topology.c
@@ -108,6 +108,7 @@ static struct fw_node *fw_node_create(u32 sid, int port_count, int color)
node->node_id = LOCAL_BUS | SELF_ID_PHY_ID(sid);
node->link_on = SELF_ID_LINK_ON(sid);
node->phy_speed = SELF_ID_PHY_SPEED(sid);
+ node->initiated_reset = SELF_ID_PHY_INITIATOR(sid);
node->port_count = port_count;
atomic_set(&node->ref_count, 1);
@@ -289,12 +290,11 @@ static struct fw_node *build_tree(struct fw_card *card,
beta_repeaters_present = true;
/*
- * If all PHYs does not report the same gap count
- * setting, we fall back to 63 which will force a gap
- * count reconfiguration and a reset.
+ * If PHYs report different gap counts, set an invalid count
+ * which will force a gap count reconfiguration and a reset.
*/
if (SELF_ID_GAP_COUNT(q) != gap_count)
- gap_count = 63;
+ gap_count = 0;
update_hop_count(node);
@@ -431,6 +431,8 @@ update_tree(struct fw_card *card, struct fw_node *root)
event = FW_NODE_LINK_OFF;
else if (!node0->link_on && node1->link_on)
event = FW_NODE_LINK_ON;
+ else if (node1->initiated_reset && node1->link_on)
+ event = FW_NODE_INITIATED_RESET;
else
event = FW_NODE_UPDATED;