diff options
author | Kirill Tkhai <tkhai@yandex.ru> | 2014-02-10 13:40:11 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-11 15:43:44 -0500 |
commit | 81291dd9484dd16e795ab4a69d16b401b2aa5821 (patch) | |
tree | 96fff9d5b4e622745f27b4d659798d94999f4a03 | |
parent | f578b5d33ee721461921c8e79e5f8b309b2e604d (diff) |
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: Kirill Tkhai <tkhai@yandex.ru>
CC: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/sbe-2t3e3/module.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/sbe-2t3e3/module.c b/drivers/staging/sbe-2t3e3/module.c index 0e32be5c2471..a6f93a43d216 100644 --- a/drivers/staging/sbe-2t3e3/module.c +++ b/drivers/staging/sbe-2t3e3/module.c | |||
@@ -122,7 +122,7 @@ static void t3e3_remove_card(struct pci_dev *pdev) | |||
122 | struct channel *channel0 = pci_get_drvdata(pdev); | 122 | struct channel *channel0 = pci_get_drvdata(pdev); |
123 | struct card *card = channel0->card; | 123 | struct card *card = channel0->card; |
124 | 124 | ||
125 | del_timer(&card->timer); | 125 | del_timer_sync(&card->timer); |
126 | if (has_two_ports(channel0->pdev)) { | 126 | if (has_two_ports(channel0->pdev)) { |
127 | t3e3_remove_channel(&card->channels[1]); | 127 | t3e3_remove_channel(&card->channels[1]); |
128 | pci_dev_put(card->channels[1].pdev); | 128 | pci_dev_put(card->channels[1].pdev); |