aboutsummaryrefslogtreecommitdiffstats
path: root/include/sound
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2008-07-29 06:42:25 -0400
committerJaroslav Kysela <perex@perex.cz>2008-07-29 15:32:15 -0400
commit58cd33c0f375578cfda25a52ed280caa888b6254 (patch)
treec670df251546d8affa258e0720d94d0a6aabcd4f /include/sound
parent8a33de9e51673dbdadb552d888a4544aefe0c31d (diff)
ALSA: ASoC: Allow codecs to override register display
Some codecs have unusual features in their register maps such as very large registers representing arrays of coefficients. Support these codecs in the register cache sysfs file by allowing them to provide a function register_display() overriding the default output for register contents. Also ensure that we don't overflow PAGE_SIZE while writing out the register dump. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
Diffstat (limited to 'include/sound')
-rw-r--r--include/sound/soc.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/sound/soc.h b/include/sound/soc.h
index 1890d87c5204..2ce530efcf11 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -410,6 +410,8 @@ struct snd_soc_codec {
410 void *control_data; /* codec control (i2c/3wire) data */ 410 void *control_data; /* codec control (i2c/3wire) data */
411 unsigned int (*read)(struct snd_soc_codec *, unsigned int); 411 unsigned int (*read)(struct snd_soc_codec *, unsigned int);
412 int (*write)(struct snd_soc_codec *, unsigned int, unsigned int); 412 int (*write)(struct snd_soc_codec *, unsigned int, unsigned int);
413 int (*display_register)(struct snd_soc_codec *, char *,
414 size_t, unsigned int);
413 hw_write_t hw_write; 415 hw_write_t hw_write;
414 hw_read_t hw_read; 416 hw_read_t hw_read;
415 void *reg_cache; 417 void *reg_cache;