|
@@ -717,7 +717,7 @@ static void st_tty_close(struct tty_struct *tty)
|
|
|
*/
|
|
*/
|
|
|
spin_lock_irqsave(&st_gdata->lock, flags);
|
|
spin_lock_irqsave(&st_gdata->lock, flags);
|
|
|
for (i = ST_BT; i < ST_MAX_CHANNELS; i++) {
|
|
for (i = ST_BT; i < ST_MAX_CHANNELS; i++) {
|
|
|
- if (st_gdata->list[i] != NULL)
|
|
|
|
|
|
|
+ if (st_gdata->is_registered[i] == true)
|
|
|
pr_err("%d not un-registered", i);
|
|
pr_err("%d not un-registered", i);
|
|
|
st_gdata->list[i] = NULL;
|
|
st_gdata->list[i] = NULL;
|
|
|
}
|
|
}
|