diff options
| author | Chin Liang See <[email protected]> | 2015-10-17 08:30:32 -0500 |
|---|---|---|
| committer | Marek Vasut <[email protected]> | 2015-11-05 02:34:14 +0100 |
| commit | bfa3e55b440e120739d2b4dd4cb57e6b40752113 (patch) | |
| tree | 0c4f2127712b1f0f2cee3dbc43c90203d584c5f5 /include | |
| parent | c624d07f3ff7ae7d29672bab189d2aeb99c63a95 (diff) | |
lib, fdt: Adding fdtdec_get_uint function
Adding fdtdec_get_uint function which is the
unsigned version for fdtdec_get_int
Signed-off-by: Chin Liang See <[email protected]>
Cc: Dinh Nguyen <[email protected]>
Cc: Dinh Nguyen <[email protected]>
Cc: Marek Vasut <[email protected]>
Cc: Stefan Roese <[email protected]>
Cc: Vikas Manocha <[email protected]>
Cc: Jagannadh Teki <[email protected]>
Cc: Pavel Machek <[email protected]>
Cc: Heiko Schocher <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/fdtdec.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/fdtdec.h b/include/fdtdec.h index 2de6dda04c5..d51e643ac3b 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -490,6 +490,19 @@ s32 fdtdec_get_int(const void *blob, int node, const char *prop_name, s32 default_val); /** + * Unsigned version of fdtdec_get_int. The property must have at least + * 4 bytes of data. The value of the first cell is returned. + * + * @param blob FDT blob + * @param node node to examine + * @param prop_name name of property to find + * @param default_val default value to return if the property is not found + * @return unsigned integer value, if found, or default_val if not + */ +unsigned int fdtdec_get_uint(const void *blob, int node, const char *prop_name, + unsigned int default_val); + +/** * Get a variable-sized number from a property * * This reads a number from one or more cells. |
