Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F142260283
D53248.id165566.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
919 B
Referenced Files
None
Subscribers
None
D53248.id165566.diff
View Options
diff --git a/lib/libc/riscv/string/Makefile.inc b/lib/libc/riscv/string/Makefile.inc
--- a/lib/libc/riscv/string/Makefile.inc
+++ b/lib/libc/riscv/string/Makefile.inc
@@ -1,4 +1,6 @@
MDSRCS+= \
+ bcopy.c \
+ bzero.c \
memchr.S \
memcpy.S \
memset.S \
diff --git a/lib/libc/riscv/string/bcopy.c b/lib/libc/riscv/string/bcopy.c
new file mode 100644
--- /dev/null
+++ b/lib/libc/riscv/string/bcopy.c
@@ -0,0 +1,14 @@
+/*-
+ * Public domain.
+ */
+
+#include <string.h>
+
+#undef bcopy /* _FORTIFY_SOURCE */
+
+void
+bcopy(const void *src, void *dst, size_t len)
+{
+
+ memmove(dst, src, len);
+}
diff --git a/lib/libc/riscv/string/bzero.c b/lib/libc/riscv/string/bzero.c
new file mode 100644
--- /dev/null
+++ b/lib/libc/riscv/string/bzero.c
@@ -0,0 +1,14 @@
+/*-
+ * Public domain.
+ */
+
+#include <string.h>
+
+#undef bzero /* _FORTIFY_SOURCE */
+
+void
+bzero(void *b, size_t len)
+{
+
+ memset(b, 0, len);
+}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Jan 18, 10:05 PM (21 m, 31 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
27720695
Default Alt Text
D53248.id165566.diff (919 B)
Attached To
Mode
D53248: libc/riscv64: implement bcopy() and bzero() through memcpy() and memset()
Attached
Detach File
Event Timeline
Log In to Comment