Doug Chalmers wrote:
> Yes Andy, it is a Canadian card. I see nothing about tveeprom, in either 
> dmesg, or syslog.
> 
> # modprobe -r cx18 ivtv tveeprom
> # modprobe tveeprom debug=1
> # modprobe cx18
> 
> /var/log/messages
> 
> Mar 28 18:07:48 slack kernel: cx18-0: Initializing card #0
> Mar 28 18:07:48 slack kernel: cx18-0: Autodetected Hauppauge card
> Mar 28 18:07:48 slack kernel: ACPI: PCI Interrupt 0000:02:04.0[A] -> 
> Link [LNKA] -> GSI 5 (level, low) -> IRQ 5
> Mar 28 18:07:48 slack kernel: cx18-0: cx23418 revision 01010000 (B)
> Mar 28 18:07:48 slack kernel: tveeprom 0-0050: Huh, no eeprom present 
> (err=-121)?

Hmm, -121 is -EREMOTEIO from the i2c_algo_bit module when the tveeprom
module tries to initiate communications with the EEPROM device over the
i2c bus, using the cx23418 as the i2c master.  

This indicates an i2c communications problem between the cx23418 and the
EEPROM (and likely other i2c devices) on the card.  To see what phase of
the transaction is failing, you could turn on debugging in
i2c-algo-bit.ko.  If i2c-algo-bit.ko was compiled with debugging,
modinfo should show an i2c_debug parameter

# modinfo i2c_algo_bit
filename:       
/lib/modules/2.6.23.14-64.fc7/kernel/drivers/i2c/algos/i2c-algo-bit.ko
license:        GPL
description:    I2C-Bus bit-banging algorithm
author:         Simon G. Vogl <[EMAIL PROTECTED]>
depends:        i2c-core
vermagic:       2.6.23.14-64.fc7 SMP mod_unload 
parm:           bit_test:Test the lines of the bus to see if it is stuck (bool)
parm:           i2c_debug:debug level - 0 off; 1 normal; 2 verbose; 3 very 
verbose

You'd want this module to load with with the option "i2c_debug=3" to see
the exact phase in which the i2c transfer is failing.

That however, won't solve the problem.  There's probably something wrong
in cx18-i2c.c.  As a complete guess, you could try this:.  In
cx18-i2c.c:init_cx18_i2c, unconditionally reset the I2C functional block
of the cx23418.  Find the statements:

        if (read_reg(CX18_REG_I2C_2_WR) != 0x0003c02f) {
                /* Reset/Unreset I2C hardware block */
                write_reg(0x10000000, 0xc71004); /* Clock select 220MHz */
                write_reg(0x10001000, 0xc71024); /* Clock Enable */
        }


And get rid of the condition, so that the block is always reset upon
driver load:

        /* if (read_reg(CX18_REG_I2C_2_WR) != 0x0003c02f) { */
        if (1) {
                /* Reset/Unreset I2C hardware block */
                write_reg(0x10000000, 0xc71004); /* Clock select 220MHz */
                write_reg(0x10001000, 0xc71024); /* Clock Enable */
        }

Recompile, unload the cx18 driver, and reload the newly compiled cx18
module.

Again, this is just a shot in the dark, but I suppose it's better than
doing nothing.

Regards,
Andy


_______________________________________________
ivtv-users mailing list
[email protected]
http://ivtvdriver.org/mailman/listinfo/ivtv-users

Reply via email to