/* SPDX-License-Identifier: GPL-2.0-only */1/*2* linux/sound/cs35l35.h -- Platform data for CS35l353*4* Copyright (c) 2016 Cirrus Logic Inc.5*/67#ifndef __CS35L35_H8#define __CS35L35_H910struct classh_cfg {11/*12* Class H Algorithm Control Variables13* You can either have it done14* automatically or you can adjust15* these variables for tuning16*17* if you do not enable the internal algorithm18* you will get a set of mixer controls for19* Class H tuning20*21* Section 4.3 of the datasheet22*/23bool classh_bst_override;24bool classh_algo_enable;25int classh_bst_max_limit;26int classh_mem_depth;27int classh_release_rate;28int classh_headroom;29int classh_wk_fet_disable;30int classh_wk_fet_delay;31int classh_wk_fet_thld;32int classh_vpch_auto;33int classh_vpch_rate;34int classh_vpch_man;35};3637struct monitor_cfg {38/*39* Signal Monitor Data40* highly configurable signal monitoring41* data positioning and different types of42* monitoring data.43*44* Section 4.8.2 - 4.8.4 of the datasheet45*/46bool is_present;47bool imon_specs;48bool vmon_specs;49bool vpmon_specs;50bool vbstmon_specs;51bool vpbrstat_specs;52bool zerofill_specs;53u8 imon_dpth;54u8 imon_loc;55u8 imon_frm;56u8 imon_scale;57u8 vmon_dpth;58u8 vmon_loc;59u8 vmon_frm;60u8 vpmon_dpth;61u8 vpmon_loc;62u8 vpmon_frm;63u8 vbstmon_dpth;64u8 vbstmon_loc;65u8 vbstmon_frm;66u8 vpbrstat_dpth;67u8 vpbrstat_loc;68u8 vpbrstat_frm;69u8 zerofill_dpth;70u8 zerofill_loc;71u8 zerofill_frm;72};7374struct cs35l35_platform_data {7576/* Stereo (2 Device) */77bool stereo;78/* serial port drive strength */79int sp_drv_str;80/* serial port drive in unused slots */81int sp_drv_unused;82/* Boost Power Down with FET */83bool bst_pdn_fet_on;84/* Boost Voltage : used if ClassH Algo Enabled */85int bst_vctl;86/* Boost Converter Peak Current CTRL */87int bst_ipk;88/* Amp Gain Zero Cross */89bool gain_zc;90/* Audio Input Location */91int aud_channel;92/* Advisory Input Location */93int adv_channel;94/* Shared Boost for stereo */95bool shared_bst;96/* Specifies this amp is using an external boost supply */97bool ext_bst;98/* Inductor Value */99int boost_ind;100/* ClassH Algorithm */101struct classh_cfg classh_algo;102/* Monitor Config */103struct monitor_cfg mon_cfg;104};105106#endif /* __CS35L35_H */107108109