linux/net/caif
Eric W. Biederman 8a8ee9aff6 net caif: Register properly as a pernet subsystem.
caif is a subsystem and as such it needs to register with
register_pernet_subsys instead of register_pernet_device.

Among other problems using register_pernet_device was resulting in
net_generic being called before the caif_net structure was allocated.
Which has been causing net_generic to fail with either BUG_ON's or by
return NULL pointers.

A more ugly problem that could be caused is packets in flight why the
subsystem is shutting down.

To remove confusion also remove the cruft cause by inappropriately
trying to fix this bug.

With the aid of the previous patch I have tested this patch and
confirmed that using register_pernet_subsys makes the failure go away as
it should.

Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Acked-by: Sjur Brændeland <sjur.brandeland@stericsson.com>
Tested-by: Sasha Levin <levinsasha928@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-01-27 21:06:03 -05:00
..
caif_dev.c net caif: Register properly as a pernet subsystem. 2012-01-27 21:06:03 -05:00
caif_socket.c
caif_usb.c caif: Fix typo in Vendor/Product-ID for CAIF modems 2012-01-17 10:46:55 -05:00
cfcnfg.c net caif: Register properly as a pernet subsystem. 2012-01-27 21:06:03 -05:00
cfctrl.c
cfdbgl.c
cfdgml.c
cffrml.c percpu: Remove irqsafe_cpu_xxx variants 2011-12-22 10:40:20 -08:00
cfmuxl.c
cfpkt_skbuff.c caif: Add support for CAIF over CDC NCM USB interface 2011-12-05 18:27:56 -05:00
cfrfml.c caif: Bad assert triggering false positive. 2011-12-06 17:21:47 -05:00
cfserl.c caif: Remove unused enum and parameter in cfserl 2011-11-30 23:30:48 -05:00
cfsrvl.c
cfutill.c
cfveil.c
cfvidl.c
chnl_net.c
Kconfig caif: Add support for CAIF over CDC NCM USB interface 2011-12-05 18:27:56 -05:00
Makefile caif: Add support for CAIF over CDC NCM USB interface 2011-12-05 18:27:56 -05:00