162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */ 262306a36Sopenharmony_ci#ifndef __ATMEL_CLASSD_H_ 362306a36Sopenharmony_ci#define __ATMEL_CLASSD_H_ 462306a36Sopenharmony_ci 562306a36Sopenharmony_ci#define CLASSD_CR 0x00000000 662306a36Sopenharmony_ci#define CLASSD_CR_RESET 0x1 762306a36Sopenharmony_ci 862306a36Sopenharmony_ci#define CLASSD_MR 0x00000004 962306a36Sopenharmony_ci 1062306a36Sopenharmony_ci#define CLASSD_MR_LEN_DIS 0x0 1162306a36Sopenharmony_ci#define CLASSD_MR_LEN_EN 0x1 1262306a36Sopenharmony_ci#define CLASSD_MR_LEN_MASK (0x1 << 0) 1362306a36Sopenharmony_ci#define CLASSD_MR_LEN_SHIFT (0) 1462306a36Sopenharmony_ci 1562306a36Sopenharmony_ci#define CLASSD_MR_LMUTE_DIS 0x0 1662306a36Sopenharmony_ci#define CLASSD_MR_LMUTE_EN 0x1 1762306a36Sopenharmony_ci#define CLASSD_MR_LMUTE_SHIFT (0x1) 1862306a36Sopenharmony_ci#define CLASSD_MR_LMUTE_MASK (0x1 << 1) 1962306a36Sopenharmony_ci 2062306a36Sopenharmony_ci#define CLASSD_MR_REN_DIS 0x0 2162306a36Sopenharmony_ci#define CLASSD_MR_REN_EN 0x1 2262306a36Sopenharmony_ci#define CLASSD_MR_REN_MASK (0x1 << 4) 2362306a36Sopenharmony_ci#define CLASSD_MR_REN_SHIFT (4) 2462306a36Sopenharmony_ci 2562306a36Sopenharmony_ci#define CLASSD_MR_RMUTE_DIS 0x0 2662306a36Sopenharmony_ci#define CLASSD_MR_RMUTE_EN 0x1 2762306a36Sopenharmony_ci#define CLASSD_MR_RMUTE_SHIFT (0x5) 2862306a36Sopenharmony_ci#define CLASSD_MR_RMUTE_MASK (0x1 << 5) 2962306a36Sopenharmony_ci 3062306a36Sopenharmony_ci#define CLASSD_MR_PWMTYP_SINGLE 0x0 3162306a36Sopenharmony_ci#define CLASSD_MR_PWMTYP_DIFF 0x1 3262306a36Sopenharmony_ci#define CLASSD_MR_PWMTYP_MASK (0x1 << 8) 3362306a36Sopenharmony_ci#define CLASSD_MR_PWMTYP_SHIFT (8) 3462306a36Sopenharmony_ci 3562306a36Sopenharmony_ci#define CLASSD_MR_NON_OVERLAP_DIS 0x0 3662306a36Sopenharmony_ci#define CLASSD_MR_NON_OVERLAP_EN 0x1 3762306a36Sopenharmony_ci#define CLASSD_MR_NON_OVERLAP_MASK (0x1 << 16) 3862306a36Sopenharmony_ci#define CLASSD_MR_NON_OVERLAP_SHIFT (16) 3962306a36Sopenharmony_ci 4062306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_5NS 0x0 4162306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_10NS 0x1 4262306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_15NS 0x2 4362306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_20NS 0x3 4462306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_MASK (0x3 << 20) 4562306a36Sopenharmony_ci#define CLASSD_MR_NOVR_VAL_SHIFT (20) 4662306a36Sopenharmony_ci 4762306a36Sopenharmony_ci#define CLASSD_INTPMR 0x00000008 4862306a36Sopenharmony_ci 4962306a36Sopenharmony_ci#define CLASSD_INTPMR_ATTL_MASK (0x3f << 0) 5062306a36Sopenharmony_ci#define CLASSD_INTPMR_ATTL_SHIFT (0) 5162306a36Sopenharmony_ci#define CLASSD_INTPMR_ATTR_MASK (0x3f << 8) 5262306a36Sopenharmony_ci#define CLASSD_INTPMR_ATTR_SHIFT (8) 5362306a36Sopenharmony_ci 5462306a36Sopenharmony_ci#define CLASSD_INTPMR_DSP_CLK_FREQ_12M288 0x0 5562306a36Sopenharmony_ci#define CLASSD_INTPMR_DSP_CLK_FREQ_11M2896 0x1 5662306a36Sopenharmony_ci#define CLASSD_INTPMR_DSP_CLK_FREQ_MASK (0x1 << 16) 5762306a36Sopenharmony_ci#define CLASSD_INTPMR_DSP_CLK_FREQ_SHIFT (16) 5862306a36Sopenharmony_ci 5962306a36Sopenharmony_ci#define CLASSD_INTPMR_DEEMP_DIS 0x0 6062306a36Sopenharmony_ci#define CLASSD_INTPMR_DEEMP_EN 0x1 6162306a36Sopenharmony_ci#define CLASSD_INTPMR_DEEMP_MASK (0x1 << 18) 6262306a36Sopenharmony_ci#define CLASSD_INTPMR_DEEMP_SHIFT (18) 6362306a36Sopenharmony_ci 6462306a36Sopenharmony_ci#define CLASSD_INTPMR_SWAP_LEFT_ON_LSB 0x0 6562306a36Sopenharmony_ci#define CLASSD_INTPMR_SWAP_RIGHT_ON_LSB 0x1 6662306a36Sopenharmony_ci#define CLASSD_INTPMR_SWAP_MASK (0x1 << 19) 6762306a36Sopenharmony_ci#define CLASSD_INTPMR_SWAP_SHIFT (19) 6862306a36Sopenharmony_ci 6962306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_8K 0x0 7062306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_16K 0x1 7162306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_32K 0x2 7262306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_48K 0x3 7362306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_96K 0x4 7462306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_22K 0x5 7562306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_44K 0x6 7662306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_88K 0x7 7762306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_MASK (0x7 << 20) 7862306a36Sopenharmony_ci#define CLASSD_INTPMR_FRAME_SHIFT (20) 7962306a36Sopenharmony_ci 8062306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_FLAT 0x0 8162306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_B_BOOST_12 0x1 8262306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_B_BOOST_6 0x2 8362306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_B_CUT_12 0x3 8462306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_B_CUT_6 0x4 8562306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_M_BOOST_3 0x5 8662306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_M_BOOST_8 0x6 8762306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_M_CUT_3 0x7 8862306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_M_CUT_8 0x8 8962306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_T_BOOST_12 0x9 9062306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_T_BOOST_6 0xa 9162306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_T_CUT_12 0xb 9262306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_T_CUT_6 0xc 9362306a36Sopenharmony_ci#define CLASSD_INTPMR_EQCFG_SHIFT (24) 9462306a36Sopenharmony_ci 9562306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_DIS 0x0 9662306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_EN 0x1 9762306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MASK (0x1 << 28) 9862306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_SHIFT (28) 9962306a36Sopenharmony_ci 10062306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_MIX 0x0 10162306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_SAT 0x1 10262306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_LEFT 0x2 10362306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_RIGHT 0x3 10462306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_MASK (0x3 << 29) 10562306a36Sopenharmony_ci#define CLASSD_INTPMR_MONO_MODE_SHIFT (29) 10662306a36Sopenharmony_ci 10762306a36Sopenharmony_ci#define CLASSD_INTSR 0x0000000c 10862306a36Sopenharmony_ci 10962306a36Sopenharmony_ci#define CLASSD_THR 0x00000010 11062306a36Sopenharmony_ci 11162306a36Sopenharmony_ci#define CLASSD_IER 0x00000014 11262306a36Sopenharmony_ci 11362306a36Sopenharmony_ci#define CLASSD_IDR 0x00000018 11462306a36Sopenharmony_ci 11562306a36Sopenharmony_ci#define CLASSD_IMR 0x0000001c 11662306a36Sopenharmony_ci 11762306a36Sopenharmony_ci#define CLASSD_ISR 0x00000020 11862306a36Sopenharmony_ci 11962306a36Sopenharmony_ci#define CLASSD_WPMR 0x000000e4 12062306a36Sopenharmony_ci 12162306a36Sopenharmony_ci#endif 122