1314bcbf0SMark Brown // SPDX-License-Identifier: GPL-2.0 2314bcbf0SMark Brown /* 3314bcbf0SMark Brown * Copyright (C) 2019 Arm Limited 4314bcbf0SMark Brown * Original author: Dave Martin <Dave.Martin@arm.com> 5314bcbf0SMark Brown */ 6314bcbf0SMark Brown 7314bcbf0SMark Brown #include "system.h" 8314bcbf0SMark Brown 9314bcbf0SMark Brown #include <asm/unistd.h> 10314bcbf0SMark Brown exit(int n)11314bcbf0SMark Brownvoid __noreturn exit(int n) 12314bcbf0SMark Brown { 13314bcbf0SMark Brown syscall(__NR_exit, n); 14*672dbf97SMark Brown unreachable(); 15314bcbf0SMark Brown } 16314bcbf0SMark Brown write(int fd,const void * buf,size_t size)17314bcbf0SMark Brownssize_t write(int fd, const void *buf, size_t size) 18314bcbf0SMark Brown { 19314bcbf0SMark Brown return syscall(__NR_write, fd, buf, size); 20314bcbf0SMark Brown } 21