linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Colin Leroy <colin@colino.net>
To: linuxppc-dev list <linuxppc-dev@lists.linuxppc.org>,
	benh@kernel.crashing.org
Subject: [PATCH] tas3004_tables.c off-by-one
Date: Sat, 20 Dec 2003 17:58:50 +0100	[thread overview]
Message-ID: <20031220175850.416fb0ec.colin@colino.net> (raw)

[-- Attachment #1: Type: text/plain, Size: 329 bytes --]

Hi,

I noticed that when pushed to the upper limits, the mixer channels on my
ibook G4 just went silent (tested with master, bass, treble).

I found out this was due to too short (by one item) arrays in
tas3004_tables.c. This patch fixes it. I just copied over the last entry
of each array.

HTH,
--
Colin
http://www.colino.net/

[-- Attachment #2: tas3004_tables.diff --]
[-- Type: text/plain, Size: 1155 bytes --]

--- drivers/sound/dmasound/tas3004_tables.c.orig	2003-12-20 17:53:45.000000000 +0100
+++ drivers/sound/dmasound/tas3004_tables.c	2003-12-20 17:53:57.000000000 +0100
@@ -195,7 +195,7 @@
 	   0x1577b,    0x16a37,    0x17df5,    0x192bd,
 	   0x1a890,    0x1bf7b,    0x1d78d,    0x1f0d1,
 	   0x20b55,    0x22727,    0x24456,    0x262f2,
-	   0x2830b
+	   0x2830b,    0x2830b
 };

 static uint tas3004_mixer_tab[]={
@@ -224,7 +224,7 @@
 	  0x1577ac,   0x16a370,   0x17df51,   0x192bc2,
 	  0x1a88f8,   0x1bf7b7,   0x1d78c9,   0x1f0d04,
 	  0x20b542,   0x227268,   0x244564,   0x262f26,
-	  0x2830af
+	  0x2830af,   0x2830af
 };

 static uint tas3004_treble_tab[]={
@@ -253,7 +253,7 @@
 	      0x2f,       0x2c,       0x27,       0x23,
 	      0x1f,       0x1a,       0x15,        0xf,
 	       0x8,        0x5,        0x2,        0x1,
-	       0x1
+	       0x1,        0x1
 };

 static uint tas3004_bass_tab[]={
@@ -282,7 +282,7 @@
 	      0x36,       0x33,       0x2f,       0x2b,
 	      0x28,       0x24,       0x20,       0x1c,
 	      0x17,       0x12,        0xd,        0x7,
-	       0x1
+	       0x1,       0x1
 };

 struct tas_gain_t tas3004_gain={

             reply	other threads:[~2003-12-20 16:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-20 16:58 Colin Leroy [this message]
2003-12-20 23:26 ` [PATCH] tas3004_tables.c off-by-one Benjamin Herrenschmidt
2003-12-21 11:23   ` Colin Leroy
2004-01-09 22:33   ` Segher Boessenkool
2004-01-12 11:45     ` Colin Leroy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031220175850.416fb0ec.colin@colino.net \
    --to=colin@colino.net \
    --cc=benh@kernel.crashing.org \
    --cc=linuxppc-dev@lists.linuxppc.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).