soc/mediatek/mt8196: Correct the argument type of MT6363
Correct the argument type of the mt6363_sdmadc_read API and the return value type of the mt6363_read16 API. TEST=Build pass BUG=b:317009620 Change-Id: I0f768e23473fa924245d90ab1e4fa383ec437db3 Signed-off-by: Hope Wang <hope.wang@mediatek.corp-partner.google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/85839 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Yidi Lin <yidilin@google.com> Reviewed-by: Yu-Ping Wu <yupingso@google.com>
This commit is contained in:
parent
2ad6b19037
commit
f7a977d39a
5 changed files with 6 additions and 6 deletions
|
|
@ -38,7 +38,7 @@ static const unsigned int *adc_voltages[] = {
|
|||
|
||||
static uint32_t get_adc_index(unsigned int channel)
|
||||
{
|
||||
int value;
|
||||
u32 value;
|
||||
|
||||
mt6363_sdmadc_read(channel, &value, SDMADC_OPEN, AUXADC_VAL_PROCESSED);
|
||||
assert(channel < ARRAY_SIZE(adc_voltages));
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@ void mt6363_enable_vrf18(bool enable);
|
|||
void mt6363_enable_vram_digrf(bool enable);
|
||||
void mt6363_enable_vram_mdfe(bool enable);
|
||||
void mt6363_init_pmif_arb(void);
|
||||
u32 mt6363_read16(u32 reg);
|
||||
u16 mt6363_read16(u32 reg);
|
||||
void mt6363_write8(u32 reg, u8 reg_val);
|
||||
void mt6363_write_field(u32 reg, u32 val, u32 mask, u32 shift);
|
||||
void mt6363_init_setting(void);
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@ struct auxadc_chan_spec {
|
|||
} sdmadc_hw_info;
|
||||
};
|
||||
|
||||
int mt6363_sdmadc_read(enum auxadc_channel channel, int *val, enum sdmadc_pures pures,
|
||||
int mt6363_sdmadc_read(enum auxadc_channel channel, u32 *val, enum sdmadc_pures pures,
|
||||
enum auxadc_val_type type);
|
||||
|
||||
#endif /* __MT6363_SDMADC_H__ */
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ static const struct pmic_setting key_protect_setting[] = {
|
|||
};
|
||||
|
||||
static struct pmif *pmif_arb;
|
||||
u32 mt6363_read16(u32 reg)
|
||||
u16 mt6363_read16(u32 reg)
|
||||
{
|
||||
u16 rdata = 0;
|
||||
|
||||
|
|
|
|||
|
|
@ -61,11 +61,11 @@ static const struct auxadc_chan_spec mt6363_sdmadc_chan_specs[] = {
|
|||
_Static_assert(ARRAY_SIZE(mt6363_sdmadc_chan_specs) == AUXADC_CHAN_MAX,
|
||||
"Wrong array size for mt6363_sdmadc_chan_specs");
|
||||
|
||||
int mt6363_sdmadc_read(enum auxadc_channel channel, int *val,
|
||||
int mt6363_sdmadc_read(enum auxadc_channel channel, u32 *val,
|
||||
enum sdmadc_pures pures, enum auxadc_val_type type)
|
||||
{
|
||||
u8 wdata;
|
||||
u32 regval;
|
||||
u16 regval;
|
||||
u32 elapsed = 0;
|
||||
const struct auxadc_chan_spec *chan;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue