From owner-freebsd-multimedia@FreeBSD.ORG Mon Dec 11 04:32:37 2006 Return-Path: X-Original-To: multimedia@FreeBSD.org Delivered-To: freebsd-multimedia@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 21A2416A417 for ; Mon, 11 Dec 2006 04:32:37 +0000 (UTC) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (gate.funkthat.com [69.17.45.168]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6E13B43CA6 for ; Mon, 11 Dec 2006 04:31:22 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (iv2buou4v4uyz3pc@localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.13.6/8.13.3) with ESMTP id kBB4WaNL028119 for ; Sun, 10 Dec 2006 20:32:36 -0800 (PST) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.13.6/8.13.3/Submit) id kBB4WaIK028118 for multimedia@FreeBSD.org; Sun, 10 Dec 2006 20:32:36 -0800 (PST) (envelope-from jmg) Date: Sun, 10 Dec 2006 20:32:35 -0800 From: John-Mark Gurney To: multimedia@FreeBSD.org Message-ID: <20061211043235.GA781@funkthat.com> Mail-Followup-To: multimedia@FreeBSD.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="J2SCkAp4GZ/dPZZf" Content-Disposition: inline User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-RELEASE-p6 i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: Subject: extra DELAYs in bktr_i2c.c X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Dec 2006 04:32:37 -0000 --J2SCkAp4GZ/dPZZf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In 2002, delays were added to iicbb.c to control the speed of the SDA and SCL lines, but their respective delays were not removed from bktr_i2c.c... This changes the tuning speed for my FusionHDTV5 Lite from over 2 seconds down to .4 seconds, and checking if we are tuned from ~.7 seconds to .14 seconds... Please test this is you are using the BKTR_USE_FREEBSD_SMBUS option? The next stage is to turn the delays in iicbb to be configurable so that we can change from 10us DELAYs (100khz), to 3us DELAYs (333khz)... Most things support 400khz these days, and that'd reduce the speeds even more... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not." --J2SCkAp4GZ/dPZZf Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="bktr_i2c.patch" ==== //depot/vendor/freebsd/src/sys/dev/bktr/bktr_i2c.c#10 - /home/jmg/p4/world/src/sys/dev/bktr/bktr_i2c.c ==== --- /tmp/tmp.1115.0 Sun Dec 10 20:22:45 2006 +++ /home/jmg/p4/world/src/sys/dev/bktr/bktr_i2c.c Sun Dec 10 19:47:32 2006 @@ -50,7 +50,6 @@ #endif #if (__FreeBSD_version < 500000) -#include /* for DELAY */ #include #include #else @@ -69,8 +68,6 @@ #include #include -#define I2C_DELAY 40 - /* Compilation is void if BKTR_USE_FREEBSD_SMBUS is not * defined. This allows bktr owners to have smbus active for there * motherboard and still use their bktr without smbus. @@ -205,8 +202,6 @@ else OUTL(sc, BKTR_I2C_DATA_CTL, clock); - DELAY(I2C_DELAY); - return; } @@ -221,8 +216,6 @@ OUTL(sc, BKTR_I2C_DATA_CTL, 0x2 | data); else OUTL(sc, BKTR_I2C_DATA_CTL, data); - - DELAY(I2C_DELAY); return; } --J2SCkAp4GZ/dPZZf--