Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dvb_net: Simplify the code if DVB NET is not defined

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

+3 -10
+3 -10
drivers/media/dvb/dvb-core/dvb_net.h
··· 42 42 struct dmx_demux *demux; 43 43 }; 44 44 45 - 46 45 void dvb_net_release(struct dvb_net *); 47 46 int dvb_net_init(struct dvb_adapter *, struct dvb_net *, struct dmx_demux *); 48 47 49 - #endif 50 - 51 - #ifndef CONFIG_DVB_NET 52 - 53 - struct dvb_dev_stub; 48 + #else 54 49 55 50 struct dvb_net { 56 - struct dvb_dev_stub *dvbdev; 51 + struct dvb_device *dvbdev; 57 52 }; 58 53 59 54 static inline void dvb_net_release(struct dvb_net *dvbnet) 60 55 { 61 - dvbnet->dvbdev = 0; 62 56 } 63 57 64 58 static inline int dvb_net_init(struct dvb_adapter *adap, 65 59 struct dvb_net *dvbnet, struct dmx_demux *dmx) 66 60 { 67 - dvbnet->dvbdev = (void *)1; 68 61 return 0; 69 62 } 70 63 71 - #endif 64 + #endif /* ifdef CONFIG_DVB_NET */ 72 65 73 66 #endif