Lines Matching +full:base +full:- +full:64

1 // SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0
4 * Module Name: utstrtoul64 - String-to-integer conversion support for both
5 * 64-bit and 32-bit integers
17 * This module contains the top-level string to 64/32-bit unsigned integer
20 * 1) A standard strtoul() function that supports 64-bit integers, base
23 * constants than the runtime (interpreter) integer-to-string conversions.
29 * iASL - Preprocessor (constants and math expressions)
30 * iASL - Main parser, conversion of constants to integers
31 * iASL - Data Table Compiler parser (constants and math expressions)
32 * interpreter - Implicit and explicit conversions, GPE method names
33 * interpreter - Repair code for return values from predefined names
34 * debugger - Command line input string conversion
35 * acpi_dump - ACPI table physical addresses
36 * acpi_exec - Support for namespace overrides
40 * acpi_gbl_integer_byte_width is used to set the 32/64 bit limit for explicit
43 * acpi_ut_strtoul64 interface, all conversions are 64 bits. This interface is
44 * used primarily for iASL, where the default width is 64 bits for all parsers,
45 * but error checking is performed later to flag cases where a 64-bit constant
46 * is wrongly defined in a 32-bit DSDT/SSDT.
58 * PARAMETERS: string - Null terminated input string,
60 * return_value - Where the converted integer is
64 * 64-bit numeric overflow
67 * full 64-bit conversion, regardless of the current global
72 * iASL - Preprocessor (constants and math expressions)
73 * iASL - Main ASL parser, conversion of ASL constants to integers
74 * iASL - Data Table Compiler parser (constants and math expressions)
75 * interpreter - Repair code for return values from predefined names
76 * acpi_dump - ACPI table physical addresses
77 * acpi_exec - Support for namespace overrides
84 u32 base = 10; /* Default is decimal */ in acpi_ut_strtoul64() local
101 * 1) Check for a hex constant. A "0x" prefix indicates base 16. in acpi_ut_strtoul64()
104 base = 16; in acpi_ut_strtoul64()
109 * followed by sequence of octal digits (0-7) in acpi_ut_strtoul64()
112 base = 8; in acpi_ut_strtoul64()
120 * Force a full 64-bit conversion. The caller (usually iASL) must in acpi_ut_strtoul64()
121 * check for a 32-bit overflow later as necessary (If current mode in acpi_ut_strtoul64()
122 * is 32-bit, meaning a 32-bit DSDT). in acpi_ut_strtoul64()
125 acpi_gbl_integer_bit_width = 64; in acpi_ut_strtoul64()
128 * Perform the base 8, 10, or 16 conversion. A 64-bit numeric overflow in acpi_ut_strtoul64()
131 switch (base) { in acpi_ut_strtoul64()
146 /* Only possible exception from above is a 64-bit overflow */ in acpi_ut_strtoul64()
156 * PARAMETERS: string - Null terminated input string,
161 * DESCRIPTION: Perform a 64-bit conversion with restrictions placed upon
168 * -----------------------------------------------------------------------------
170 * Base is always 16, either with or without the 0x prefix. Decimal and
187 * (32 or 64 bits). There are no numeric overflow conditions. (NO ERROR)
189 * 3) The first non-hex character terminates the conversion and returns
192 * 4) Conversion of a null (zero-length) string to an integer is
201 * interpreter - All runtime implicit conversions, as per ACPI specification
202 * iASL - Data Table Compiler parser (constants and math expressions)
240 * PARAMETERS: string - Null terminated input string,
245 * DESCRIPTION: Perform a 64-bit conversion with the restrictions placed upon
249 * -----------------------------------------------------------------------------
251 * Base is either 10 (default) or 16 (with 0x prefix). Octal (base 8) strings
264 * (32 or 64 bits). The ACPI specification states the behavior is
268 * 3) Behavior on the first non-hex character is not defined by the ACPI
274 * 4) Conversion of a null (zero-length) string to an integer is
283 * interpreter - Runtime ASL to_integer operator, as per the ACPI specification
290 u32 base = 10; /* Default is decimal */ in acpi_ut_explicit_strtoul64() local
303 base = 16; in acpi_ut_explicit_strtoul64()
315 switch (base) { in acpi_ut_explicit_strtoul64()