Skip to contentSkip to conversation

Fix mpc52xx_uart_of_assign to use correct index

PATCH In review John Rigby 2 participants 2 messages May 23, 2007

lore
Share & tools
lore

John Rigby

author
#0 lore raw

PATCH 1/1 Fix mpc52xx_uart_of_assign to use correct index

Use idx as index into mpc52xx_uart_nodes instead of i

---
 drivers/serial/mpc52xx_uart.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/serial/mpc52xx_uart.c +1 -1
index 3cc2fb9..0648017 100644
@@ -1114,7 +1114,7 @@ mpc52xx_uart_of_assign(struct device_node *np, int idx)
 	/* If the slot is already occupied, then swap slots */
 	if (mpc52xx_uart_nodes[idx] && (free_idx != -1))
 		mpc52xx_uart_nodes[free_idx] = mpc52xx_uart_nodes[idx];
-	mpc52xx_uart_nodes[i] = np;
+	mpc52xx_uart_nodes[idx] = np;
 }
 
 static void
Signature · 1 line
1.5.1.1.174.gabbf5