]> git.saurik.com Git - apple/xnu.git/blobdiff - libsyscall/custom/__pipe.s
xnu-4903.270.47.tar.gz
[apple/xnu.git] / libsyscall / custom / __pipe.s
index d375dddbd7a00754a9d014762bb7df9876e6bf94..0c527d5ea6671c375b03e744d167012798c70206 100644 (file)
@@ -46,6 +46,25 @@ PSEUDO(___pipe, pipe, 0, cerror_nocancel)
        xorl    %eax, %eax
        ret
 
+#elif defined(__arm__)
+
+MI_ENTRY_POINT(___pipe)
+       mov             r3,r0              // save fildes across syscall
+       SYSCALL_NONAME(pipe, 0, cerror_nocancel)
+       str     r0, [r3, #0]
+       str     r1, [r3, #4]
+       mov             r0,#0
+       bx              lr
+
+#elif defined(__arm64__)
+
+MI_ENTRY_POINT(___pipe)
+       mov             x9, x0                          // Stash FD array
+       SYSCALL_NONAME(pipe, 0, cerror_nocancel)
+       stp             w0, w1, [x9]            // Save results
+       mov             x0, #0                          // Success
+       ret                                                     // Done
+
 #else
 #error Unsupported architecture
 #endif