diff --git a/include/ucore/hash.h b/include/ucore/hash.h index 750b446..3c185d8 100644 --- a/include/ucore/hash.h +++ b/include/ucore/hash.h @@ -28,6 +28,8 @@ uc_pjwhash(const char *str,size_t len); uint32_t uc_sax_hash(void *key, size_t len); +unsigned long +uc_sdbmhash(const unsigned char *str); #ifdef __cplusplus } #endif diff --git a/include/ucore/iomux.h b/include/ucore/iomux.h index 414ce21..efcc3a1 100644 --- a/include/ucore/iomux.h +++ b/include/ucore/iomux.h @@ -137,6 +137,13 @@ struct UCTimers *iomux_get_timers(struct IOMux *mux); * or indirectly by the UCTimers provieded in a timer callback handler. */ struct IOMux *iomux_from_timers(struct UCTimers *timers); + + +/** Get the clock associated with the IOMux. This is the clock used + * used to drive the UCTimers associated with this IOMux + */ +struct UCoreClock *iomux_get_clock(struct IOMux *mux); + #ifdef __cplusplus } #endif diff --git a/src/sdmhash.c b/src/sdmhash.c index da7d0fb..6fde471 100644 --- a/src/sdmhash.c +++ b/src/sdmhash.c @@ -1,3 +1,5 @@ +#include "ucore/hash.h" + unsigned long uc_sdbmhash(const unsigned char *str) { diff --git a/src/strlcpy.c b/src/strlcpy.c index 6f9682a..36c3e6b 100644 --- a/src/strlcpy.c +++ b/src/strlcpy.c @@ -1,4 +1,5 @@ #include +#include "ucore/string.h" size_t uc_strlcpy(char *restrict dst, const char *restrict src, size_t max) { diff --git a/src/supervisor.c b/src/supervisor.c index b5f41d8..783ef7a 100644 --- a/src/supervisor.c +++ b/src/supervisor.c @@ -8,6 +8,7 @@ #include #include #include +#include "ucore/supervisor.h" #define CLEAN_EXIT 11