diff options
-rw-r--r-- | linux/drivers/media/dvb/cinergyT2/cinergyT2.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/dvb/frontends/zl10353.c | 2 | ||||
-rw-r--r-- | linux/drivers/media/video/mxb.c | 10 | ||||
-rw-r--r-- | linux/drivers/media/video/tda9840.c | 12 | ||||
-rw-r--r-- | linux/drivers/media/video/tea6415c.c | 12 | ||||
-rw-r--r-- | linux/drivers/media/video/tea6420.c | 12 | ||||
-rwxr-xr-x | mailimport | 35 |
7 files changed, 71 insertions, 16 deletions
diff --git a/linux/drivers/media/dvb/cinergyT2/cinergyT2.c b/linux/drivers/media/dvb/cinergyT2/cinergyT2.c index 10ed8b8c0..57ab7b0f3 100644 --- a/linux/drivers/media/dvb/cinergyT2/cinergyT2.c +++ b/linux/drivers/media/dvb/cinergyT2/cinergyT2.c @@ -523,6 +523,9 @@ static int cinergyt2_open (struct inode *inode, struct file *file) static void cinergyt2_unregister(struct cinergyt2 *cinergyt2) { + dvb_net_release(&cinergyt2->dvbnet); + dvb_dmxdev_release(&cinergyt2->dmxdev); + dvb_dmx_release(&cinergyt2->demux); dvb_unregister_device(cinergyt2->fedev); dvb_unregister_adapter(&cinergyt2->adapter); @@ -955,6 +958,7 @@ static int cinergyt2_probe (struct usb_interface *intf, return 0; bailout: + dvb_net_release(&cinergyt2->dvbnet); dvb_dmxdev_release(&cinergyt2->dmxdev); dvb_dmx_release(&cinergyt2->demux); dvb_unregister_adapter(&cinergyt2->adapter); diff --git a/linux/drivers/media/dvb/frontends/zl10353.c b/linux/drivers/media/dvb/frontends/zl10353.c index c1510ebb8..10bb871fa 100644 --- a/linux/drivers/media/dvb/frontends/zl10353.c +++ b/linux/drivers/media/dvb/frontends/zl10353.c @@ -91,7 +91,7 @@ static int zl10353_read_register(struct zl10353_state *state, u8 reg) } #if 1 -void zl10353_dump_regs(struct dvb_frontend *fe) +static void zl10353_dump_regs(struct dvb_frontend *fe) { struct zl10353_state *state = fe->demodulator_priv; char buf[52], buf2[4]; diff --git a/linux/drivers/media/video/mxb.c b/linux/drivers/media/video/mxb.c index 9391d06a0..cedefda72 100644 --- a/linux/drivers/media/video/mxb.c +++ b/linux/drivers/media/video/mxb.c @@ -1,7 +1,7 @@ /* mxb - v4l2 driver for the Multimedia eXtension Board - Copyright (C) 1998-2003 Michael Hunold <michael@mihu.de> + Copyright (C) 1998-2006 Michael Hunold <michael@mihu.de> Visit http://www.mihu.de/linux/saa7146/mxb/ for further details about this card. @@ -329,6 +329,7 @@ static int mxb_init_done(struct saa7146_dev* dev) struct video_decoder_init init; struct i2c_msg msg; struct tuner_setup tun_setup; + v4l2_std_id std = V4L2_STD_PAL_BG; int i = 0, err = 0; struct tea6415c_multiplex vm; @@ -363,6 +364,9 @@ static int mxb_init_done(struct saa7146_dev* dev) mxb->tuner->driver->command(mxb->tuner, VIDIOC_S_FREQUENCY, &mxb->cur_freq); + /* set a default video standard */ + mxb->tuner->driver->command(mxb->tuner, VIDIOC_S_STD, &std); + /* mute audio on tea6420s */ mxb->tea6420_1->driver->command(mxb->tea6420_1,TEA6420_SWITCH, &TEA6420_line[6][0]); mxb->tea6420_2->driver->command(mxb->tea6420_2,TEA6420_SWITCH, &TEA6420_line[6][1]); @@ -923,17 +927,21 @@ static int std_callback(struct saa7146_dev* dev, struct saa7146_standard *std) int one = 1; if(V4L2_STD_PAL_I == std->id ) { + v4l2_std_id std = V4L2_STD_PAL_I; DEB_D(("VIDIOC_S_STD: setting mxb for PAL_I.\n")); /* set the 7146 gpio register -- I don't know what this does exactly */ saa7146_write(dev, GPIO_CTRL, 0x00404050); /* unset the 7111 gpio register -- I don't know what this does exactly */ mxb->saa7111a->driver->command(mxb->saa7111a,DECODER_SET_GPIO, &zero); + mxb->tuner->driver->command(mxb->tuner, VIDIOC_S_STD, &std); } else { + v4l2_std_id std = V4L2_STD_PAL_BG; DEB_D(("VIDIOC_S_STD: setting mxb for PAL/NTSC/SECAM.\n")); /* set the 7146 gpio register -- I don't know what this does exactly */ saa7146_write(dev, GPIO_CTRL, 0x00404050); /* set the 7111 gpio register -- I don't know what this does exactly */ mxb->saa7111a->driver->command(mxb->saa7111a,DECODER_SET_GPIO, &one); + mxb->tuner->driver->command(mxb->tuner, VIDIOC_S_STD, &std); } return 0; } diff --git a/linux/drivers/media/video/tda9840.c b/linux/drivers/media/video/tda9840.c index f39e4f54c..9cc13ec8e 100644 --- a/linux/drivers/media/video/tda9840.c +++ b/linux/drivers/media/video/tda9840.c @@ -24,6 +24,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include "compat.h" + #include <linux/module.h> #include <linux/ioctl.h> #include <linux/i2c.h> @@ -221,10 +223,18 @@ static int detach(struct i2c_client *client) } static struct i2c_driver driver = { +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)) &&(LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)) .owner = THIS_MODULE, +#endif +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) .name = "tda9840", - .id = I2C_DRIVERID_TDA9840, .flags = I2C_DF_NOTIFY, +#else + .driver = { + .name = "tda9840", + }, +#endif + .id = I2C_DRIVERID_TDA9840, .attach_adapter = attach, .detach_client = detach, .command = command, diff --git a/linux/drivers/media/video/tea6415c.c b/linux/drivers/media/video/tea6415c.c index ad09e4c1c..12e83ad21 100644 --- a/linux/drivers/media/video/tea6415c.c +++ b/linux/drivers/media/video/tea6415c.c @@ -26,6 +26,8 @@ Foundation, Inc., 675 Mvss Ave, Cambridge, MA 02139, USA. */ +#include "compat.h" + #include <linux/module.h> #include <linux/ioctl.h> #include <linux/i2c.h> @@ -190,10 +192,18 @@ static int command(struct i2c_client *client, unsigned int cmd, void *arg) } static struct i2c_driver driver = { +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)) &&(LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)) .owner = THIS_MODULE, +#endif +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) .name = "tea6415c", - .id = I2C_DRIVERID_TEA6415C, .flags = I2C_DF_NOTIFY, +#else + .driver = { + .name = "tea6415c", + }, +#endif + .id = I2C_DRIVERID_TEA6415C, .attach_adapter = attach, .detach_client = detach, .command = command, diff --git a/linux/drivers/media/video/tea6420.c b/linux/drivers/media/video/tea6420.c index dd8279ad5..d22eac01b 100644 --- a/linux/drivers/media/video/tea6420.c +++ b/linux/drivers/media/video/tea6420.c @@ -26,6 +26,8 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include "compat.h" + #include <linux/module.h> #include <linux/ioctl.h> #include <linux/i2c.h> @@ -167,10 +169,18 @@ static int command(struct i2c_client *client, unsigned int cmd, void *arg) } static struct i2c_driver driver = { +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0)) &&(LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)) .owner = THIS_MODULE, +#endif +#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15) .name = "tea6420", - .id = I2C_DRIVERID_TEA6420, .flags = I2C_DF_NOTIFY, +#else + .driver = { + .name = "tea6420", + }, +#endif + .id = I2C_DRIVERID_TEA6420, .attach_adapter = attach, .detach_client = detach, .command = command, diff --git a/mailimport b/mailimport index b563eecd9..e6e4df411 100755 --- a/mailimport +++ b/mailimport @@ -28,6 +28,10 @@ if [ "$TMPDIR" == "" ]; then TMPDIR=/tmp fi +if [ "$EDITOR" == "" ]; then + EDITOR=nano +fi + DIR=$TMPDIR/mailimport$$ mkdir $DIR if [ "$?" != "0" ]; then @@ -39,26 +43,35 @@ TMP2=$DIR/patchheader apply_patch () { next=$1 - pdir=linux - echo patch -s -t -p1 --dry-run -l -N -d $pdir -i $next - patch -s -t -p1 --dry-run -l -N -d $pdir -i $next - if [ "$?" != "0" ]; then - pdir=. + unset cont + until [ "$cont" == "0" ]; do + cont=1 + pdir=linux echo patch -s -t -p1 --dry-run -l -N -d $pdir -i $next patch -s -t -p1 --dry-run -l -N -d $pdir -i $next if [ "$?" != "0" ]; then - $head $next + pdir=. + echo patch -s -t -p1 --dry-run -l -N -d $pdir -i $next + patch -s -t -p1 --dry-run -l -N -d $pdir -i $next + fi + + if [ "$?" != "0" ]; then echo "*** ERROR: Patch didn't applied well" if [ "$exitonerror" != "" ]; then + $head $next exit - else - return fi + echo "** Edit file $next" + sleep 1 + $EDITOR $next + else + echo "Patch applied OK against $pdir" + cont=0 fi - fi + done - nano $next + $EDITOR $next unset cont until [ "$cont" == "0" ]; do @@ -68,7 +81,7 @@ apply_patch () { if [ "`grep '^Bad:' $TMP2`" != "" ]; then echo "*** ERROR: Patch bad formed. Please fix." sleep 1 - nano $next + $EDITOR $next cont=1 fi done |