Lines Matching refs:s
24 const char *_parse_integer_fixup_radix(const char *s, unsigned int *base) in _parse_integer_fixup_radix() argument
27 if (s[0] == '0') { in _parse_integer_fixup_radix()
28 if (_tolower(s[1]) == 'x' && isxdigit(s[2])) in _parse_integer_fixup_radix()
35 if (*base == 16 && s[0] == '0' && _tolower(s[1]) == 'x') in _parse_integer_fixup_radix()
36 s += 2; in _parse_integer_fixup_radix()
37 return s; in _parse_integer_fixup_radix()
48 unsigned int _parse_integer(const char *s, unsigned int base, unsigned long long *p) in _parse_integer() argument
56 unsigned int c = *s; in _parse_integer()
79 s++; in _parse_integer()
85 static int _kstrtoull(const char *s, unsigned int base, unsigned long long *res) in _kstrtoull() argument
90 s = _parse_integer_fixup_radix(s, &base); in _kstrtoull()
91 rv = _parse_integer(s, base, &_res); in _kstrtoull()
96 s += rv; in _kstrtoull()
97 if (*s == '\n') in _kstrtoull()
98 s++; in _kstrtoull()
99 if (*s) in _kstrtoull()
121 int kstrtoull(const char *s, unsigned int base, unsigned long long *res) in kstrtoull() argument
123 if (s[0] == '+') in kstrtoull()
124 s++; in kstrtoull()
125 return _kstrtoull(s, base, res); in kstrtoull()
145 int kstrtoll(const char *s, unsigned int base, long long *res) in kstrtoll() argument
150 if (s[0] == '-') { in kstrtoll()
151 rv = _kstrtoull(s + 1, base, &tmp); in kstrtoll()
158 rv = kstrtoull(s, base, &tmp); in kstrtoll()
170 int _kstrtoul(const char *s, unsigned int base, unsigned long *res) in _kstrtoul() argument
175 rv = kstrtoull(s, base, &tmp); in _kstrtoul()
186 int _kstrtol(const char *s, unsigned int base, long *res) in _kstrtol() argument
191 rv = kstrtoll(s, base, &tmp); in _kstrtol()
217 int kstrtouint(const char *s, unsigned int base, unsigned int *res) in kstrtouint() argument
222 rv = kstrtoull(s, base, &tmp); in kstrtouint()
248 int kstrtoint(const char *s, unsigned int base, int *res) in kstrtoint() argument
253 rv = kstrtoll(s, base, &tmp); in kstrtoint()
263 int kstrtou16(const char *s, unsigned int base, u16 *res) in kstrtou16() argument
268 rv = kstrtoull(s, base, &tmp); in kstrtou16()
278 int kstrtos16(const char *s, unsigned int base, s16 *res) in kstrtos16() argument
283 rv = kstrtoll(s, base, &tmp); in kstrtos16()
293 int kstrtou8(const char *s, unsigned int base, u8 *res) in kstrtou8() argument
298 rv = kstrtoull(s, base, &tmp); in kstrtou8()
308 int kstrtos8(const char *s, unsigned int base, s8 *res) in kstrtos8() argument
313 rv = kstrtoll(s, base, &tmp); in kstrtos8()
332 int kstrtobool(const char *s, bool *res) in kstrtobool() argument
334 if (!s) in kstrtobool()
337 switch (s[0]) { in kstrtobool()
350 switch (s[1]) { in kstrtobool()
374 int kstrtobool_from_user(const char __user *s, size_t count, bool *res) in kstrtobool_from_user() argument
380 if (copy_from_user(buf, s, count)) in kstrtobool_from_user()
388 int f(const char __user *s, size_t count, unsigned int base, type *res) \
394 if (copy_from_user(buf, s, count)) \