alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
To: alsa-devel@alsa-project.org
Cc: liam.r.girdwood@linux.intel.com
Subject: [PATCH v2] ALSA: core api: define offsets for TLV items
Date: Wed, 28 Mar 2018 10:09:04 -0700	[thread overview]
Message-ID: <20180328170904.19845-1-ranjani.sridharan@linux.intel.com> (raw)

This patch defines accessor offsets for the type, length, min,
mute and step items in TLV data. These will be used by drivers to
extract the TLV data while loading topology.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
---
V2: removed redundant redefinitions and updated prefix
---
 include/uapi/sound/tlv.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/include/uapi/sound/tlv.h b/include/uapi/sound/tlv.h
index be5371f09a62..1fd786a5e57b 100644
--- a/include/uapi/sound/tlv.h
+++ b/include/uapi/sound/tlv.h
@@ -98,4 +98,12 @@
 
 #define SNDRV_CTL_TLVD_DB_GAIN_MUTE	-9999999
 
+/* Accessor offsets for TLV data items */
+#define SNDRV_CTL_TLV_OFFSET_TYPE		0
+#define SNDRV_CTL_TLV_OFFSET_LEN		1
+
+/* Accessor offsets for min, mute and step items in dB scale type TLV */
+#define SNDRV_CTL_TLV_OFFSET_DB_MIN		2
+#define SNDRV_CTL_TLV_OFFSET_DB_MUTE_AND_STEP	3
+
 #endif
-- 
2.14.1

             reply	other threads:[~2018-03-28 17:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-28 17:09 Ranjani Sridharan [this message]
2018-03-28 19:05 ` [PATCH v2] ALSA: core api: define offsets for TLV items Takashi Sakamoto
2018-03-28 19:30   ` Takashi Sakamoto
2018-03-29  4:07     ` Ranjani Sridharan

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=20180328170904.19845-1-ranjani.sridharan@linux.intel.com \
    --to=ranjani.sridharan@linux.intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=liam.r.girdwood@linux.intel.com \
    /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).