Skip to contentSkip to conversation

solos-pci: Fix regression introduced by newest firmware

PATCH Superseded Philip Prindeville 1 participant 1 message Mar 20, 2011

Subsystems (3)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 solos-pci: Fix regression introduced by newest firmware

The newest FPGA firmware on the Solos processors correctly signals carrier transitions, bitrate, etc.

The driver previously ignored these messages, and the physical state was always ATM_PHY_SIG_UNKNOWN.

Now that the board reports its state, we expose a bug whereby the transition from UNKNOWN to LOST causes us to release all VC's. It should not: only transitions from FOUND to LOST or UNKNOWN should do this (actually, it's bears examining if the VC's should be released at all).

So we add a check to the previous state on transitions for leaving FOUND state.

---

drivers/atm/solos-pci.c +4 -1
@@ -382,8 +382,11 @@ static int process_status(struct solos_c
 
 	/* Anything but 'Showtime' is down */
 	if (strcmp(state_str, "Showtime")) {
+		char old_signal = card->atmdev[port]->signal;
+
 		atm_dev_signal_change(card->atmdev[port], ATM_PHY_SIG_LOST);
-		atm_dev_release_vccs(card->atmdev[port]);
+		if (old_signal == ATM_PHY_SIG_FOUND)
+			atm_dev_release_vccs(card->atmdev[port]);
 		dev_info(&card->dev->dev, "Port %d: %s\n", port, state_str);
		return 0;
	}