From 7e35f7f318168f1b735abc87754108c06955f50d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristian=20H=C3=B8gsberg?= Date: Wed, 14 Mar 2007 17:34:57 -0400 Subject: firewire: Free pending transactions on cdev release. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Kristian Høgsberg Signed-off-by: Stefan Richter --- drivers/firewire/fw-device-cdev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'drivers/firewire') diff --git a/drivers/firewire/fw-device-cdev.c b/drivers/firewire/fw-device-cdev.c index ebf0d100805..b1b7edb0d2a 100644 --- a/drivers/firewire/fw-device-cdev.c +++ b/drivers/firewire/fw-device-cdev.c @@ -827,8 +827,10 @@ static int fw_device_op_release(struct inode *inode, struct file *file) kfree(r); } - list_for_each_entry_safe(t, next_t, &client->transaction_list, link) + list_for_each_entry_safe(t, next_t, &client->transaction_list, link) { fw_cancel_transaction(client->device->card, &t->transaction); + kfree(t); + } /* FIXME: We should wait for the async tasklets to stop * running before freeing the memory. */ -- cgit v1.2.3