blob: e60acf3d07d40e990db29117226c25e72a99835e [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Martyn Welch66697ce2017-11-08 15:35:15 +00002/*
3 * Copyright 2016 General Electric Company
Martyn Welch66697ce2017-11-08 15:35:15 +00004 */
5
6#include "common.h"
7
8/*
9 * Read VPD from given data, verify content, and call callback
10 * for each vital product data block.
11 *
12 * Returns Non-zero on error. Negative numbers encode errno.
13 */
14int vpd_reader(size_t size, u8 *data, void *userdata,
15 int (*fn)(void *userdata, u8 id, u8 version, u8 type,
16 size_t size, u8 const *data));