utest: add broadcast test
Signed-off-by: Michael Shaw <m@michaelsshaw.com>
This commit is contained in:
parent
7cd4063087
commit
f309a087a0
1 changed files with 9 additions and 0 deletions
|
|
@ -21,6 +21,15 @@ size_t strlen(const char *c)
|
||||||
|
|
||||||
void _start()
|
void _start()
|
||||||
{
|
{
|
||||||
|
int fd = open("/dev/broadcast", 0);
|
||||||
|
if (fd < 0)
|
||||||
|
while (1)
|
||||||
|
;
|
||||||
|
|
||||||
|
char msg[] = "Hello, userspace!\n";
|
||||||
|
write(fd, msg, strlen(msg));
|
||||||
|
close(fd);
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue