blob: f6ce8024bf47d74c677bbf0f030652bebbd1dfb2 [file] [log] [blame]
Julius Wernerdbba2b32019-05-24 20:31:15 -07001/*
2 * Copyright (c) 2019, ARM Limited and Contributors. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6#ifndef LIB_BL_AUX_PARAMS_H
7#define LIB_BL_AUX_PARAMS_H
8
9#include <stdbool.h>
10#include <stdint.h>
11
Julius Werner2a231e32019-05-28 21:03:58 -070012#include <export/lib/bl_aux_params/bl_aux_params_exp.h>
Julius Wernerdbba2b32019-05-24 20:31:15 -070013
14/*
15 * Handler function that handles an individual aux parameter. Return true if
16 * the parameter was handled, and flase if bl_aux_params_parse() should make its
17 * own attempt at handling it (for generic parameters).
18 */
19typedef bool (*bl_aux_param_handler_t)(struct bl_aux_param_header *param);
20
21/*
22 * Interprets head as the start of an aux parameter list, and passes the
23 * parameters individually to handler(). Handles generic parameters directly if
24 * handler() hasn't already done so. If only generic parameters are expected,
25 * handler() can be NULL.
26 */
27void bl_aux_params_parse(u_register_t head,
28 bl_aux_param_handler_t handler);
29
30#endif /* LIB_BL_AUX_PARAMS_H */