Johannes Thumshirn
5d9e2ab9fe
mcb: Implement bus->dev.release callback
The mcb_bus structure previously was released in mcb_release_bus. This lead to
the following warning on module unload:
------------[ cut here ]------------
WARNING: CPU: 1 PID: 2032 at drivers/base/core.c:251 device_release+0x73/0x90
Device 'mcb:0' does not have a release() function, it is broken and must be fixed.
Modules linked in: men_z135_uart mcb_pci(-) mcb
CPU: 1 PID: 2032 Comm: rmmod Not tainted 4.6.0-rc4+ #3
Hardware name: N/A N/A/COMe-mBTi10, BIOS MVV1R921 X64 10/14/2015
00000286 00000286 c0117de4 c12d6f16 c0117e2c c18be0d3 c0117dfc c104f6e1
000000fb f5ccbe08 f5ccbe00 f5c64600 c0117e18 c104f728 00000009 00000000
c0117e10 c18db674 c0117e2c c0117e3c c13ce5c3 c18be0d3 000000fb c18db674
Call Trace:
[<c12d6f16>] dump_stack+0x47/0x61
[<c104f6e1>] __warn+0xc1/0xe0
[<c104f728>] warn_slowpath_fmt+0x28/0x30
[<c13ce5c3>] device_release+0x73/0x90
[<c12d92e4>] kobject_release+0x34/0x80
[<c12d929d>] ? kobject_del+0x2d/0x40
[<c12d9205>] kobject_put+0x25/0x50
[<c13ce77f>] put_device+0xf/0x20
[<c13d114b>] klist_devices_put+0xb/0x10
[<c1752673>] klist_next+0x73/0xf0
[<c13d1140>] ? unbind_store+0x100/0x100
[<f8a23370>] ? mcb_bus_add_devices+0x30/0x30 [mcb]
[<c13d0a81>] bus_for_each_dev+0x51/0x80
[<f8a23319>] mcb_release_bus+0x19/0x40 [mcb]
[<f8a23370>] ? mcb_bus_add_devices+0x30/0x30 [mcb]
[<f8a2b033>] mcb_pci_remove+0x13/0x20 [mcb_pci]
[<c130d358>] pci_device_remove+0x28/0xb0
[<c13d201b>] __device_release_driver+0x7b/0x110
[<c13d2847>] driver_detach+0x87/0x90
[<c13d1b9b>] bus_remove_driver+0x3b/0x80
[<c13d2ed0>] driver_unregister+0x20/0x50
[<c130be53>] pci_unregister_driver+0x13/0x60
[<f8a2b1f4>] mcb_pci_driver_exit+0xd/0xf [mcb_pci]
[<c10be588>] SyS_delete_module+0x138/0x200
[<c1159208>] ? ____fput+0x8/0x10
[<c1068054>] ? task_work_run+0x74/0x90
[<c1001879>] do_fast_syscall_32+0x69/0x120
[<c1757597>] sysenter_past_esp+0x40/0x6a
---[ end trace 1ed34c2aa3019875 ]---
Release a mcb_bus' memory on the device's release callback, to avoid above
warning.
Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Reported-by: Andreas Werner <andreas.werner@men.de>
Tested-by: Andreas Werner <andreas.werner@men.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-05-03 15:52:28 -07:00
..
2016-04-02 01:17:36 +02:00
2016-05-01 14:20:04 -07:00
2016-03-01 16:38:16 -08:00
2016-03-18 20:06:46 -07:00
2016-03-17 21:38:27 -07:00
2016-04-07 22:23:47 +02:00
2016-03-07 14:41:08 +02:00
2016-04-15 15:44:10 -07:00
2016-03-10 19:51:29 +01:00
2016-04-12 12:35:07 -07:00
2016-05-01 14:20:04 -07:00
2016-03-29 16:31:16 -07:00
2016-03-24 10:32:42 -07:00
2016-04-08 21:46:05 +02:00
2016-03-21 15:50:28 +01:00
2016-03-23 06:12:39 -07:00
2016-03-17 02:30:16 +01:00
2016-04-16 22:52:03 +05:30
2016-03-21 09:26:45 +01:00
2016-03-16 08:36:55 -07:00
2016-04-04 08:32:45 +09:00
2016-03-25 08:52:25 -07:00
2016-04-16 15:37:05 -07:00
2016-04-08 11:49:47 +02:00
2016-04-14 13:06:19 +10:00
2016-04-11 12:31:09 -07:00
2016-05-01 09:23:14 -07:00
2016-03-27 10:37:48 -07:00
2016-05-03 14:59:30 -07:00
2016-04-09 08:36:44 +02:00
2016-03-20 16:59:27 -04:00
2016-04-07 22:11:08 +02:00
2016-04-04 13:45:10 -07:00
2016-04-07 18:16:20 -07:00
2016-03-25 16:59:11 -07:00
2016-04-07 14:51:47 +02:00
2016-03-23 12:02:29 +01:00
2016-03-27 22:38:12 -04:00
2016-03-23 17:20:59 -07:00
2016-04-01 08:58:13 +02:00
2016-03-18 18:10:38 -07:00
2016-04-14 18:40:47 -07:00
2016-05-03 15:52:28 -07:00
2016-04-17 11:24:46 -04:00
2016-04-05 06:47:50 -07:00
2016-05-01 14:20:04 -07:00
2016-03-25 16:37:42 -07:00
2016-03-18 10:15:11 -07:00
2016-05-03 15:07:35 -07:00
2016-04-14 11:40:01 +02:00
2016-04-15 15:25:09 -07:00
2016-04-08 15:52:45 -04:00
2016-03-19 10:05:34 -07:00
2016-03-26 11:44:33 -04:00
2016-04-15 14:59:41 -06:00
2016-04-14 14:04:50 -06:00
2016-05-01 14:01:13 -07:00
2016-03-19 15:15:07 -07:00
2016-04-04 10:41:08 -07:00
2016-03-16 14:45:55 -07:00
2016-04-30 13:56:46 -07:00
2016-04-30 14:01:37 -07:00
2016-03-29 22:48:53 +02:00
2016-03-21 11:36:17 +00:00
2016-03-05 12:22:41 -08:00
2016-04-01 15:21:27 +02:00
2016-04-02 18:35:05 -05:00
2016-03-09 23:50:55 +01:00
2016-03-25 16:55:37 -07:00
2016-04-05 03:44:48 +02:00
2016-03-15 12:13:56 -07:00
2016-04-14 16:54:00 +02:00
2016-04-02 18:35:05 -05:00
2016-03-18 10:15:11 -07:00
2016-03-28 16:19:00 -07:00
2016-03-24 22:49:08 -07:00
2016-04-01 07:15:54 -05:00
2016-04-09 12:00:42 -07:00
2016-03-04 12:12:08 +01:00
2016-03-20 15:40:32 -07:00
2016-04-04 10:05:49 -07:00
2016-04-30 14:15:56 -07:00
2016-04-09 12:09:37 -07:00
2016-03-30 20:06:44 -07:00
2016-03-18 14:10:57 +08:00
2016-03-31 20:49:39 -07:00
2016-05-01 14:11:12 -07:00
2016-04-13 12:06:18 -07:00
2016-03-17 13:05:09 -07:00
2016-03-22 12:41:14 -07:00
2016-04-30 14:01:37 -07:00
2016-04-07 15:16:39 +03:00
2016-05-01 14:00:00 -07:00
2016-05-01 14:37:49 -07:00
2016-03-22 15:36:02 -07:00
2016-04-04 11:18:00 +01:00