[alsa-devel] "Negative" volume settings in a kcontrol
mike.looijmans at topic.nl
Fri May 31 09:01:22 CEST 2013
On 05/29/2013 09:42 PM, Mark Brown wrote:
> On Tue, May 28, 2013 at 01:46:15PM +0200, Mike Looijmans wrote:
>> On 05/06/2013 03:22 PM, Clemens Ladisch wrote:
>>> Mike Looijmans wrote:
> *ALWAYS* CC maintainers on mails and don't drop people from CCs either...
I hereby promise to improve myself in that respect :)
>>> There are some ASoC helper macros that handle signed register fields, such
>>> as SOC_DOUBLE_S8_TLV and SOC_SINGLE_XR_SX. If those don't do what you want,
>>> you have to write your own.
>> SOC_DOUBLE_S8_TLV seems to be a misnamed hardware-specific macro. It
>> provides no way to specify the location of the left/right bits so
>> the macro name is misleading.
> That's trivially fixable...
>> SOC_SINGLE_XR_SX is too new for my kernel. And from what I gather, I
>> cannot use it anyway for my purposes. So the solution turns out to
> What makes you gather this?
What I actually needed was a SOC_DOUBLE_... thingy. Otherwise, the macro
was pretty close, but I'm using a 2.6.37 kernel so just backporting the
snd_soc_*_xr_sx methods would be more work than simply writing new
info/set/get methods. I also considered the fact that only one driver is
using the SOC_SINGLE_XR_SX macro a bit of a code smell, so I feared a
similar experience as with SOC_DOUBLE_S8_TLV which was also introduced
just for a single driver.
More information about the Alsa-devel