All of lore.kernel.org
 help / color / mirror / Atom feed
* VIA 8233A
@ 2003-02-10  6:21 p z oooo
  2003-02-10  8:21 ` VIA 8233A - Patch included Tais M. Hansen
  2003-02-10  9:14 ` VIA 8233A Takashi Iwai
  0 siblings, 2 replies; 14+ messages in thread
From: p z oooo @ 2003-02-10  6:21 UTC (permalink / raw)
  To: alsa-devel

Hi,

There is bug in via82xx.c. VIA8233A is wrongly detected as VIA8233 
and then not working.

in function snd_via82xx_probe is this 

case TYPE_CARD_VIA8233:
		chip_type = TYPE_VIA8233;
		sprintf(card->shortname, "VIA 823x rev%d", revision);
		for (i = 0; i < ARRAY_SIZE(via823x_cards); i++) {
			if (revision == via823x_cards[i].revision) {
				chip_type = via823x_cards[i].type;
				strcpy(card->shortname, via823x_cards
[i].name);
				break;
			}
		}
		if (chip_type == VIA_REV_8233A)
			strcpy(card->driver, "VIA8233A");
		else
			strcpy(card->driver, "VIA8233");
		break;
	default:
		snd_printk(KERN_ERR "invalid card type %d\n", 
card_type);
		err = -EINVAL;
		goto __error;
	}
		
	if ((err = snd_via82xx_create(card, pci, chip_type, revision, 
ac97_clock[dev], &chip)) < 0)
		goto __error;

	if ((err = snd_via82xx_mixer_new(chip)) < 0)
		goto __error;

	if (chip_type == TYPE_VIA686) {
		if ((err = snd_via686_pcm_new(chip)) < 0 ||
		    (err = snd_via686_init_misc(chip, dev)) < 0)
			goto __error;
	} else {
		if (chip_type == VIA_REV_8233A) {
			if ((err = snd_via8233a_pcm_new(chip)) < 0)
				goto __error;
		} else {
			if ((err = snd_via8233_pcm_new(chip)) < 0)
				goto __error;
		}
		if ((err = snd_via8233_init_misc(chip, dev)) < 0)
			goto __error;
	} 

But chip_type is compared to VIA_REV_8233A, but must be comparet to 
TYPE_VIA8233A.

When I changed VIA_REV_8233A to TYPE_VIA8233A my onboard soundcard 
(VIA8233A + ALC650) works (2 channel, 4 cannel).

5.1 has problem - swaped channels. (LF, RF, Center - OK, LS - Woofer, 
RS - LS, Woofer - RS.


Peter Zubaj


====================== REKLAMA =================================
Vyrazne zlavy pocitacov a prislusenstva
Toshiba Pocket PC e740 v cench u? od 24.300,- Sk bez DPH
Navstivte nas na adrese http://www.somi.sk/akcie.php
================================================================




-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com

^ permalink raw reply	[flat|nested] 14+ messages in thread
* Re: VIA 8233A, 8235 with ALC650 codec
@ 2003-02-19  6:51 p z oooo
  2003-02-19  9:22 ` Takashi Iwai
  0 siblings, 1 reply; 14+ messages in thread
From: p z oooo @ 2003-02-19  6:51 UTC (permalink / raw)
  To: alsa-devel

I played with 8233A ALC650 and:

1) this part of code is not working:

switch (runtime->channels) {
	case 1: slots = (1<<0) | (1<<4); break;
	case 2: slots = (1<<0) | (2<<4); break;
	case 3: slots = (1<<0) | (2<<4) | (5<<8); break;
	case 4: slots = (1<<0) | (2<<4) | (3<<8) | (4<<12); break;
	case 5: slots = (1<<0) | (2<<4) | (5<<8) | (3<<12) | (4<<16); 
break;
	case 6: slots = (1<<0) | (2<<4) | (5<<8) | (6<<12) | (3<<16) 
| (4<<20); break;
	default: slots = 0; break;
	}
	/* STOP index is never reached */
	outl(0xff000000 | slots, VIADEV_REG(viadev, 
OFFSET_STOP_IDX)); 

I think that 8233A uses this slots mapping and this can't be changed 
with previous code. I changed 
case 6: slots = (1<<0) | (2<<4) | (5<<8) | (6<<12) | (3<<16) | 
(4<<20); break;
to
case 6: slots = (1<<0) | (2<<4) | (3<<8) | (4<<12) | (5<<16) | 
(6<<20); break;
and this doesn't work (no change).

channels slots
1 - 3, 4
2 - 3, 4
4 - 3, 4, 7, 8
6 - 3, 4, 6, 9, 7, 8


Peter Zubaj

====================== REKLAMA =================================
Vyrazne zlavy pocitacov a prislusenstva
Toshiba Pocket PC e740 v cench u? od 24.300,- Sk bez DPH
Navstivte nas na adrese http://www.somi.sk/akcie.php
================================================================



-------------------------------------------------------
This SF.net email is sponsored by: SlickEdit Inc. Develop an edge.
The most comprehensive and flexible code editor you can use.
Code faster. C/C++, C#, Java, HTML, XML, many more. FREE 30-Day Trial.
www.slickedit.com/sourceforge

^ permalink raw reply	[flat|nested] 14+ messages in thread
* Re: VIA 8233A, 8235 with ALC650 codec
@ 2003-02-20  6:19 p z oooo
  2003-02-20  9:06 ` Takashi Iwai
  0 siblings, 1 reply; 14+ messages in thread
From: p z oooo @ 2003-02-20  6:19 UTC (permalink / raw)
  To: gbdj; +Cc: alsa-devel, tiwai

I tink, there is still small bug (I think) - via82xx.c

else
   /* slot mapping: 3,4,6,9,7,8 */
   val = 0x4000; 
   snd_ac97_update_bits(chip->ac97, AC97_ALC650_MULTICH, 0xc000, val);

is this correct ???
val = 0x4000; (I think, that there should be 0xc000)

try change this

Peter Zubaj

____________________________________
P. S. V. P. U.
http://www.pobox.sk/




-------------------------------------------------------
This SF.net email is sponsored by: SlickEdit Inc. Develop an edge.
The most comprehensive and flexible code editor you can use.
Code faster. C/C++, C#, Java, HTML, XML, many more. FREE 30-Day Trial.
www.slickedit.com/sourceforge

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2003-02-25 17:00 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-10  6:21 VIA 8233A p z oooo
2003-02-10  8:21 ` VIA 8233A - Patch included Tais M. Hansen
2003-02-10  9:14 ` VIA 8233A Takashi Iwai
2003-02-18  4:43   ` VIA 8233A, 8235 with ALC650 codec Anton Worshevsky
2003-02-18 17:03     ` Takashi Iwai
2003-02-20  2:51       ` Anton Worshevsky
2003-02-20  9:08         ` Takashi Iwai
2003-02-23 21:50           ` Anton Worshevsky
2003-02-25 17:00             ` Takashi Iwai
  -- strict thread matches above, loose matches on Subject: below --
2003-02-19  6:51 p z oooo
2003-02-19  9:22 ` Takashi Iwai
     [not found]   ` <000d01c2d7fb$4f521de0$8601a8c0@ZUBAJPNEW>
2003-02-19 10:04     ` Takashi Iwai
2003-02-20  6:19 p z oooo
2003-02-20  9:06 ` Takashi Iwai

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.