Zhang Xiaoxu
60b6d38add
cifs: Fix memory leak on the deferred close
...
commit ca08d0eac020d48a3141dbec0a3cf64fbdb17cde upstream.
xfstests on smb21 report kmemleak as below:
unreferenced object 0xffff8881767d6200 (size 64):
comm "xfs_io", pid 1284, jiffies 4294777434 (age 20.789s)
hex dump (first 32 bytes):
80 5a d0 11 81 88 ff ff 78 8a aa 63 81 88 ff ff .Z......x..c....
00 71 99 76 81 88 ff ff 00 00 00 00 00 00 00 00 .q.v............
backtrace:
[<00000000ad04e6ea>] cifs_close+0x92/0x2c0
[<0000000028b93c82>] __fput+0xff/0x3f0
[<00000000d8116851>] task_work_run+0x85/0xc0
[<0000000027e14f9e>] do_exit+0x5e5/0x1240
[<00000000fb492b95>] do_group_exit+0x58/0xe0
[<00000000129a32d9>] __x64_sys_exit_group+0x28/0x30
[<00000000e3f7d8e9>] do_syscall_64+0x35/0x80
[<00000000102e8a0b>] entry_SYSCALL_64_after_hwframe+0x46/0xb0
When cancel the deferred close work, we should also cleanup the struct
cifs_deferred_close.
Fixes: 9e992755be8f2 ("cifs: Call close synchronously during unlink/rename/lease break.")
Fixes: e3fc065682ebb ("cifs: Deferred close performance improvements")
Cc: stable@vger.kernel.org
Reviewed-by: Shyam Prasad N <sprasad@microsoft.com>
Signed-off-by: Zhang Xiaoxu <zhangxiaoxu5@huawei.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-08-25 11:45:09 +02:00
..
2022-06-17 06:03:30 +09:00
2022-05-09 16:21:44 -04:00
2022-05-09 16:21:44 -04:00
2022-07-14 10:10:12 +02:00
2022-05-09 16:21:45 -04:00
2022-05-09 16:21:44 -04:00
2022-08-25 11:45:08 +02:00
2022-07-05 16:12:21 +01:00
2022-07-14 10:10:12 +02:00
2022-08-25 11:45:09 +02:00
2022-05-09 16:21:45 -04:00
2022-02-22 18:30:28 +01:00
2022-05-09 16:21:45 -04:00
2022-05-09 16:18:54 -07:00
2022-02-25 11:56:13 +01:00
2022-01-24 14:17:02 +01:00
2022-05-02 11:23:49 -05:00
2022-05-09 16:21:45 -04:00
2022-05-09 16:21:45 -04:00
2022-08-17 15:14:21 +02:00
2022-06-09 21:26:32 +09:00
2022-04-28 16:31:10 +02:00
2022-08-17 15:14:00 +02:00
2022-08-17 15:16:17 +02:00
2022-08-17 15:16:02 +02:00
2022-05-27 11:22:03 -07:00
2022-06-03 10:34:34 -07:00
2022-07-05 16:12:55 +01:00
2022-08-17 15:15:56 +02:00
2022-05-24 19:55:07 -07:00
2022-05-09 23:12:34 -04:00
2022-05-09 23:12:34 -04:00
2022-05-09 16:21:45 -04:00
2022-05-09 16:21:45 -04:00
2022-06-16 19:11:32 -07:00
2022-05-24 19:55:07 -07:00
2022-05-09 16:21:45 -04:00
2022-08-17 15:15:43 +02:00
2022-06-03 14:42:24 -07:00
2022-05-27 15:59:21 -07:00
2022-08-17 15:15:26 +02:00
2022-08-17 15:13:54 +02:00
2022-08-17 15:13:42 +02:00
2022-05-09 16:21:44 -04:00
2022-07-14 10:10:12 +02:00
2022-08-17 15:13:40 +02:00
2022-08-17 15:13:40 +02:00
2022-07-03 15:42:33 -07:00
2022-06-28 11:18:13 +02:00
2022-07-18 15:07:52 -07:00
2022-06-03 16:57:16 -07:00
2022-07-18 15:09:15 -07:00
2022-05-09 16:21:44 -04:00
2022-03-22 15:57:03 -07:00
2022-05-09 23:12:53 -04:00
2022-08-17 15:13:48 +02:00
2022-08-17 15:15:54 +02:00
2022-03-15 11:08:23 -07:00
2022-05-09 16:21:44 -04:00
2022-05-09 16:21:44 -04:00
2022-06-06 10:08:10 +02:00
2021-11-09 10:11:53 -08:00
2022-05-09 23:12:34 -04:00
2022-05-09 16:21:46 -04:00
2022-05-23 20:24:12 -05:00
2022-05-24 19:55:07 -07:00
2022-04-05 15:39:19 +02:00
2022-05-27 11:22:03 -07:00
2022-06-17 19:01:28 -04:00
2022-06-03 14:42:24 -07:00
2022-05-24 19:55:07 -07:00
2022-05-09 16:21:44 -04:00
2022-02-14 10:37:32 +09:00
2022-05-09 16:21:46 -04:00
2022-05-24 19:55:07 -07:00
2022-07-01 09:09:52 -07:00
2022-06-08 19:13:55 +09:00
2022-04-01 19:57:03 -07:00
2022-08-17 15:13:46 +02:00
2022-03-08 12:55:29 -06:00
2022-03-03 20:38:56 -08:00
2022-04-15 14:49:56 -07:00
2022-04-22 10:57:18 -07:00
2022-02-09 09:50:02 -08:00
2022-05-09 23:12:34 -04:00
2022-03-03 20:38:56 -08:00
2022-03-28 17:29:53 -07:00
2021-11-06 13:30:32 -07:00
2022-05-27 15:49:30 -07:00
2022-03-22 15:57:03 -07:00
2022-04-17 19:50:02 -06:00
2022-08-17 15:13:59 +02:00
2022-08-17 15:16:06 +02:00
2022-05-09 18:20:49 -07:00
2022-06-04 18:52:00 -07:00
2022-06-05 15:03:03 -04:00
2022-01-18 09:23:19 +02:00
2021-12-09 14:09:36 -05:00
2022-06-06 09:54:30 +02:00
2022-05-19 23:25:10 -04:00
2022-06-06 09:54:30 +02:00
2022-06-04 19:00:05 -07:00
2022-04-01 19:35:56 -07:00
2022-04-28 23:16:15 -07:00
2022-05-30 10:56:18 -07:00
2022-05-09 16:21:44 -04:00
2022-05-19 12:25:39 -04:00
2022-08-17 15:14:20 +02:00
2022-08-17 15:13:56 +02:00
2022-05-09 23:12:34 -04:00
2022-08-17 15:16:06 +02:00
2022-06-04 19:00:05 -07:00
2022-05-31 14:10:54 -07:00
2022-05-27 11:22:03 -07:00
2022-04-19 10:19:02 -07:00
2021-12-03 18:44:06 +01:00
2022-07-26 19:38:46 -07:00
2022-07-14 15:35:24 -07:00
2022-01-11 09:03:05 -08:00
2022-05-22 21:03:01 +01:00
2022-01-17 05:49:30 +02:00
2022-08-17 15:14:49 +02:00
2022-05-31 14:10:54 -07:00
2022-04-17 19:49:59 -06:00
2022-04-26 13:36:25 -07:00
2022-01-22 08:33:36 +02:00
2022-07-26 18:25:01 -07:00
2022-04-24 18:18:37 -06:00