linux/net/vmw_vsock
Stefan Hajnoczi 05e489b159 VSOCK: make af_vsock.ko removable again
Commit c1eef220c1 ("vsock: always call
vsock_init_tables()") introduced a module_init() function without a
corresponding module_exit() function.

Modules with an init function can only be removed if they also have an
exit function.  Therefore the vsock module was considered "permanent"
and could not be removed.

This patch adds an empty module_exit() function so that "rmmod vsock"
works.  No explicit cleanup is required because:

1. Transports call vsock_core_exit() upon exit and cannot be removed
   while sockets are still alive.
2. vsock_diag.ko does not perform any action that requires cleanup by
   vsock.ko.

Fixes: c1eef220c1 ("vsock: always call vsock_init_tables()")
Reported-by: Xiumei Mu <xmu@redhat.com>
Cc: Cong Wang <xiyou.wangcong@gmail.com>
Cc: Jorgen Hansen <jhansen@vmware.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Jorgen Hansen <jhansen@vmware.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-04-17 09:44:30 -04:00
..
Kconfig VSOCK: add sock_diag interface 2017-10-05 18:44:17 -07:00
Makefile Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-11-04 09:26:51 +09:00
af_vsock.c VSOCK: make af_vsock.ko removable again 2018-04-17 09:44:30 -04:00
af_vsock_tap.c VSOCK: Add vsockmon tap functions 2017-04-24 12:35:56 -04:00
diag.c VSOCK: add sock_diag interface 2017-10-05 18:44:17 -07:00
hyperv_transport.c VSOCK: fix outdated sk_state value in hvs_release() 2017-12-05 15:07:37 -05:00
virtio_transport.c VSOCK: use TCP state constants for sk_state 2017-10-05 18:44:17 -07:00
virtio_transport_common.c VSOCK: use TCP state constants for sk_state 2017-10-05 18:44:17 -07:00
vmci_transport.c VSOCK: Don't set sk_state to TCP_CLOSE before testing it 2017-11-28 16:01:50 -05:00
vmci_transport.h
vmci_transport_notify.c VSOCK: use TCP state constants for sk_state 2017-10-05 18:44:17 -07:00
vmci_transport_notify.h
vmci_transport_notify_qstate.c VSOCK: use TCP state constants for sk_state 2017-10-05 18:44:17 -07:00
vsock_addr.c