Files
OpenCellular/builtin/string.h
Nadim Taha 69c3fc2378 builtin: Expands string.h / stdint.h
Declares UINT8_MAX, INT8_MAX and defines strnlen(), strncpy(), strncmp() &
memchr(). Needed by a module I'm integrating into cr51.

BRANCH=none
BUG=none
TEST=make buildall -j

Change-Id: I894b0297216df1b945b36fc77cd3bc5c4ef8aa2b
Signed-off-by: Nadim Taha <ntaha@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/436786
Reviewed-by: Randall Spangler <rspangler@chromium.org>
2017-02-17 01:46:31 +00:00

24 lines
765 B
C

/* Copyright 2016 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/* This header is only needed for CR50 compatibility */
#ifndef __CROS_EC_STRINGS_H__
#define __CROS_EC_STRINGS_H__
#include <stddef.h>
int memcmp(const void *s1, const void *s2, size_t len);
void *memcpy(void *dest, const void *src, size_t len);
void *memmove(void *dest, const void *src, size_t n);
void *memset(void *dest, int c, size_t len);
void *memchr(const void *buffer, int c, size_t n);
size_t strnlen(const char *s, size_t maxlen);
char *strncpy(char *dest, const char *src, size_t n);
int strncmp(const char *s1, const char *s2, size_t n);
#endif /* __CROS_EC_STRINGS_H__ */