diff options
author | Simon Glass <sjg@chromium.org> | 2021-10-09 09:28:21 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-10-09 13:09:56 -0400 |
commit | 2a2d8e94ddc75c2c8d456e9163aa5dac510badcf (patch) | |
tree | e085b4c6bf58d86374bc541da07bf26716f274a1 /include/u-boot/lz4.h | |
parent | 94e922c76a0e1fcdead3359e340f53fd0709a963 (diff) | |
download | u-boot-2a2d8e94ddc75c2c8d456e9163aa5dac510badcf.tar.gz |
lz4: Use a private header for U-Boot
At present U-Boot has a header file called lz4.h for its own use. If the
host has its own lz4 header file installed (e.g. from the 'liblz4-dev'
package) then host builds will use that instead.
Move the U-Boot file into its own directory, as is done with various
other headers with the same problem.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/u-boot/lz4.h')
-rw-r--r-- | include/u-boot/lz4.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/include/u-boot/lz4.h b/include/u-boot/lz4.h new file mode 100644 index 00000000000..1276fb98a34 --- /dev/null +++ b/include/u-boot/lz4.h @@ -0,0 +1,24 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Copyright 2019 Google LLC + */ + +#ifndef __LZ4_H +#define __LZ4_H + +/** + * ulz4fn() - Decompress LZ4 data + * + * @src: Source data to decompress + * @srcn: Length of source data + * @dst: Destination for uncompressed data + * @dstn: Returns length of uncompressed data + * @return 0 if OK, -EPROTONOSUPPORT if the magic number or version number are + * not recognised or independent blocks are used, -EINVAL if the reserved + * fields are non-zero, or input is overrun, -EENOBUFS if the destination + * buffer is overrun, -EEPROTO if the compressed data causes an error in + * the decompression algorithm + */ +int ulz4fn(const void *src, size_t srcn, void *dst, size_t *dstn); + +#endif |