Merge branch 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab...
authorLinus Torvalds <torvalds@woody.linux-foundation.org>
Fri, 24 Aug 2007 04:38:54 +0000 (21:38 -0700)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Fri, 24 Aug 2007 04:38:54 +0000 (21:38 -0700)
* 'master' of ssh://master.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb:
  V4L/DVB (6070): Fix a warning at dvb_net
  V4L/DVB (6042): b2c2-flexcop: fix Airstar HD5000 tuning regression

drivers/media/dvb/b2c2/flexcop-i2c.c
drivers/media/dvb/dvb-core/dvb_net.c

index 02a0ea6..6bf858a 100644 (file)
@@ -135,6 +135,13 @@ static int flexcop_master_xfer(struct i2c_adapter *i2c_adap, struct i2c_msg msgs
        struct flexcop_device *fc = i2c_get_adapdata(i2c_adap);
        int i, ret = 0;
 
+       /* Some drivers use 1 byte or 0 byte reads as probes, which this
+        * driver doesn't support.  These probes will always fail, so this
+        * hack makes them always succeed.  If one knew how, it would of
+        * course be better to actually do the read.  */
+       if (num == 1 && msgs[0].flags == I2C_M_RD && msgs[0].len <= 1)
+               return 1;
+
        if (mutex_lock_interruptible(&fc->i2c_mutex))
                return -ERESTARTSYS;
 
index acf0263..bdd7970 100644 (file)
@@ -800,7 +800,8 @@ static int dvb_net_ts_callback(const u8 *buffer1, size_t buffer1_len,
 }
 
 
-static void dvb_net_sec(struct net_device *dev, u8 *pkt, int pkt_len)
+static void dvb_net_sec(struct net_device *dev, const u8 *pkt, int
+pkt_len)
 {
        u8 *eth;
        struct sk_buff *skb;
@@ -902,7 +903,7 @@ static int dvb_net_sec_callback(const u8 *buffer1, size_t buffer1_len,
         * we rely on the DVB API definition where exactly one complete
         * section is delivered in buffer1
         */
-       dvb_net_sec (dev, (u8*) buffer1, buffer1_len);
+       dvb_net_sec (dev, buffer1, buffer1_len);
        return 0;
 }