Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Apr 2001 12:17:57 +0200
From:      Anders Andersson <anders@codefactory.se>
To:        gollum <gollum@hobbit.ccrypt.net>
Cc:        freebsd-mobile@freebsd.org, cg@FreeBSD.org
Subject:   Re: Fix for csa driver under 4.x
Message-ID:  <20010425121757.A480@jellyfish.codefactory.se>
In-Reply-To: <Pine.BSO.4.32.0104242146520.24249-100000@hobbit.ccrypt.net>; from gollum@hobbit.ccrypt.net on Tis, Apr 24, 2001 at 10:10:44pm -0700
References:  <Pine.BSO.4.32.0104242146520.24249-100000@hobbit.ccrypt.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tis, Apr 24, 2001 at 10:10:44pm -0700, gollum wrote:
> The follow fix solved the sound issue on my T21 (CS461x) laptop running
> 4.3 FreeBSD. The issue was two function parameters that were backwards
> in the pci_write_config call in the csa_attach function. This fix sould
> solve the sound issue for the csa driver under 4.2 also, however, I have
> yet to test it. NOTE: This fix has been added to the HEAD CVS tree, but
> has yet to be added to RELENG_4.
> 
> The following diff shows the fix for the csa.c file under
> /usr/src/sys/dev/sound/pci:
> 
> *** csa.c       Tue Apr 24 21:51:45 2001
> --- csa.c.broken        Tue Apr 24 20:47:38 2001
> ***************
> *** 131,137 ****
>         stcmd = pci_read_config(dev, PCIR_COMMAND, 4);
>         if ((stcmd & PCIM_CMD_MEMEN) == 0 || (stcmd & PCIM_CMD_BUSMASTEREN) == 0) {
>                 stcmd |= (PCIM_CMD_MEMEN | PCIM_CMD_BUSMASTEREN);
> !               pci_write_config(dev, PCIR_COMMAND, stcmd, 4);
>         }
> 
>         /* Allocate the resources. */
> --- 131,137 ----
>         stcmd = pci_read_config(dev, PCIR_COMMAND, 4);
>         if ((stcmd & PCIM_CMD_MEMEN) == 0 || (stcmd & PCIM_CMD_BUSMASTEREN) == 0) {
>                 stcmd |= (PCIM_CMD_MEMEN | PCIM_CMD_BUSMASTEREN);
> !               pci_write_config(dev, PCIR_COMMAND, 4, stcmd);
>         }
> 
>         /* Allocate the resources. */
> 
> 
> 
> <gollum>

This patch makes sound work on my IBM ThinkPad A20p

csa0: <Crystal Semiconductor CS4614/4622/4624 Audio accelerator/4280
Audio controller> mem 0xf0000000-0xf00fffff,0xf0121000-0xf0121fff irq 11
at device 5.0 on pci0
pcm0: <CS461x PCM Audio> on csa0

-- 
Anders Andersson		anders@codefactory.se
CodeFactory AB			http://www.codefactory.se/
Office: +46 (0)31 711 99 35	Cell: +46 (0)70 587 53 35

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010425121757.A480>