[PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2010-07-01 Thread Michael Krufky
Mauro,

Please pull from:

http://kernellabs.com/hg/~mkrufky/k2c2

for:

- cx23885: add support for new model revisions of the HVR12xx board family

 Documentation/video4linux/CARDLIST.cx23885  |6 -
 drivers/media/video/cx23885/cx23885-cards.c |   40 ++
 2 files changed, 43 insertions(+), 3 deletions(-)

Cheers,

Mike
--
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


[RESEND PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-07-01 Thread Michael Krufky
Mauro,

Resending this pull request for the 4th time.  You've agreed to merge
this last month.

This change should go to Linus for 2.6.31 -- Please send this to him
with your first round of bugfixes for 2.6.31

Please pull from:

http://kernellabs.com/hg/~mkrufky/k2c2

for:

- cx23885: override set_frontend to allow rf input path switching on the HVR1275
- cx23885: add FIXME comment above set_frontend override

 cx23885-dvb.c |   30 ++
 cx23885.h |4 
 2 files changed, 34 insertions(+)


Regards,

Mike
--
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: [RESEND PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-07-01 Thread Mauro Carvalho Chehab
Em Wed, 1 Jul 2009 08:04:55 -0400
Michael Krufky mkru...@kernellabs.com escreveu:

 Mauro,
 
 Resending this pull request for the 4th time.  You've agreed to merge
 this last month.
 
 This change should go to Linus for 2.6.31 -- Please send this to him
 with your first round of bugfixes for 2.6.31
 
 Please pull from:
 
 http://kernellabs.com/hg/~mkrufky/k2c2

Argh! I was not noticing that your tree were causing merge conflicts with mine:

$ ./v4l/scripts/do_merge.pl http://kernellabs.com/hg/~mkrufky/k2c2
Checking if everything is ok, before applying the new tree.
hg pull http://kernellabs.com/hg/~mkrufky/k2c2
pulling from http://kernellabs.com/hg/~mkrufky/k2c2
searching for changes
adding changesets
adding manifests
adding file changes
added 2 changesets with 4 changes to 2 files (+1 heads)
(run 'hg heads' to see heads, 'hg merge' to merge)
Merging the new changesets
merging linux/drivers/media/video/cx23885/cx23885-dvb.c
warning: conflicts during merge.
merging linux/drivers/media/video/cx23885/cx23885-dvb.c failed!
merging linux/drivers/media/video/cx23885/cx23885.h
0 files updated, 1 files merged, 0 files removed, 1 files unresolved
use 'hg resolve' to retry unresolved file merges
hg merge failed. Can't procceed.
*** ERROR *** Rolling back hg pull http://kernellabs.com/hg/~mkrufky/k2c2
rolling back last transaction
2 files updated, 0 files merged, 0 files removed, 0 files unresolved

This probably happened since the first time you sent me the patch. I've patched
the do_merge.pl script to print a louder error message to be easier for
noticing when a pull request failed.

What's even more weird is that applying the patches manually work fine. So, I
suspect that somehow your tree is corrupted. Another possibility is that some
patches between your patch parent and tip changed something at the same place
you're touching, and hg couldn't solve the conflict.

To avoid even more troubles with this, I've manually picked the two patches and
applied with ./mailimport script. Please, re-generate this tree, since the
hash of the patches has changed.



Cheers,
Mauro
--
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: [RESEND PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-07-01 Thread Michael Krufky
On Wed, Jul 1, 2009 at 9:18 AM, Mauro Carvalho
Chehabmche...@infradead.org wrote:
 Em Wed, 1 Jul 2009 08:04:55 -0400
 Michael Krufky mkru...@kernellabs.com escreveu:

 Mauro,

 Resending this pull request for the 4th time.  You've agreed to merge
 this last month.

 This change should go to Linus for 2.6.31 -- Please send this to him
 with your first round of bugfixes for 2.6.31

 Please pull from:

 http://kernellabs.com/hg/~mkrufky/k2c2

 Argh! I was not noticing that your tree were causing merge conflicts with 
 mine:

 $ ./v4l/scripts/do_merge.pl http://kernellabs.com/hg/~mkrufky/k2c2
 Checking if everything is ok, before applying the new tree.
 hg pull http://kernellabs.com/hg/~mkrufky/k2c2
 pulling from http://kernellabs.com/hg/~mkrufky/k2c2
 searching for changes
 adding changesets
 adding manifests
 adding file changes
 added 2 changesets with 4 changes to 2 files (+1 heads)
 (run 'hg heads' to see heads, 'hg merge' to merge)
 Merging the new changesets
 merging linux/drivers/media/video/cx23885/cx23885-dvb.c
 warning: conflicts during merge.
 merging linux/drivers/media/video/cx23885/cx23885-dvb.c failed!
 merging linux/drivers/media/video/cx23885/cx23885.h
 0 files updated, 1 files merged, 0 files removed, 1 files unresolved
 use 'hg resolve' to retry unresolved file merges
 hg merge failed. Can't procceed.
 *** ERROR *** Rolling back hg pull http://kernellabs.com/hg/~mkrufky/k2c2
 rolling back last transaction
 2 files updated, 0 files merged, 0 files removed, 0 files unresolved

 This probably happened since the first time you sent me the patch. I've 
 patched
 the do_merge.pl script to print a louder error message to be easier for
 noticing when a pull request failed.

 What's even more weird is that applying the patches manually work fine. So, I
 suspect that somehow your tree is corrupted. Another possibility is that some
 patches between your patch parent and tip changed something at the same place
 you're touching, and hg couldn't solve the conflict.

 To avoid even more troubles with this, I've manually picked the two patches 
 and
 applied with ./mailimport script. Please, re-generate this tree, since the
 hash of the patches has changed.

Thanks for merging it.

There's only one problem now -- I had the patches marked as HIGH
priority, but now it is marked NORMAL -- Can you please make sure to
send this change to Linus for 2.6.31?

Thanks again.

Regards,

Mike
--
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: [PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-06-16 Thread Michael Krufky

Michael Krufky wrote:

Mauro Carvalho Chehab wrote:

Em Tue, 16 Jun 2009 11:19:29 -0400
Michael Krufky mkru...@linuxtv.org escreveu:

 

Mauro,

Please pull from:

http://kernellabs.com/hg/~mkrufky/k2c2

for:

- cx23885: override set_frontend to allow rf input path switching on 
the HVR1275


 cx23885-dvb.c |   29 +
 cx23885.h |2 ++
 2 files changed, 31 insertions(+)

Hopefully, you can get this into the next merge window with all the
other pending changesets ;-)

Thanks  regards,

Mike




 

Use separate RF input spigots for Antennae and Cable.

Priority: normal

Reviewed-by: Steven Toth st...@kernellabs.com
Signed-off-by: Michael Krufky mkru...@kernellabs.com

--- a/linux/drivers/media/video/cx23885/cx23885-dvb.cTue May 12 
17:53:47 2009 -0400
+++ b/linux/drivers/media/video/cx23885/cx23885-dvb.cFri May 08 
21:39:24 2009 -0400

@@ -417,6 +417,30 @@
 .demod_address = 0x05,
 };
 
+static int cx23885_dvb_set_frontend(struct dvb_frontend *fe,

+struct dvb_frontend_parameters *param)
+{
+struct cx23885_tsport *port = fe-dvb-priv;
+struct cx23885_dev *dev = port-dev;
+
+switch (dev-board) {
+case CX23885_BOARD_HAUPPAUGE_HVR1275:
+switch (param-u.vsb.modulation) {
+case VSB_8:
+cx23885_gpio_clear(dev, GPIO_5);
+break;
+case QAM_64:
+case QAM_256:
+default:
+cx23885_gpio_set(dev, GPIO_5);
+break;
+}
+break;
+}
+return (port-set_frontend_save) ?
+port-set_frontend_save(fe, param) : -ENODEV;
+}
+
 static int dvb_register(struct cx23885_tsport *port)
 {
 struct cx23885_dev *dev = port-dev;
@@ -456,6 +480,11 @@
0x60, dev-i2c_bus[1].i2c_adap,
hauppauge_hvr127x_config);
 }
+
+/* define bridge override to set_frontend */
+port-set_frontend_save = fe0-dvb.frontend-ops.set_frontend;
+fe0-dvb.frontend-ops.set_frontend = 
cx23885_dvb_set_frontend;

+
 break;
 case CX23885_BOARD_HAUPPAUGE_HVR1255:
 i2c_bus = dev-i2c_bus[0];
--- a/linux/drivers/media/video/cx23885/cx23885.hTue May 12 
17:53:47 2009 -0400
+++ b/linux/drivers/media/video/cx23885/cx23885.hFri May 08 
21:39:24 2009 -0400

@@ -288,6 +288,8 @@
 /* Allow a single tsport to have multiple frontends */
 u32num_frontends;
 void   *port_priv;
+int (*set_frontend_save) (struct dvb_frontend *,
+  struct dvb_frontend_parameters *);
 };
 
 struct cx23885_dev {





Argh! this looks like a hack! Don't you have a better approach for it?



I have a better approach that I plan to push for the next kernel.  
This is planned for 2.6.31, for 2.6.32 I have a better method that 
will be genericly used for all drivers.


I plan to post an RFC about the new method after the merge window closes.

Can you merge this for now, and the new, better method can be saved 
for the next devel cycle?


I'd just like to add a point:

The method used in this patch is the same method currently used inside 
the dib0700 driver (grep for set_param_save in struct dib0700_adapter_state)


This is the minimal patch for the current merge window -- I'd like to 
merge this one for now, and when the merge window closes, I will issue 
the RFC for the new, better method, while converting dib0700 and cx23885 
both to use this new better method.


Once that is done, this sort of thing will be much clearer and easier to 
accomplish across other drivers in the susbsystem tree.


I have added a FIXME comment as per your request...

Please pull from:

http://kernellabs.com/hg/~mkrufky/k2c2

for the following:

- cx23885: override set_frontend to allow rf input path switching on the 
HVR1275

- cx23885: add FIXME comment above set_frontend override

cx23885-dvb.c |   30 ++
cx23885.h |4 
2 files changed, 34 insertions(+)

Cheers,

Mike


--
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: [PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-06-16 Thread Michael Krufky

Mauro Carvalho Chehab wrote:

Em Tue, 16 Jun 2009 11:19:29 -0400
Michael Krufky mkru...@linuxtv.org escreveu:

  

Mauro,

Please pull from:

http://kernellabs.com/hg/~mkrufky/k2c2

for:

- cx23885: override set_frontend to allow rf input path switching on the HVR1275

 cx23885-dvb.c |   29 +
 cx23885.h |2 ++
 2 files changed, 31 insertions(+)

Hopefully, you can get this into the next merge window with all the
other pending changesets ;-)

Thanks  regards,

Mike




  

Use separate RF input spigots for Antennae and Cable.

Priority: normal

Reviewed-by: Steven Toth st...@kernellabs.com
Signed-off-by: Michael Krufky mkru...@kernellabs.com

--- a/linux/drivers/media/video/cx23885/cx23885-dvb.c   Tue May 12 17:53:47 
2009 -0400
+++ b/linux/drivers/media/video/cx23885/cx23885-dvb.c   Fri May 08 21:39:24 
2009 -0400
@@ -417,6 +417,30 @@
.demod_address = 0x05,
 };
 
+static int cx23885_dvb_set_frontend(struct dvb_frontend *fe,

+   struct dvb_frontend_parameters *param)
+{
+   struct cx23885_tsport *port = fe-dvb-priv;
+   struct cx23885_dev *dev = port-dev;
+
+   switch (dev-board) {
+   case CX23885_BOARD_HAUPPAUGE_HVR1275:
+   switch (param-u.vsb.modulation) {
+   case VSB_8:
+   cx23885_gpio_clear(dev, GPIO_5);
+   break;
+   case QAM_64:
+   case QAM_256:
+   default:
+   cx23885_gpio_set(dev, GPIO_5);
+   break;
+   }
+   break;
+   }
+   return (port-set_frontend_save) ?
+   port-set_frontend_save(fe, param) : -ENODEV;
+}
+
 static int dvb_register(struct cx23885_tsport *port)
 {
struct cx23885_dev *dev = port-dev;
@@ -456,6 +480,11 @@
   0x60, dev-i2c_bus[1].i2c_adap,
   hauppauge_hvr127x_config);
}
+
+   /* define bridge override to set_frontend */
+   port-set_frontend_save = fe0-dvb.frontend-ops.set_frontend;
+   fe0-dvb.frontend-ops.set_frontend = cx23885_dvb_set_frontend;
+
break;
case CX23885_BOARD_HAUPPAUGE_HVR1255:
i2c_bus = dev-i2c_bus[0];
--- a/linux/drivers/media/video/cx23885/cx23885.h   Tue May 12 17:53:47 
2009 -0400
+++ b/linux/drivers/media/video/cx23885/cx23885.h   Fri May 08 21:39:24 
2009 -0400
@@ -288,6 +288,8 @@
/* Allow a single tsport to have multiple frontends */
u32num_frontends;
void   *port_priv;
+   int (*set_frontend_save) (struct dvb_frontend *,
+ struct dvb_frontend_parameters *);
 };
 
 struct cx23885_dev {





Argh! this looks like a hack! Don't you have a better approach for it?



I have a better approach that I plan to push for the next kernel.  This 
is planned for 2.6.31, for 2.6.32 I have a better method that will be 
genericly used for all drivers.


I plan to post an RFC about the new method after the merge window closes.

Can you merge this for now, and the new, better method can be saved for 
the next devel cycle?


Thanks  Regards,

Mike
--
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: [PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-06-16 Thread Trent Piepho
On Tue, 16 Jun 2009, Mauro Carvalho Chehab wrote:
 Em Tue, 16 Jun 2009 11:19:29 -0400
 Michael Krufky mkru...@linuxtv.org escreveu:
  +static int cx23885_dvb_set_frontend(struct dvb_frontend *fe,
  +   struct dvb_frontend_parameters *param)

You could make this an HVR1275 specific function and then do away with the
first case statement.  With a name like cx23885_dvb_set_frontend() it
appears that all boards will use it, when it is only ever called with an
HVR1275.

  +   switch (param-u.vsb.modulation) {
  +   case VSB_8:
  +   cx23885_gpio_clear(dev, GPIO_5);
  +   break;
  +   case QAM_64:
  +   case QAM_256:
  +   default:
  +   cx23885_gpio_set(dev, GPIO_5);
  +   break;

Using the modulation to switch inputs is of course a hack, needed because
the dvb api lacks a concept of multiple inputs.  I do not know if any still
exist, but there were cable systems which broadcast with both QAM and VS.


 Argh! this looks like a hack! Don't you have a better approach for it?

--
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: [PULL] http://kernellabs.com/hg/~mkrufky/k2c2

2009-06-16 Thread Michael Krufky
On Tue, Jun 16, 2009 at 7:59 PM, Trent Piephoxy...@speakeasy.org wrote:
 On Tue, 16 Jun 2009, Mauro Carvalho Chehab wrote:
 Em Tue, 16 Jun 2009 11:19:29 -0400
 Michael Krufky mkru...@linuxtv.org escreveu:
  +static int cx23885_dvb_set_frontend(struct dvb_frontend *fe,
  +                               struct dvb_frontend_parameters *param)

 You could make this an HVR1275 specific function and then do away with the
 first case statement.  With a name like cx23885_dvb_set_frontend() it
 appears that all boards will use it, when it is only ever called with an
 HVR1275.

Actually, it *will* be used by other boards.  For now it is
HVR1275-specific.  The other changes will come after the close of the
merge window.


  +           switch (param-u.vsb.modulation) {
  +           case VSB_8:
  +                   cx23885_gpio_clear(dev, GPIO_5);
  +                   break;
  +           case QAM_64:
  +           case QAM_256:
  +           default:
  +                   cx23885_gpio_set(dev, GPIO_5);
  +                   break;

 Using the modulation to switch inputs is of course a hack, needed because
 the dvb api lacks a concept of multiple inputs.  I do not know if any still
 exist, but there were cable systems which broadcast with both QAM and VS.

By design on this board, VSB uses one input, QAM uses the other.

Cheers,

Mike
--
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