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

[media] Make DVB NET configurable in the kernel

Signed-off-by: Hans Petter Selasky <hselasky@c2i.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>

authored by

Hans Petter Selasky and committed by
Mauro Carvalho Chehab
a34ff6cd 4522e825

+40 -2
+11 -1
drivers/media/Kconfig
··· 68 68 69 69 config DVB_CORE 70 70 tristate "DVB for Linux" 71 - depends on NET && INET 72 71 select CRC32 73 72 help 74 73 DVB core utility functions for device handling, software fallbacks etc. ··· 83 84 mailing list. 84 85 85 86 If unsure say N. 87 + 88 + config DVB_NET 89 + bool "DVB Network Support" 90 + default (NET && INET) 91 + depends on NET && INET 92 + help 93 + The DVB network support in the DVB core can 94 + optionally be disabled if this 95 + option is set to N. 96 + 97 + If unsure say Y. 86 98 87 99 config VIDEO_MEDIA 88 100 tristate
+3 -1
drivers/media/dvb/dvb-core/Makefile
··· 2 2 # Makefile for the kernel DVB device drivers. 3 3 # 4 4 5 + dvb-net-$(CONFIG_DVB_NET) := dvb_net.o 6 + 5 7 dvb-core-objs := dvbdev.o dmxdev.o dvb_demux.o dvb_filter.o \ 6 8 dvb_ca_en50221.o dvb_frontend.o \ 7 - dvb_net.o dvb_ringbuffer.o dvb_math.o 9 + $(dvb-net-y) dvb_ringbuffer.o dvb_math.o 8 10 9 11 obj-$(CONFIG_DVB_CORE) += dvb-core.o
+26
drivers/media/dvb/dvb-core/dvb_net.h
··· 32 32 33 33 #define DVB_NET_DEVICES_MAX 10 34 34 35 + #ifdef CONFIG_DVB_NET 36 + 35 37 struct dvb_net { 36 38 struct dvb_device *dvbdev; 37 39 struct net_device *device[DVB_NET_DEVICES_MAX]; ··· 45 43 46 44 void dvb_net_release(struct dvb_net *); 47 45 int dvb_net_init(struct dvb_adapter *, struct dvb_net *, struct dmx_demux *); 46 + 47 + #endif 48 + 49 + #ifndef CONFIG_DVB_NET 50 + 51 + struct dvb_dev_stub; 52 + 53 + struct dvb_net { 54 + struct dvb_dev_stub *dvbdev; 55 + }; 56 + 57 + static inline void dvb_net_release(struct dvb_net *dvbnet) 58 + { 59 + dvbnet->dvbdev = 0; 60 + } 61 + 62 + static inline int dvb_net_init(struct dvb_adapter *adap, 63 + struct dvb_net *dvbnet, struct dmx_demux *dmx) 64 + { 65 + dvbnet->dvbdev = (void *)1; 66 + return 0; 67 + } 68 + 69 + #endif 48 70 49 71 #endif