xref: /netbsd/lib/libc/arch/powerpc/sys/pipe.S (revision bf9ec67e)
1/*	$NetBSD: pipe.S,v 1.6 2000/09/28 08:38:54 kleink Exp $	*/
2
3#include "SYS.h"
4
5#ifdef WEAK_ALIAS
6WEAK_ALIAS(pipe, _pipe)
7#endif
8
9ENTRY(_pipe)
10	mr	5,3		# save pointer
11	li	0,SYS_pipe
12	sc			# assume, that r5 is kept
13	bso	1f
14	stw	3,0(5)		# success, store fds
15	stw	4,4(5)
16	li	3,0
17	blr			# and return 0
181:
19	b	PIC_PLT(_C_LABEL(__cerror))
20