search for: vsock_core_init

Displaying 20 results from an estimated 82 matches for "vsock_core_init".

2014 May 01
1
[PATCH] vsock: Make transport the proto owner
...------------------------ 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index 7d64d36..8f02e5c 100644 --- a/include/net/af_vsock.h +++ b/include/net/af_vsock.h @@ -155,7 +155,11 @@ struct vsock_transport { /**** CORE ****/ -int vsock_core_init(const struct vsock_transport *t); +int __vsock_core_init(const struct vsock_transport *t, struct module *owner); +static inline int vsock_core_init(const struct vsock_transport *t) +{ + return __vsock_core_init(t, THIS_MODULE); +} void vsock_core_exit(void); /**** UTILS ****/ diff --git a/net...
2014 May 01
1
[PATCH] vsock: Make transport the proto owner
...------------------------ 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index 7d64d36..8f02e5c 100644 --- a/include/net/af_vsock.h +++ b/include/net/af_vsock.h @@ -155,7 +155,11 @@ struct vsock_transport { /**** CORE ****/ -int vsock_core_init(const struct vsock_transport *t); +int __vsock_core_init(const struct vsock_transport *t, struct module *owner); +static inline int vsock_core_init(const struct vsock_transport *t) +{ + return __vsock_core_init(t, THIS_MODULE); +} void vsock_core_exit(void); /**** UTILS ****/ diff --git a/net...
2019 Feb 01
3
[PATCH v3 0/2] vsock/virtio: fix issues on device hot-unplug
These patches try to handle the hot-unplug of vsock virtio transport device in a proper way. Maybe move the vsock_core_init()/vsock_core_exit() functions in the module_init and module_exit of vsock_virtio_transport module can't be the best way, but the architecture of vsock_core forces us to this approach for now. The vsock_core proto_ops expect a valid pointer to the transport device, so we can't call vsock_co...
2019 Feb 01
3
[PATCH v3 0/2] vsock/virtio: fix issues on device hot-unplug
These patches try to handle the hot-unplug of vsock virtio transport device in a proper way. Maybe move the vsock_core_init()/vsock_core_exit() functions in the module_init and module_exit of vsock_virtio_transport module can't be the best way, but the architecture of vsock_core forces us to this approach for now. The vsock_core proto_ops expect a valid pointer to the transport device, so we can't call vsock_co...
2014 May 01
1
[PATCH] vsock: Make transport the proto owner
...------------------------ 2 files changed, 27 insertions(+), 26 deletions(-) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index 7d64d36..4282778 100644 --- a/include/net/af_vsock.h +++ b/include/net/af_vsock.h @@ -155,7 +155,11 @@ struct vsock_transport { /**** CORE ****/ -int vsock_core_init(const struct vsock_transport *t); +int __vsock_core_init(const struct vsock_transport *t, struct module *owner); +static inline int vsock_core_init(const struct vsock_transport *t) +{ + return __vsock_core_init(t, THIS_MODULE); +} void vsock_core_exit(void); /**** UTILS ****/ diff --git a/net/v...
2014 May 01
1
[PATCH] vsock: Make transport the proto owner
...------------------------ 2 files changed, 27 insertions(+), 26 deletions(-) diff --git a/include/net/af_vsock.h b/include/net/af_vsock.h index 7d64d36..4282778 100644 --- a/include/net/af_vsock.h +++ b/include/net/af_vsock.h @@ -155,7 +155,11 @@ struct vsock_transport { /**** CORE ****/ -int vsock_core_init(const struct vsock_transport *t); +int __vsock_core_init(const struct vsock_transport *t, struct module *owner); +static inline int vsock_core_init(const struct vsock_transport *t) +{ + return __vsock_core_init(t, THIS_MODULE); +} void vsock_core_exit(void); /**** UTILS ****/ diff --git a/net/v...
2019 May 01
3
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...index 15eb5d3d4750..96ab344f17bb 100644 --- a/net/vmw_vsock/virtio_transport.c +++ b/net/vmw_vsock/virtio_transport.c @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) if (!virtio_vsock_workqueue) return -ENOMEM; - ret = register_virtio_driver(&virtio_vsock_driver); + ret = vsock_core_init(&virtio_transport.transport); if (ret) goto out_wq; - ret = vsock_core_init(&virtio_transport.transport); + ret = register_virtio_driver(&virtio_vsock_driver); if (ret) - goto out_vdr; + goto out_vci; return 0; -out_vdr: - unregister_virtio_driver(&virtio_vsock_driv...
2019 May 01
3
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...index 15eb5d3d4750..96ab344f17bb 100644 --- a/net/vmw_vsock/virtio_transport.c +++ b/net/vmw_vsock/virtio_transport.c @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) if (!virtio_vsock_workqueue) return -ENOMEM; - ret = register_virtio_driver(&virtio_vsock_driver); + ret = vsock_core_init(&virtio_transport.transport); if (ret) goto out_wq; - ret = vsock_core_init(&virtio_transport.transport); + ret = register_virtio_driver(&virtio_vsock_driver); if (ret) - goto out_vdr; + goto out_vci; return 0; -out_vdr: - unregister_virtio_driver(&virtio_vsock_driv...
2019 May 02
2
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...nsport.c > > +++ b/net/vmw_vsock/virtio_transport.c > > @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) > > if (!virtio_vsock_workqueue) > > return -ENOMEM; > > > > - ret = register_virtio_driver(&virtio_vsock_driver); > > + ret = vsock_core_init(&virtio_transport.transport); > > Have you checked that all transport callbacks are safe even if another > CPU calls them while virtio_vsock_probe() is executing on another CPU? > I have the same doubt. What do you think to take the 'the_virtio_vsock_mutex' in the virtio...
2019 May 02
2
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...nsport.c > > +++ b/net/vmw_vsock/virtio_transport.c > > @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) > > if (!virtio_vsock_workqueue) > > return -ENOMEM; > > > > - ret = register_virtio_driver(&virtio_vsock_driver); > > + ret = vsock_core_init(&virtio_transport.transport); > > Have you checked that all transport callbacks are safe even if another > CPU calls them while virtio_vsock_probe() is executing on another CPU? > I have the same doubt. What do you think to take the 'the_virtio_vsock_mutex' in the virtio...
2019 Mar 06
2
[PATCH v2] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock
Previous to commit 22b5c0b63f32 ("vsock/virtio: fix kernel panic after device hot-unplug"), vsock_core_init() was called from virtio_vsock_probe(). Now, virtio_transport_reset_no_sock() can be called before vsock_core_init() has the chance to run. [Wed Feb 27 14:17:09 2019] BUG: unable to handle kernel NULL pointer dereference at 0000000000000110 [Wed Feb 27 14:17:09 2019] #PF error: [normal kernel read...
2019 Mar 06
2
[PATCH v2] vsock/virtio: fix kernel panic from virtio_transport_reset_no_sock
Previous to commit 22b5c0b63f32 ("vsock/virtio: fix kernel panic after device hot-unplug"), vsock_core_init() was called from virtio_vsock_probe(). Now, virtio_transport_reset_no_sock() can be called before vsock_core_init() has the chance to run. [Wed Feb 27 14:17:09 2019] BUG: unable to handle kernel NULL pointer dereference at 0000000000000110 [Wed Feb 27 14:17:09 2019] #PF error: [normal kernel read...
2019 May 01
0
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...> --- a/net/vmw_vsock/virtio_transport.c > +++ b/net/vmw_vsock/virtio_transport.c > @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) > if (!virtio_vsock_workqueue) > return -ENOMEM; > > - ret = register_virtio_driver(&virtio_vsock_driver); > + ret = vsock_core_init(&virtio_transport.transport); Have you checked that all transport callbacks are safe even if another CPU calls them while virtio_vsock_probe() is executing on another CPU? > if (ret) > goto out_wq; > > - ret = vsock_core_init(&virtio_transport.transport); > + ret = r...
2019 May 06
1
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...io_transport.c > > > @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void) > > > if (!virtio_vsock_workqueue) > > > return -ENOMEM; > > > > > > - ret = register_virtio_driver(&virtio_vsock_driver); > > > + ret = vsock_core_init(&virtio_transport.transport); > > > > Have you checked that all transport callbacks are safe even if another > > CPU calls them while virtio_vsock_probe() is executing on another CPU? > > > > I have the same doubt. > > What do you think to take the 'the_v...
2019 May 15
2
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...@ static int __init virtio_vsock_init(void) > > > > > if (!virtio_vsock_workqueue) > > > > > return -ENOMEM; > > > > > > > > > > - ret = register_virtio_driver(&virtio_vsock_driver); > > > > > + ret = vsock_core_init(&virtio_transport.transport); > > > > > > > > Have you checked that all transport callbacks are safe even if another > > > > CPU calls them while virtio_vsock_probe() is executing on another CPU? > > > > > > > > > > I have the sa...
2019 May 15
2
[PATCH] vsock/virtio: Initialize core virtio vsock before registering the driver
...@ static int __init virtio_vsock_init(void) > > > > > if (!virtio_vsock_workqueue) > > > > > return -ENOMEM; > > > > > > > > > > - ret = register_virtio_driver(&virtio_vsock_driver); > > > > > + ret = vsock_core_init(&virtio_transport.transport); > > > > > > > > Have you checked that all transport callbacks are safe even if another > > > > CPU calls them while virtio_vsock_probe() is executing on another CPU? > > > > > > > > > > I have the sa...
2019 Oct 23
0
[PATCH net-next 11/14] vsock: add multi-transports support
...multiple transports in the VSOCK core. With the multi-transports support, we can use vsock with nested VMs (using also different hypervisors) loading both guest->host and host->guest transports at the same time. Major changes: - vsock core module can be loaded regardless of the transports - vsock_core_init() and vsock_core_exit() are renamed to vsock_core_register() and vsock_core_unregister() - vsock_core_register() has a feature parameter (H2G, G2H, DGRAM) to identify which directions the transport can handle and if it's support DGRAM (only vmci) - each stream socket is assigned to a tran...
2019 Sep 27
0
[RFC PATCH 10/13] vsock: add multi-transports support
...transports at the same time. Major changes: - vsock core module can be loaded interdependently of the transports - each 'struct virtio_transport' has a new feature fields (H2G, G2H, DGRAM) to identify which directions the transport can handle and if it's support DGRAM (only vmci) - vsock_core_init() and vsock_core_exit() are renamed to vsock_core_register() and vsock_core_unregister() - each stream socket is assigned to a transport when the remote CID is set (during the connect() or when we receive a connection request on a listener socket). The remote CID is used to decide which tra...
2019 May 23
0
[PATCH 4.9 07/53] vsock/virtio: Initialize core virtio vsock before registering the driver
...hanged, 6 insertions(+), 7 deletions(-) --- a/net/vmw_vsock/virtio_transport.c +++ b/net/vmw_vsock/virtio_transport.c @@ -600,28 +600,27 @@ static int __init virtio_vsock_init(void if (!virtio_vsock_workqueue) return -ENOMEM; - ret = register_virtio_driver(&virtio_vsock_driver); + ret = vsock_core_init(&virtio_transport.transport); if (ret) goto out_wq; - ret = vsock_core_init(&virtio_transport.transport); + ret = register_virtio_driver(&virtio_vsock_driver); if (ret) - goto out_vdr; + goto out_vci; return 0; -out_vdr: - unregister_virtio_driver(&virtio_vsock_driv...
2019 May 23
0
[PATCH 4.14 09/77] vsock/virtio: Initialize core virtio vsock before registering the driver
...hanged, 6 insertions(+), 7 deletions(-) --- a/net/vmw_vsock/virtio_transport.c +++ b/net/vmw_vsock/virtio_transport.c @@ -702,28 +702,27 @@ static int __init virtio_vsock_init(void if (!virtio_vsock_workqueue) return -ENOMEM; - ret = register_virtio_driver(&virtio_vsock_driver); + ret = vsock_core_init(&virtio_transport.transport); if (ret) goto out_wq; - ret = vsock_core_init(&virtio_transport.transport); + ret = register_virtio_driver(&virtio_vsock_driver); if (ret) - goto out_vdr; + goto out_vci; return 0; -out_vdr: - unregister_virtio_driver(&virtio_vsock_driv...