Archived
14
0
Fork 0

ctcm: avoid crash in ctcm_remove_device

Channels are already removed when setting a ctcm-device offline.
Thus ctcm_remove_device must not refer to channel information.
Solution: delete channel information from the trace call in
ctcm_remove_device.

Signed-off-by: Ursula Braun <ursula.braun@de.ibm.com>
Signed-off-by: Frank Blaschka <frank.blaschka@de.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Ursula Braun 2009-05-19 21:38:38 +00:00 committed by David S. Miller
parent f214856540
commit 8ac6d45228

View file

@ -1677,10 +1677,8 @@ static void ctcm_remove_device(struct ccwgroup_device *cgdev)
BUG_ON(priv == NULL);
CTCM_DBF_TEXT_(SETUP, CTC_DBF_INFO,
"removing device %s, r/w = %s/%s, proto : %d",
priv->channel[READ]->netdev->name,
priv->channel[READ]->id, priv->channel[WRITE]->id,
priv->protocol);
"removing device %p, proto : %d",
cgdev, priv->protocol);
if (cgdev->state == CCWGROUP_ONLINE)
ctcm_shutdown_device(cgdev);