Lines Matching refs:buck

44 static int s2mps11_buck_hex2volt(int buck, int hex)  in s2mps11_buck_hex2volt()  argument
51 switch (buck) { in s2mps11_buck_hex2volt()
66 if (buck == 5 && hex > S2MPS11_BUCK5_VOLT_MAX_HEX) in s2mps11_buck_hex2volt()
68 else if (buck != 5 && hex > S2MPS11_BUCK_VOLT_MAX_HEX) in s2mps11_buck_hex2volt()
77 pr_err("Value: %#x is wrong for BUCK%d", hex, buck); in s2mps11_buck_hex2volt()
81 static int s2mps11_buck_volt2hex(int buck, int uV) in s2mps11_buck_volt2hex() argument
85 switch (buck) { in s2mps11_buck_volt2hex()
101 if (buck == 5 && hex > S2MPS11_BUCK5_VOLT_MAX_HEX) in s2mps11_buck_volt2hex()
103 else if (buck != 5 && hex > S2MPS11_BUCK_VOLT_MAX_HEX) in s2mps11_buck_volt2hex()
112 pr_err("Value: %d uV is wrong for BUCK%d", uV, buck); in s2mps11_buck_volt2hex()
118 int hex, buck, ret; in s2mps11_buck_val() local
122 buck = dev->driver_data; in s2mps11_buck_val()
123 if (buck < 1 || buck > S2MPS11_BUCK_NUM) { in s2mps11_buck_val()
124 pr_err("Wrong buck number: %d\n", buck); in s2mps11_buck_val()
131 addr = s2mps11_buck_out[buck]; in s2mps11_buck_val()
133 switch (buck) { in s2mps11_buck_val()
148 ret = s2mps11_buck_hex2volt(buck, val); in s2mps11_buck_val()
155 hex = s2mps11_buck_volt2hex(buck, *uV); in s2mps11_buck_val()
170 int buck, ret; in s2mps11_buck_mode() local
172 buck = dev->driver_data; in s2mps11_buck_mode()
173 if (buck < 1 || buck > S2MPS11_BUCK_NUM) { in s2mps11_buck_mode()
174 pr_err("Wrong buck number: %d\n", buck); in s2mps11_buck_mode()
178 addr = s2mps11_buck_ctrl[buck]; in s2mps11_buck_mode()
213 pr_err("Wrong mode: %d for buck: %d\n", *opmode, buck); in s2mps11_buck_mode()