Bug 26415

Summary: [FIX] yet another ES1371 sound chip rev.
Product: Base System Reporter: Jose M. Alcaide <jose>
Component: i386Assignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   

Description Jose M. Alcaide 2001-04-08 00:30:04 UTC
After installing 4.3-RC1 on a new system based on the Gigabyte GA-7ZX
motherboard, which includes an ES1371 audio chip, the pcm driver
fails to detect the AC97 codec properly:

pcm0: <AudioPCI ES1371> port 0xd000-0xd03f irq 10 at device 14.0 on pci0
es_init
es_init pre ac97 2.1
wrcodec addr 0x26 data 0x0
wrcodec addr 0x0 data 0x0
rdcodec addr 0x0 ... loop 1 t 0x1000 x 0x40000000 loop 2 t 0x5000 x 0x70000 loop 3 t 0x1000 0x40000000
ret 0x0
rdcodec addr 0x7c ... loop 1 t 0x1000 x 0x40000000 loop 2 t 0x5000 x 0x70000 loop 3 t 0x1000
0x40000000 ret 0x0
rdcodec addr 0x7e ... loop 1 t 0x1000 x 0x40000000 loop 2 t 0x5000 x 0x70000 loop 3 t 0x1000
0x40000000 ret 0x0
pcm0: ac97 codec invalid or not present (id == 0)
device_probe_and_attach: pcm0 attach returned 6

And this is the relevant line from "pciconf -l":

none0@pci0:14:0:        class=0x040100 card=0xa0001458 chip=0x58801274 rev=0x03 hdr=0x00

Fix: 

I modified es137x.c, changing the test

  revid == 7 || revid >= 9 || (devid == ES1371_PCI_ID3 && revid == 2)

to (yes, I know it is ugly ;-) ):

  revid == 7 || revid >= 9 || (devid == ES1371_PCI_ID3 && (revid == 2 || revid == 3))


(Ugly, but it works)
How-To-Repeat: 	N/A
Comment 1 greid freebsd_committer freebsd_triage 2001-04-08 01:08:00 UTC
State Changed
From-To: open->closed

Revision ID added, thanks!
Comment 2 dwcjr 2001-05-02 00:34:09 UTC
I'm looking through the cvs logs and I don't see this in RELENG_4, and I
missing it?
Comment 3 greid freebsd_committer freebsd_triage 2001-05-02 00:38:41 UTC
On Tue, 1 May 2001, David W. Chapman Jr. wrote:

> I'm looking through the cvs logs and I don't see this in RELENG_4, and I
> missing it?

You're not missing it - it hasn't been MFC'd yet. I'll be doing an MFC of
some ES137x stuff in the next couple of days.

~greid
--
+-------------------+---------------------+
|    George Reid    |  FreeBSD Committer  |
|  +44 7740 197460  |  greid@FreeBSD.org  |
+-------------------+---------------------+