[patch] [media] exynos4-is: cleanup a define

2013-11-08 Thread Dan Carpenter
This define is only used in s5pcsis_irq_handler():

if ((status  S5PCSIS_INTSRC_NON_IMAGE_DATA)  pktbuf-data) {

The problem is that status is a 32 bit and (0xff  28) is larger than
32 bits and that sets off a static checker warning.  I consulted with
Sylwester Nawrocki and the define should actually be (0xf  28).

Signed-off-by: Dan Carpenter dan.carpen...@oracle.com

diff --git a/drivers/media/platform/exynos4-is/mipi-csis.c 
b/drivers/media/platform/exynos4-is/mipi-csis.c
index 9fc2af6..31dfc50 100644
--- a/drivers/media/platform/exynos4-is/mipi-csis.c
+++ b/drivers/media/platform/exynos4-is/mipi-csis.c
@@ -91,7 +91,7 @@ MODULE_PARM_DESC(debug, Debug level (0-2));
 #define S5PCSIS_INTSRC_ODD_BEFORE  (1  29)
 #define S5PCSIS_INTSRC_ODD_AFTER   (1  28)
 #define S5PCSIS_INTSRC_ODD (0x3  28)
-#define S5PCSIS_INTSRC_NON_IMAGE_DATA  (0xff  28)
+#define S5PCSIS_INTSRC_NON_IMAGE_DATA  (0xf  28)
 #define S5PCSIS_INTSRC_FRAME_START (1  27)
 #define S5PCSIS_INTSRC_FRAME_END   (1  26)
 #define S5PCSIS_INTSRC_ERR_SOT_HS  (0xf  12)
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[patch] [media] v4l: ti-vpe: checking for IS_ERR() instead of NULL

2013-11-08 Thread Dan Carpenter
devm_ioremap() returns NULL on error, it doesn't return an ERR_PTR.

Signed-off-by: Dan Carpenter dan.carpen...@oracle.com

diff --git a/drivers/media/platform/ti-vpe/vpe.c 
b/drivers/media/platform/ti-vpe/vpe.c
index 4e58069..e163466 100644
--- a/drivers/media/platform/ti-vpe/vpe.c
+++ b/drivers/media/platform/ti-vpe/vpe.c
@@ -1962,8 +1962,8 @@ static int vpe_probe(struct platform_device *pdev)
 * registers based on the sub block base addresses
 */
dev-base = devm_ioremap(pdev-dev, res-start, SZ_32K);
-   if (IS_ERR(dev-base)) {
-   ret = PTR_ERR(dev-base);
+   if (!dev-base) {
+   ret = -ENOMEM;
goto v4l2_dev_unreg;
}
 
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5] videodev2: Set vb2_rect's width and height as unsigned

2013-11-08 Thread Ricardo Ribalda Delgado
Hello Laurent

Thanks for your comments

On Fri, Nov 8, 2013 at 3:42 AM, Laurent Pinchart
laurent.pinch...@ideasonboard.com wrote:
 Hi Ricardo,

 Thank you for the patch.

 On Wednesday 06 November 2013 19:42:16 Ricardo Ribalda Delgado wrote:
 As discussed on the media summit 2013, there is no reason for the width
 and height to be signed.

 Therefore this patch is an attempt to convert those fields from __s32 to
 __u32.

 Acked-by: Sakari Ailus sakari.ai...@iki.fi (documentation and smiapp)
 Signed-off-by: Ricardo Ribalda Delgado ricardo.riba...@gmail.com
 ---
 v5: Comments by Sakari Ailus
 -Fix typos in summary

 v4: Wrong patch format

 v3: Comments by Sakari Ailus
 -Update also doc

 v2: Comments by Sakari Ailus and Laurent Pinchart

 -Fix alignment on all drivers
 -Replace min with min_t where possible and remove unneeded checks

  Documentation/DocBook/media/v4l/compat.xml | 12 
  Documentation/DocBook/media/v4l/dev-overlay.xml|  8 ++---
  Documentation/DocBook/media/v4l/vidioc-cropcap.xml |  8 ++---
  drivers/media/i2c/mt9m032.c| 16 +-
  drivers/media/i2c/mt9p031.c| 28 ++
  drivers/media/i2c/mt9t001.c| 26 ++---
  drivers/media/i2c/mt9v032.c| 34  ++
  drivers/media/i2c/smiapp/smiapp-core.c |  8 ++---
  drivers/media/i2c/soc_camera/mt9m111.c |  4 +--
  drivers/media/i2c/tvp5150.c| 14 -
  drivers/media/pci/bt8xx/bttv-driver.c  |  6 ++--
  drivers/media/pci/saa7134/saa7134-video.c  |  4 ---
  drivers/media/platform/soc_camera/soc_scale_crop.c |  4 +--
  include/uapi/linux/videodev2.h |  4 +--
  14 files changed, 97 insertions(+), 79 deletions(-)

 diff --git a/Documentation/DocBook/media/v4l/compat.xml
 b/Documentation/DocBook/media/v4l/compat.xml index 0c7195e..5dbe68b 100644
 --- a/Documentation/DocBook/media/v4l/compat.xml
 +++ b/Documentation/DocBook/media/v4l/compat.xml
 @@ -2523,6 +2523,18 @@ that used it. It was originally scheduled for removal
 in 2.6.35. /orderedlist
  /section

 +section
 +  titleV4L2 in Linux 3.12/title
 +  orderedlist
 +listitem
 + para In struct structnamev4l2_rect/structname, the type
 +of structfieldwidth/structfield and structfieldheight/structfield
 +fields changed from _s32 to _u32.
 +   /para
 +/listitem
 +  /orderedlist
 +/section
 +
  section id=other
titleRelation of V4L2 to other Linux multimedia APIs/title

 diff --git a/Documentation/DocBook/media/v4l/dev-overlay.xml
 b/Documentation/DocBook/media/v4l/dev-overlay.xml index 40d1d76..a44ac66
 100644
 --- a/Documentation/DocBook/media/v4l/dev-overlay.xml
 +++ b/Documentation/DocBook/media/v4l/dev-overlay.xml
 @@ -346,16 +346,14 @@ rectangle, in pixels./entry
  rectangle, in pixels. Offsets increase to the right and down./entry
 /row
 row
 - entry__s32/entry
 + entry__u32/entry
   entrystructfieldwidth/structfield/entry
   entryWidth of the rectangle, in pixels./entry
 /row
 row
 - entry__s32/entry
 + entry__u32/entry
   entrystructfieldheight/structfield/entry
 - entryHeight of the rectangle, in pixels. Width and
 -height cannot be negative, the fields are signed for hysterical
 -reasons. !-- video4linux-l...@redhat.com on 22 Oct 2002 subject

 I like the concept of hysterical reasons :-)

 + entryHeight of the rectangle, in pixels.!--
 video4linux-l...@redhat.com on 22 Oct 2002 subject Re:[V4L][patches!]
 Re:v4l2/kernel-2.5 --/entry
 /row
   /tbody
 diff --git a/Documentation/DocBook/media/v4l/vidioc-cropcap.xml
 b/Documentation/DocBook/media/v4l/vidioc-cropcap.xml index bf7cc97..26b8f8f
 100644
 --- a/Documentation/DocBook/media/v4l/vidioc-cropcap.xml
 +++ b/Documentation/DocBook/media/v4l/vidioc-cropcap.xml
 @@ -133,16 +133,14 @@ rectangle, in pixels./entry
  rectangle, in pixels./entry
 /row
 row
 - entry__s32/entry
 + entry__u32/entry
   entrystructfieldwidth/structfield/entry
   entryWidth of the rectangle, in pixels./entry
 /row
 row
 - entry__s32/entry
 + entry__u32/entry
   entrystructfieldheight/structfield/entry
 - entryHeight of the rectangle, in pixels. Width
 -and height cannot be negative, the fields are signed for
 -hysterical reasons. !-- video4linux-l...@redhat.com
 + entryHeight of the rectangle, in pixels.!--
 video4linux-l...@redhat.com on 22 Oct 2002 subject Re:[V4L][patches!]
 Re:v4l2/kernel-2.5 -- /entry
 /row
 diff --git a/drivers/media/i2c/mt9m032.c b/drivers/media/i2c/mt9m032.c
 index 846b15f..85ec3ba 100644
 --- a/drivers/media/i2c/mt9m032.c
 +++ b/drivers/media/i2c/mt9m032.c
 @@ -459,13 +459,15 @@ static int mt9m032_set_pad_crop(struct 

Re: [patch] [media] v4l: ti-vpe: checking for IS_ERR() instead of NULL

2013-11-08 Thread Archit Taneja

Hi Dan,

On Friday 08 November 2013 03:31 PM, Dan Carpenter wrote:

devm_ioremap() returns NULL on error, it doesn't return an ERR_PTR.

Signed-off-by: Dan Carpenter dan.carpen...@oracle.com

diff --git a/drivers/media/platform/ti-vpe/vpe.c 
b/drivers/media/platform/ti-vpe/vpe.c
index 4e58069..e163466 100644
--- a/drivers/media/platform/ti-vpe/vpe.c
+++ b/drivers/media/platform/ti-vpe/vpe.c
@@ -1962,8 +1962,8 @@ static int vpe_probe(struct platform_device *pdev)
 * registers based on the sub block base addresses
 */
dev-base = devm_ioremap(pdev-dev, res-start, SZ_32K);
-   if (IS_ERR(dev-base)) {
-   ret = PTR_ERR(dev-base);
+   if (!dev-base) {
+   ret = -ENOMEM;
goto v4l2_dev_unreg;
}


Thanks for the patch, this was addressed in Wei's patch though:

v4l: ti-vpe: fix return value check in vpe_probe()

Thanks,
Archit
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5] videodev2: Set vb2_rect's width and height as unsigned

2013-11-08 Thread Sakari Ailus
On Fri, Nov 08, 2013 at 11:12:54AM +0100, Ricardo Ribalda Delgado wrote:
...
 Also I am not aware of a reason why clamp_t is better than clamp (I am
 probably wrong here). If there is a good reason for not using
 clamp_t I have no problem in reviewing again the patch and use
 unsigned constants.

clamp_t() should only be used if you need to force a type for the clamping
operation. It's always better if you don't have to, and all the arguments
are of the same type: type casting can have an effect on the end result and
bugs related to that can be difficult to find.

-- 
Kind regards,

Sakari Ailus
e-mail: sakari.ai...@iki.fi XMPP: sai...@retiisi.org.uk
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v5] videodev2: Set vb2_rect's width and height as unsigned

2013-11-08 Thread Ricardo Ribalda Delgado
Hello Sakari

On Fri, Nov 8, 2013 at 11:39 AM, Sakari Ailus sakari.ai...@iki.fi wrote:
 On Fri, Nov 08, 2013 at 11:12:54AM +0100, Ricardo Ribalda Delgado wrote:
 ...
 Also I am not aware of a reason why clamp_t is better than clamp (I am
 probably wrong here). If there is a good reason for not using
 clamp_t I have no problem in reviewing again the patch and use
 unsigned constants.

 clamp_t() should only be used if you need to force a type for the clamping
 operation. It's always better if you don't have to, and all the arguments
 are of the same type: type casting can have an effect on the end result and
 bugs related to that can be difficult to find.


But IMHO in these case, we will cause much more castings in other
places. I find more descriptive a casting via clamp_t, than via ().

Regards!

 --
 Kind regards,

 Sakari Ailus
 e-mail: sakari.ai...@iki.fi XMPP: sai...@retiisi.org.uk



-- 
Ricardo Ribalda
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [patch] [media] exynos4-is: cleanup a define

2013-11-08 Thread Sylwester Nawrocki


(dropping some unrelated e-mail addresses from Cc)

On 11/08/2013 10:52 AM, Dan Carpenter wrote:

This define is only used in s5pcsis_irq_handler():

if ((status  S5PCSIS_INTSRC_NON_IMAGE_DATA)  pktbuf-data) {

The problem is that status is a 32 bit and (0xff  28) is larger than
32 bits and that sets off a static checker warning.  I consulted with
Sylwester Nawrocki and the define should actually be (0xf  28).

Signed-off-by: Dan Carpenterdan.carpen...@oracle.com


Thanks for the fix, patch added to my tree for v3.14.


diff --git a/drivers/media/platform/exynos4-is/mipi-csis.c 
b/drivers/media/platform/exynos4-is/mipi-csis.c
index 9fc2af6..31dfc50 100644
--- a/drivers/media/platform/exynos4-is/mipi-csis.c
+++ b/drivers/media/platform/exynos4-is/mipi-csis.c
@@ -91,7 +91,7 @@ MODULE_PARM_DESC(debug, Debug level (0-2));
  #define S5PCSIS_INTSRC_ODD_BEFORE (1  29)
  #define S5PCSIS_INTSRC_ODD_AFTER  (1  28)
  #define S5PCSIS_INTSRC_ODD(0x3  28)
-#define S5PCSIS_INTSRC_NON_IMAGE_DATA  (0xff  28)
+#define S5PCSIS_INTSRC_NON_IMAGE_DATA  (0xf  28)
  #define S5PCSIS_INTSRC_FRAME_START(1  27)
  #define S5PCSIS_INTSRC_FRAME_END  (1  26)
  #define S5PCSIS_INTSRC_ERR_SOT_HS (0xf  12)


--
Regards,
Sylwester
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 3/8] Montage M88DS3103 DVB-S/S2 demodulator driver

2013-11-08 Thread Manu Abraham
On Wed, Nov 6, 2013 at 11:27 PM, Antti Palosaari cr...@iki.fi wrote:
 ---
  drivers/media/dvb-frontends/Kconfig  |7 +
  drivers/media/dvb-frontends/Makefile |1 +
  drivers/media/dvb-frontends/m88ds3103.c  | 1293 
 ++
  drivers/media/dvb-frontends/m88ds3103.h  |  108 +++
  drivers/media/dvb-frontends/m88ds3103_priv.h |  218 +
  5 files changed, 1627 insertions(+)
  create mode 100644 drivers/media/dvb-frontends/m88ds3103.c
  create mode 100644 drivers/media/dvb-frontends/m88ds3103.h
  create mode 100644 drivers/media/dvb-frontends/m88ds3103_priv.h

 diff --git a/drivers/media/dvb-frontends/Kconfig 
 b/drivers/media/dvb-frontends/Kconfig
 index bddbab4..6c46caf 100644
 --- a/drivers/media/dvb-frontends/Kconfig
 +++ b/drivers/media/dvb-frontends/Kconfig
 @@ -35,6 +35,13 @@ config DVB_STV6110x
 help
   A Silicon tuner that supports DVB-S and DVB-S2 modes

 +config DVB_M88DS3103
 +   tristate Montage M88DS3103
 +   depends on DVB_CORE  I2C
 +   default m if !MEDIA_SUBDRV_AUTOSELECT
 +   help
 + Say Y when you want to support this frontend.
 +
  comment Multistandard (cable + terrestrial) frontends
 depends on DVB_CORE

 diff --git a/drivers/media/dvb-frontends/Makefile 
 b/drivers/media/dvb-frontends/Makefile
 index f9cb43d..0c75a6a 100644
 --- a/drivers/media/dvb-frontends/Makefile
 +++ b/drivers/media/dvb-frontends/Makefile
 @@ -85,6 +85,7 @@ obj-$(CONFIG_DVB_STV6110) += stv6110.o
  obj-$(CONFIG_DVB_STV0900) += stv0900.o
  obj-$(CONFIG_DVB_STV090x) += stv090x.o
  obj-$(CONFIG_DVB_STV6110x) += stv6110x.o
 +obj-$(CONFIG_DVB_M88DS3103) += m88ds3103.o
  obj-$(CONFIG_DVB_ISL6423) += isl6423.o
  obj-$(CONFIG_DVB_EC100) += ec100.o
  obj-$(CONFIG_DVB_HD29L2) += hd29l2.o
 diff --git a/drivers/media/dvb-frontends/m88ds3103.c 
 b/drivers/media/dvb-frontends/m88ds3103.c
 new file mode 100644
 index 000..91b3729
 --- /dev/null
 +++ b/drivers/media/dvb-frontends/m88ds3103.c
 @@ -0,0 +1,1293 @@
 +/*
 + * Montage M88DS3103 demodulator driver
 + *
 + * Copyright (C) 2013 Antti Palosaari cr...@iki.fi
 + *
 + *This program is free software; you can redistribute it and/or modify
 + *it under the terms of the GNU General Public License as published by
 + *the Free Software Foundation; either version 2 of the License, or
 + *(at your option) any later version.
 + *
 + *This program is distributed in the hope that it will be useful,
 + *but WITHOUT ANY WARRANTY; without even the implied warranty of
 + *MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 + *GNU General Public License for more details.
 + *
 + *You should have received a copy of the GNU General Public License along
 + *with this program; if not, write to the Free Software Foundation, Inc.,
 + *51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
 + */
 +
 +#include m88ds3103_priv.h
 +
 +static struct dvb_frontend_ops m88ds3103_ops;
 +
 +/* write multiple registers */
 +static int m88ds3103_wr_regs(struct m88ds3103_priv *priv,
 +   u8 reg, const u8 *val, int len)
 +{
 +   int ret;
 +   u8 buf[1 + len];
 +   struct i2c_msg msg[1] = {
 +   {
 +   .addr = priv-cfg-i2c_addr,
 +   .flags = 0,
 +   .len = sizeof(buf),
 +   .buf = buf,
 +   }
 +   };
 +
 +   buf[0] = reg;
 +   memcpy(buf[1], val, len);
 +
 +   mutex_lock(priv-i2c_mutex);
 +   ret = i2c_transfer(priv-i2c, msg, 1);
 +   mutex_unlock(priv-i2c_mutex);
 +   if (ret == 1) {
 +   ret = 0;
 +   } else {
 +   dev_warn(priv-i2c-dev,
 +   %s: i2c wr failed=%d reg=%02x len=%d\n,
 +   KBUILD_MODNAME, ret, reg, len);
 +   ret = -EREMOTEIO;
 +   }
 +
 +   return ret;
 +}
 +
 +/* read multiple registers */
 +static int m88ds3103_rd_regs(struct m88ds3103_priv *priv,
 +   u8 reg, u8 *val, int len)
 +{
 +   int ret;
 +   u8 buf[len];
 +   struct i2c_msg msg[2] = {
 +   {
 +   .addr = priv-cfg-i2c_addr,
 +   .flags = 0,
 +   .len = 1,
 +   .buf = reg,
 +   }, {
 +   .addr = priv-cfg-i2c_addr,
 +   .flags = I2C_M_RD,
 +   .len = sizeof(buf),
 +   .buf = buf,
 +   }
 +   };
 +
 +   mutex_lock(priv-i2c_mutex);
 +   ret = i2c_transfer(priv-i2c, msg, 2);
 +   mutex_unlock(priv-i2c_mutex);
 +   if (ret == 2) {
 +   memcpy(val, buf, len);
 +   ret = 0;
 +   } else {
 +   dev_warn(priv-i2c-dev,
 +   %s: i2c rd failed=%d reg=%02x len=%d\n,
 +   KBUILD_MODNAME, ret, reg, len);
 +   

Re: [PATCH 3/8] Montage M88DS3103 DVB-S/S2 demodulator driver

2013-11-08 Thread Antti Palosaari

On 09.11.2013 04:35, Manu Abraham wrote:

On Wed, Nov 6, 2013 at 11:27 PM, Antti Palosaari cr...@iki.fi wrote:




+/*
+ * Driver implements own I2C-adapter for tuner I2C access. That's since chip
+ * has I2C-gate control which closes gate automatically after I2C transfer.
+ * Using own I2C adapter we can workaround that.
+ */



Why should the demodulator implement it's own adapter for tuner access ?


In order to implement it properly.



DS3103 is identical to DS3002, DS3000 which is similar to all other
dvb demodulators. Comparing datsheets of these demodulators
with others, I can't see any difference in the repeater setup, except
for an additional bit field to control the repeater block itself.

Also, from what I see, the vendor; Montage has a driver, which appears
to be more code complete looking at this url. http://goo.gl/biaPYu

Do you still think the DS3103 is much different in comparison ?


There was even some patches, maybe 2 years, ago in order to mainline 
that but it never happened.


More complete is here 53 vs. 86 register writes, so yes it is more ~40 
more complete if you like to compare it like that.


regards
Antti

--
http://palosaari.fi/
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 3/8] Montage M88DS3103 DVB-S/S2 demodulator driver

2013-11-08 Thread Manu Abraham
On Sat, Nov 9, 2013 at 8:18 AM, Antti Palosaari cr...@iki.fi wrote:
 On 09.11.2013 04:35, Manu Abraham wrote:

 On Wed, Nov 6, 2013 at 11:27 PM, Antti Palosaari cr...@iki.fi wrote:



 +/*
 + * Driver implements own I2C-adapter for tuner I2C access. That's since
 chip
 + * has I2C-gate control which closes gate automatically after I2C
 transfer.
 + * Using own I2C adapter we can workaround that.
 + */



 Why should the demodulator implement it's own adapter for tuner access ?


 In order to implement it properly.



 DS3103 is identical to DS3002, DS3000 which is similar to all other
 dvb demodulators. Comparing datsheets of these demodulators
 with others, I can't see any difference in the repeater setup, except
 for an additional bit field to control the repeater block itself.

 Also, from what I see, the vendor; Montage has a driver, which appears
 to be more code complete looking at this url. http://goo.gl/biaPYu

 Do you still think the DS3103 is much different in comparison ?


DS3000 demodulator datasheet states:

To avoid unwanted noise disturbing the tuner performance, the
M88DS3000 offers a 2-wire bus repeater dedicated for tuner
control. The tuner is connected to the M88DS3000 through the
SCLT and SDAT pins. See Figure 11. Every time the 2-wire bus
master wants to access the tuner registers, it must enable the
repeater first. When the repeater is enabled, the SDAT and SCLT
pins are active. The messages on the SDA and SCL pins is
repeated on the SDAT and SCLT pins. The repeater will be
automatically disabled once the access times to the tuner
reaches the configured value. When disabled, the SCLT and
SDAT pins are completely isolated from the 2-wire bus and
become inactive (HIGH).

DS3002 demodulator datasheet states:

To avoid unwanted noise disturbing the tuner performance, the
M88DS3002B offers a 2-wire bus repeater dedicated for tuner
control. The tuner is connected to the M88DS3002B through
the SCLT and SDAT pins. See Figure 12. Every time the 2-wire
bus master wants to access the tuner registers, it must enable
the repeater first by configuring bit 2_WIRE_REP_EN (03H).
When the repeater is enabled, the SDAT and SCLT pins are
active. The messages on the SDA and SCL pins is repeated
on the SDAT and SCLT pins. The repeater will be automatically
disabled once the access times to the tuner reaches the
configured value set in bits 2_WIRE_REP_TM[2:0] (03H).
When disabled, the SCLT and SDAT pins are completely
isolated from the 2-wire bus and become inactive (HIGH).

DS3013 demodulator datasheet states:

To avoid unwanted noise disturbing the tuner performance, the
M88DS3103 offers a 2-wire bus repeater dedicated for tuner
control. The tuner is connected to the M88DS3103 through the
SCLT and SDAT pins. See Figure 12. Every time the 2-wire bus
master wants to access the tuner registers, it must enable the
repeater first by configuring bit 2_WIRE_REP_EN (03H). When
the repeater is enabled, the SDAT and SCLT pins are active.
The messages on the SDA and SCL pins is repeated on the
SDAT and SCLT pins. The repeater will be automatically
disabled once the access times to the tuner reaches the
configured value set in bits 2_WIRE_REP_TM[2:0] (03H).
When disabled, the SCLT and SDAT pins are completely
isolated from the 2-wire bus and become inactive (HIGH).

When you compare this with *almost* any other demodulator
that exists; This behaviour is much consistent with that which
exists in the mainline kernel source.


If you look at most DVB-S/S2 demodulator drivers almost all
of them do have an I2C repeater, which in some cases are
configurable for a) auto-manual close, b) auto close,
c) manual close. The majority of them do auto close,
unless bugs on the hardware implementation do exist.

What I don't understand why you need an I2C adapter to handle
the I2C repeater. All demodulator drivers use i2c_gate_ctl
to enable/disable the repeater.

ie, how is your i2c_adapter implementation for the ds3103
demodulator going to make things better than:

static int ds3103_i2c_gate_ctrl(struct dvb_frontend *fe, int enable)
{
struct ds3103_state *state = fe-demodulator_priv;

if (enable)
ds3103_writereg(state, 0x03, 0x12);
else
ds3103_writereg(state, 0x03, 0x02);

return 0;
}

which is more common to all other DVB demodulator drivers.
Please don't make weird implementations for straight forward
stuff.


 There was even some patches, maybe 2 years, ago in order to mainline that
 but it never happened.

??


 More complete is here 53 vs. 86 register writes, so yes it is more ~40 more
 complete if you like to compare it like that.

What I would stress more, is that the driver at this URL

http://goo.gl/biaPYu

is from Montage themselves rather than a reverse engineered one;
rather than the number of lines of code, or number of registers.
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org

cron job: media_tree daily build: WARNINGS

2013-11-08 Thread Hans Verkuil
This message is generated daily by a cron job that builds media_tree for
the kernels and architectures in the list below.

Results of the daily build of media_tree:

date:   Sat Nov  9 04:00:19 CET 2013
git branch: for-v3.13c
git hash:   3adeac2c34cc28e05d0ec52f38f009dcce278555
gcc version:i686-linux-gcc (GCC) 4.8.1
sparse version: 0.4.5-rc1
host hardware:  x86_64
host os:3.12-0.slh.1-amd64

linux-git-arm-at91: OK
linux-git-arm-davinci: OK
linux-git-arm-exynos: OK
linux-git-arm-mx: OK
linux-git-arm-omap: OK
linux-git-arm-omap1: OK
linux-git-arm-pxa: OK
linux-git-blackfin: OK
linux-git-i686: OK
linux-git-m32r: OK
linux-git-mips: OK
linux-git-powerpc64: OK
linux-git-sh: OK
linux-git-x86_64: OK
linux-2.6.31.14-i686: OK
linux-2.6.32.27-i686: OK
linux-2.6.33.7-i686: OK
linux-2.6.34.7-i686: OK
linux-2.6.35.9-i686: OK
linux-2.6.36.4-i686: OK
linux-2.6.37.6-i686: OK
linux-2.6.38.8-i686: OK
linux-2.6.39.4-i686: OK
linux-3.0.60-i686: OK
linux-3.1.10-i686: OK
linux-3.2.37-i686: OK
linux-3.3.8-i686: OK
linux-3.4.27-i686: OK
linux-3.5.7-i686: OK
linux-3.6.11-i686: OK
linux-3.7.4-i686: OK
linux-3.8-i686: OK
linux-3.9.2-i686: OK
linux-3.10.1-i686: OK
linux-3.11.1-i686: OK
linux-3.12-i686: OK
linux-2.6.31.14-x86_64: OK
linux-2.6.32.27-x86_64: OK
linux-2.6.33.7-x86_64: OK
linux-2.6.34.7-x86_64: OK
linux-2.6.35.9-x86_64: OK
linux-2.6.36.4-x86_64: OK
linux-2.6.37.6-x86_64: OK
linux-2.6.38.8-x86_64: OK
linux-2.6.39.4-x86_64: OK
linux-3.0.60-x86_64: OK
linux-3.1.10-x86_64: OK
linux-3.2.37-x86_64: OK
linux-3.3.8-x86_64: OK
linux-3.4.27-x86_64: OK
linux-3.5.7-x86_64: OK
linux-3.6.11-x86_64: OK
linux-3.7.4-x86_64: OK
linux-3.8-x86_64: OK
linux-3.9.2-x86_64: OK
linux-3.10.1-x86_64: OK
linux-3.11.1-x86_64: OK
linux-3.12-x86_64: OK
apps: WARNINGS
spec-git: OK
sparse version: 0.4.5-rc1
sparse: ERRORS

Detailed results are available here:

http://www.xs4all.nl/~hverkuil/logs/Saturday.log

Full logs are available here:

http://www.xs4all.nl/~hverkuil/logs/Saturday.tar.bz2

The Media Infrastructure API from this daily build is here:

http://www.xs4all.nl/~hverkuil/spec/media.html
--
To unsubscribe from this list: send the line unsubscribe linux-media in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html