o bluetooth: use revised net module infrastructure

Using THIS_MODULE in the struct proto_ops registered with the core.
parent d4cf4c22
...@@ -148,6 +148,7 @@ static int bnep_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long ...@@ -148,6 +148,7 @@ static int bnep_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
static struct proto_ops bnep_sock_ops = { static struct proto_ops bnep_sock_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.owner = THIS_MODULE,
.release = bnep_sock_release, .release = bnep_sock_release,
.ioctl = bnep_sock_ioctl, .ioctl = bnep_sock_ioctl,
.bind = sock_no_bind, .bind = sock_no_bind,
......
...@@ -553,6 +553,7 @@ int hci_sock_getsockopt(struct socket *sock, int level, int optname, char *optva ...@@ -553,6 +553,7 @@ int hci_sock_getsockopt(struct socket *sock, int level, int optname, char *optva
struct proto_ops hci_sock_ops = { struct proto_ops hci_sock_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.owner = THIS_MODULE,
.release = hci_sock_release, .release = hci_sock_release,
.bind = hci_sock_bind, .bind = hci_sock_bind,
.getname = hci_sock_getname, .getname = hci_sock_getname,
......
...@@ -2084,6 +2084,7 @@ static void __exit l2cap_proc_cleanup(void) ...@@ -2084,6 +2084,7 @@ static void __exit l2cap_proc_cleanup(void)
static struct proto_ops l2cap_sock_ops = { static struct proto_ops l2cap_sock_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.owner = THIS_MODULE,
.release = l2cap_sock_release, .release = l2cap_sock_release,
.bind = l2cap_sock_bind, .bind = l2cap_sock_bind,
.connect = l2cap_sock_connect, .connect = l2cap_sock_connect,
...@@ -2104,6 +2105,7 @@ static struct proto_ops l2cap_sock_ops = { ...@@ -2104,6 +2105,7 @@ static struct proto_ops l2cap_sock_ops = {
static struct net_proto_family l2cap_sock_family_ops = { static struct net_proto_family l2cap_sock_family_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.create = l2cap_sock_create, .create = l2cap_sock_create,
.owner = THIS_MODULE,
}; };
static struct hci_proto l2cap_hci_proto = { static struct hci_proto l2cap_hci_proto = {
......
...@@ -856,6 +856,7 @@ static void __exit rfcomm_sock_proc_cleanup(void) ...@@ -856,6 +856,7 @@ static void __exit rfcomm_sock_proc_cleanup(void)
static struct proto_ops rfcomm_sock_ops = { static struct proto_ops rfcomm_sock_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.owner = THIS_MODULE,
.release = rfcomm_sock_release, .release = rfcomm_sock_release,
.bind = rfcomm_sock_bind, .bind = rfcomm_sock_bind,
.connect = rfcomm_sock_connect, .connect = rfcomm_sock_connect,
......
...@@ -969,6 +969,7 @@ static void __exit sco_proc_cleanup(void) ...@@ -969,6 +969,7 @@ static void __exit sco_proc_cleanup(void)
static struct proto_ops sco_sock_ops = { static struct proto_ops sco_sock_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.owner = THIS_MODULE,
.release = sco_sock_release, .release = sco_sock_release,
.bind = sco_sock_bind, .bind = sco_sock_bind,
.connect = sco_sock_connect, .connect = sco_sock_connect,
...@@ -989,6 +990,7 @@ static struct proto_ops sco_sock_ops = { ...@@ -989,6 +990,7 @@ static struct proto_ops sco_sock_ops = {
static struct net_proto_family sco_sock_family_ops = { static struct net_proto_family sco_sock_family_ops = {
.family = PF_BLUETOOTH, .family = PF_BLUETOOTH,
.create = sco_sock_create, .create = sco_sock_create,
.owner = THIS_MODULE,
}; };
static struct hci_proto sco_hci_proto = { static struct hci_proto sco_hci_proto = {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment