lkml.org 
[lkml]   [2000]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectOld DC10: Patch for 0.6
Hello,

I have received a patch from Brian Flachs <flachs@umunhum.stanford.edu>
which may fix this problem with older ZR36057 chips. The patch is
available here. It must be applied against version 0.6 of the driver.

If you have the problem with older DC10 cards, please, try this patch
and send me a note whether this workaround works on your system. Also,
please, test it thoroughly and check if it breaks something that works
with out-of-the-box version 0.6. If everything is OK, this patch will
be included in the next driver release.

Best regards,
Serguei Miridonov.

------ Original message --------
Date: Tue, 17 Oct 2000 06:46:36 -0700
From: Brian Flachs <flachs@umunhum.stanford.edu>
Message-Id: <200010171346.GAA29153@umunhum.Stanford.EDU>
To: mirsev@cicese.mx
Subject: Re: version 0.6


hi,

so looking at what parameters are set when xawtv runs,
i think i have a reasonable starting point. i can
atleast start xawtv, lavrec, lavrec, lavrec successfully.

i have not made this conditional on what kind of board
is there. since other boards already work, i guess some
thing needs to be figured out there.

--- dc10.c~ Fri Oct 13 10:08:22 2000
+++ dc10.c Tue Oct 17 08:50:56 2000
@@ -1,4 +1,4 @@
-#define DEBUGLEVEL 0
+#define DEBUGLEVEL 3
#define MAX_KMALLOC_MEM (128*1024)
/*
Miro/Pinnacle Systems Inc. DC10/DC10plus and
@@ -3106,6 +3106,77 @@
}

/*
+ * this seems to be neccessary for 36057's
+ */
+
+static void zoran_reinit(struct zoran *zr)
+ {
+ int overlay_on;
+ int input;
+
+ /* reset the chip completely */
+ btwrite(0, ZR36057_SPGPPCR);
+ mdelay(1);
+ btwrite(ZR36057_SPGPPCR_SoftReset, ZR36057_SPGPPCR);
+ mdelay(1);
+
+ /* assert P_Reset */
+ btwrite(0, ZR36057_JPC);
+
+ /* set up GPIO direction - all output */
+ btwrite(ZR36057_SPGPPCR_SoftReset | 0, ZR36057_SPGPPCR);
+ btwrite((0x81 << 24) | 0x8888, ZR36057_GPPGCR1);
+
+ /* reset JPEG codec */
+ zr36060_sleep(zr, 1);
+ zr36060_reset(zr);
+
+ /* now we shall reload the chip */
+
+ /* overlay */
+ zr36057_overlay(zr, 0);
+ set_videobus_enable(zr, 0);
+
+ switch (zr->params.input)
+ {
+ case 0:
+ input = 0;
+
+ set_input:
+ i2c_control_device(&zr->i2c, I2C_DRIVERID_VIDEODECODER, DECODER_SET_INPUT, &input);
+ break;
+
+ case 1:
+ input = 7;
+ goto set_input;
+
+ case 2:
+ if(zr->card == DC10 || zr->card == DC10plus)
+ {
+ input = 5;
+ goto set_input;
+ }
+ }
+
+ i2c_control_device(&zr->i2c, I2C_DRIVERID_VIDEODECODER, DECODER_SET_NORM, &zr->params.norm);
+ i2c_control_device(&zr->i2c, I2C_DRIVERID_VIDEOENCODER, ENCODER_SET_NORM, &zr->params.norm);
+ set_videobus_enable(zr, 1);
+
+ overlay_on = zr->v4l_overlay_active && !zr->v4l_memgrab_active;
+ if (overlay_on) zr36057_overlay(zr, 1);
+
+ /* Make sure the changes come into effect */
+ wait_grab_pending(zr);
+
+ /* brightness hue and color... */
+ i2c_control_device(&zr->i2c,I2C_DRIVERID_VIDEODECODER,DECODER_SET_PICTURE,&zr->picture);
+
+ /* zr36057_set_memgrab(zr, 1) ??? */
+
+
+ }
+
+/*
* Open a zoran card. Right now the flags stuff is just playing
*/

@@ -3132,6 +3203,9 @@
}

/* default setup */
+#if 1
+ zoran_reinit(zr);
+#endif

if (zr->user == 1) { /* First device open */
zoran_open_init_params(zr);


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:41    [W:0.040 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site