Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
summeros
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Byron Lathi
summeros
Commits
05f30526
Commit
05f30526
authored
3 years ago
by
Byron Lathi
Browse files
Options
Downloads
Patches
Plain Diff
add memcpy
shamelessly stolen from newlib
parent
c245b210
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
kernel/lib.c
+14
-0
14 additions, 0 deletions
kernel/lib.c
kernel/lib.h
+1
-0
1 addition, 0 deletions
kernel/lib.h
with
15 additions
and
0 deletions
kernel/lib.c
+
14
−
0
View file @
05f30526
...
...
@@ -322,6 +322,20 @@ uint32_t strncpy(const int8_t* src, int8_t* dest, uint32_t n)
return
0
;
}
void
*
memccpy
(
void
*
__restrict
dst0
,
const
void
*
__restrict
src0
,
uint32_t
len0
)
{
void
*
ptr
=
NULL
;
char
*
dst
=
(
char
*
)
dst0
;
char
*
src
=
(
char
*
)
src0
;
while
(
len0
--
)
{
*
dst
++
=
*
src
++
;
}
return
ptr
;
}
/*
* These font data were read out of video memory during text mode and
...
...
This diff is collapsed.
Click to expand it.
kernel/lib.h
+
1
−
0
View file @
05f30526
...
...
@@ -33,6 +33,7 @@ uint32_t strlen(const int8_t* s);
uint32_t
strncmp
(
const
int8_t
*
a
,
const
int8_t
*
b
,
uint32_t
n
);
uint32_t
strcpy
(
const
int8_t
*
src
,
int8_t
*
dest
);
uint32_t
strncpy
(
const
int8_t
*
src
,
int8_t
*
dest
,
uint32_t
n
);
void
*
memccpy
(
void
*
__restrict
dst0
,
const
void
*
__restrict
src0
,
uint32_t
len0
);
void
clear
(
void
);
extern
unsigned
char
font_data
[
256
][
16
];
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment