Commit 81291dd9 authored by Kirill Tkhai's avatar Kirill Tkhai Committed by Greg Kroah-Hartman

staging: sbe-2t3e3: Fix possible reuse of freed memory in timer function

Do not call kfree() till timer function is finished.

[This was found using grep. Compilation tested only]
Signed-off-by: default avatarKirill Tkhai <tkhai@yandex.ru>
CC: Joe Perches <joe@perches.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f578b5d3
......@@ -122,7 +122,7 @@ static void t3e3_remove_card(struct pci_dev *pdev)
struct channel *channel0 = pci_get_drvdata(pdev);
struct card *card = channel0->card;
del_timer(&card->timer);
del_timer_sync(&card->timer);
if (has_two_ports(channel0->pdev)) {
t3e3_remove_channel(&card->channels[1]);
pci_dev_put(card->channels[1].pdev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment