summaryrefslogtreecommitdiffstats
path: root/lib16/conio.c
blob: 96b03ca18b9d74daa0d53a89681d1225927f8ebe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#define SEG_BASE (*(const unsigned int *)0xfffc)

void puts(const char *s)
{
	int rv;

	/* XXX: should loop over this */
	asm volatile("int $0x80"
		     : "=a" (rv)
		     : "a" (4),	/* __NR_write */
		       "b" (1),
		       "c" ((unsigned int)s + SEG_BASE),
		       "d" (strlen(s)));
}