treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / sound / soc / codecs / rl6347a.h
blob761455a2fa386dbcf41213df36bf0c9d9dbb02a8
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3 * rl6347a.h - RL6347A class device shared support
5 * Copyright 2015 Realtek Semiconductor Corp.
7 * Author: Oder Chiou <oder_chiou@realtek.com>
8 */
9 #ifndef __RL6347A_H__
10 #define __RL6347A_H__
12 #include <sound/hda_verbs.h>
14 #define VERB_CMD(V, N, D) ((N << 20) | (V << 8) | D)
16 #define RL6347A_VENDOR_REGISTERS 0x20
18 #define RL6347A_COEF_INDEX\
19 VERB_CMD(AC_VERB_SET_COEF_INDEX, RL6347A_VENDOR_REGISTERS, 0)
20 #define RL6347A_PROC_COEF\
21 VERB_CMD(AC_VERB_SET_PROC_COEF, RL6347A_VENDOR_REGISTERS, 0)
23 struct rl6347a_priv {
24 struct reg_default *index_cache;
25 int index_cache_size;
28 int rl6347a_hw_write(void *context, unsigned int reg, unsigned int value);
29 int rl6347a_hw_read(void *context, unsigned int reg, unsigned int *value);
31 #endif /* __RL6347A_H__ */