blob: d8007d8e947e82d2b3f7e1c978553e6dc51f8dc6 [file] [log] [blame]
Antonio Nino Diaz9eddb1e2018-08-16 14:53:05 +01001/*
Ambroise Vincentb237bca2019-02-13 15:58:00 +00002 * Copyright (c) 2013-2019, ARM Limited and Contributors. All rights reserved.
Antonio Nino Diaz9eddb1e2018-08-16 14:53:05 +01003 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#include <stddef.h>
Ambroise Vincentb237bca2019-02-13 15:58:00 +00008#include <string.h>
Antonio Nino Diaz9eddb1e2018-08-16 14:53:05 +01009
10void *memset(void *dst, int val, size_t count)
11{
12 char *ptr = dst;
13
14 while (count--)
15 *ptr++ = val;
16
17 return dst;
18}