From: leslie Date: Sat, 15 Aug 2009 07:30:29 +0000 (+0800) Subject: sasc: dvbloopback fixes (by gonzzor) X-Git-Tag: upstream/620~202 X-Git-Url: http://www.vanbest.org/gitweb/?a=commitdiff_plain;h=7f268b35ab31de1c3c260d62b3ce146f4569bfaf;p=sasc-ng.git sasc: dvbloopback fixes (by gonzzor) --- diff --git a/contrib/sasc-ng/Makefile b/contrib/sasc-ng/Makefile index 492a3d6..ce10354 100644 --- a/contrib/sasc-ng/Makefile +++ b/contrib/sasc-ng/Makefile @@ -16,7 +16,7 @@ ifdef DVB_DIR DVB_MOD_DIR = DVB_DIR=$(DVB_DIR) endif -DEFINES += -DRELEASE_VERSION=\"$(VERSION)\" +DEFINES += -DRELEASE_VERSION=\"$(VERSION)\" -D__KERNEL_STRICT_NAMES INCLUDES += -Idvbloopback/module -I/lib/modules/$(shell uname -r)/build/include LBDIR = dvbloopback/src SCDIR = sc/PLUGINS/src/$(SCVER) diff --git a/contrib/sasc-ng/dvbloopback/module/dvbdev-2.6.v4l.h b/contrib/sasc-ng/dvbloopback/module/dvbdev-2.6.v4l.h index 89d12dc..1fb5666 100644 --- a/contrib/sasc-ng/dvbloopback/module/dvbdev-2.6.v4l.h +++ b/contrib/sasc-ng/dvbloopback/module/dvbdev-2.6.v4l.h @@ -27,7 +27,6 @@ #include #include #include -#include #define DVB_MAJOR 212 @@ -62,14 +61,19 @@ struct dvb_adapter { struct device *device; struct module *module; + + int mfe_shared; /* indicates mutually exclusive frontends */ + struct dvb_device *mfe_dvbdev; /* frontend device in use */ + struct mutex mfe_lock; /* access lock for thread creation */ }; struct dvb_device { struct list_head list_head; - struct file_operations *fops; + const struct file_operations *fops; struct dvb_adapter *adapter; int type; + int minor; u32 id; /* in theory, 'users' can vanish now, diff --git a/contrib/sasc-ng/dvbloopback/src/Makefile b/contrib/sasc-ng/dvbloopback/src/Makefile deleted file mode 100644 index b938cf9..0000000 --- a/contrib/sasc-ng/dvbloopback/src/Makefile +++ /dev/null @@ -1,46 +0,0 @@ -VERSION = 0.0.2 -TOOL = forward - -CC ?= gcc -CXX ?= g++ -CXXFLAGS ?= -g -Wall -Werror -CFLAGS ?= -g -Wall - -ifdef DVB_DIR - INCLUDES = -I$(DVB_DIR)/linux/include - DVB_MOD_DIR = DVB_DIR=$(DVB_DIR) -endif - -DEFINES += -DRELEASE_VERSION=\"$(VERSION)\" -INCLUDES += -I../module - -#OBJS = forward.o process_req.o msg_passing.o plugin_getsid.o plugin_ringbuf.o \ -# plugin_dss.o version.o -OBJS = forward.o process_req.o msg_passing.o \ - plugin_dss.o version.o -LIBS = -lpthread - -INC_DEPS := $(shell ls *.h) - -all: $(TOOL) - -$(TOOL): $(OBJS) - $(CXX) $(CFLAGS) -o $(TOOL) $(OBJS) $(LIBS) - -clean: - rm -f $(OBJS) - rm version.cpp - -%.o: %.c $(INC_DEPS) - $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< - -%.o: %.cpp - $(CXX) $(CXXFLAGS) -c $(DEFINES) $(INCLUDES) $< - -version.o: version.cpp - $(CXX) $(CXXFLAGS) -o $@ -c $(DEFINES) $< - -version.cpp: FORCE - echo 'const char *source_version =' '"'`(svnversion $(shell pwd) 2>/dev/null) || echo Unknown`'";' > .vers.new ; diff .vers.new $@ > .vers.diff 2>&1 ; if test -s .vers.diff ; then mv -f .vers.new $@ ; fi ; rm -f .vers.new .vers.diff - -FORCE: diff --git a/contrib/sasc-ng/dvbloopback/src/process_req.c b/contrib/sasc-ng/dvbloopback/src/process_req.c index d1cd167..e71f352 100644 --- a/contrib/sasc-ng/dvbloopback/src/process_req.c +++ b/contrib/sasc-ng/dvbloopback/src/process_req.c @@ -117,6 +117,7 @@ void *poll_loop(void * parm) ioctl(pc->virtfd, DVBLB_CMD_ASYNC, &msg); } } + return NULL; } static cmdret_t do_cmd(struct list_head *list, struct parser_cmds *pc,