Files
android_kernel_motorola_sm6225/sound/soc/codecs/tas2560-misc.h
T
Wen Xie 87709cb9cd ASoC: Tas2560: Add audio codecs
Add audio codecs Tas2560 driver.

Change-Id: I0806dc5427b7c8bdd3447e06ebd1e92d9a8ec22c
Signed-off-by: Wen Xie <xiewen3@motorola.com>
Reviewed-on: https://gerrit.mot.com/1196381
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Zhengming Yao <yaozm1@lenovo.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2018-06-20 02:54:39 -05:00

46 lines
1.6 KiB
C

/*
** =============================================================================
** Copyright (c) 2016 Texas Instruments Inc.
**
** This program is free software; you can redistribute it and/or modify it under
** the terms of the GNU General Public License as published by the Free Software
** Foundation; version 2.
**
** This program is distributed in the hope that it will be useful, but WITHOUT
** ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
** FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
**
** File:
** tas2560-misc.h
**
** Description:
** header file for tas2560-misc.c
**
** =============================================================================
*/
#ifndef _TAS2560_MISC_H
#define _TAS2560_MISC_H
#define TIAUDIO_CMD_REG_WITE 1
#define TIAUDIO_CMD_REG_READ 2
#define TIAUDIO_CMD_DEBUG_ON 3
#define TIAUDIO_CMD_CALIBRATION 7
#define TIAUDIO_CMD_SAMPLERATE 8
#define TIAUDIO_CMD_BITRATE 9
#define TIAUDIO_CMD_DACVOLUME 10
#define TIAUDIO_CMD_SPEAKER 11
#define TAS2560_MAGIC_NUMBER 'M' /* '2560' */
#define SMARTPA_SPK_DAC_VOLUME _IOWR(TAS2560_MAGIC_NUMBER, 1, unsigned long)
#define SMARTPA_SPK_POWER_ON _IOWR(TAS2560_MAGIC_NUMBER, 2, unsigned long)
#define SMARTPA_SPK_POWER_OFF _IOWR(TAS2560_MAGIC_NUMBER, 3, unsigned long)
#define SMARTPA_SPK_SET_SAMPLERATE _IOWR(TAS2560_MAGIC_NUMBER, 7, unsigned long)
#define SMARTPA_SPK_SET_BITRATE _IOWR(TAS2560_MAGIC_NUMBER, 8, unsigned long)
int tas2560_register_misc(struct tas2560_priv *pTAS2560);
int tas2560_deregister_misc(struct tas2560_priv *pTAS2560);
#endif /* _TAS2560_MISC_H */