summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNico Huber <nico.huber@secunet.com>2021-06-16 17:48:40 +0000
committerWerner Zeh <werner.zeh@siemens.com>2021-06-18 04:39:26 +0000
commit358c84a5a8ac9119c2b73ff8c7ff13c6231e1786 (patch)
treeaa9d4e6b66f9a8c60f07fae76d3a0c36ba01ccc2
parentc538ce12ae4f8d577f5d510e5194771f0db6b023 (diff)
includes: Move *abs() declarations into `stdlib.h`
Change-Id: Id4df2d3210735bee737353d293450e59cf93bd9a Signed-off-by: Nico Huber <nico.huber@secunet.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/55593 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r--payloads/libpayload/include/libpayload.h3
-rw-r--r--payloads/libpayload/include/stdlib.h9
2 files changed, 9 insertions, 3 deletions
diff --git a/payloads/libpayload/include/libpayload.h b/payloads/libpayload/include/libpayload.h
index a33d8bb382..7701a052c2 100644
--- a/payloads/libpayload/include/libpayload.h
+++ b/payloads/libpayload/include/libpayload.h
@@ -441,9 +441,6 @@ int exec(long addr, int argc, char **argv);
*/
int bcd2dec(int b);
int dec2bcd(int d);
-int abs(int j);
-long int labs(long int j);
-long long int llabs(long long int j);
u8 bin2hex(u8 b);
u8 hex2bin(u8 h);
void hexdump(const void *memory, size_t length);
diff --git a/payloads/libpayload/include/stdlib.h b/payloads/libpayload/include/stdlib.h
index a6bc8e8b02..eb014f4533 100644
--- a/payloads/libpayload/include/stdlib.h
+++ b/payloads/libpayload/include/stdlib.h
@@ -201,6 +201,15 @@ int rand(void);
void srand(unsigned int seed);
/** @} */
+/**
+ * @defgroup misc Misc functions
+ * @{
+ */
+int abs(int j);
+long int labs(long int j);
+long long int llabs(long long int j);
+/** @} */
+
/* Enter remote GDB mode. Will initialize connection if not already up. */
void gdb_enter(void);
/* Disconnect existing GDB connection if one exists. */