	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ether1394_send_packet
_ether1394_send_packet:                 ## @ether1394_send_packet
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	32(%rdi), %r12
	movl	(%r12), %edi
	callq	_ether1394_alloc_common_packet
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r14
	movq	(%rbx), %rax
	movq	_ETH1394_GASP@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_6
## %bb.3:
	addl	$8, %r15d
	movq	16(%rbx), %rdx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%r15d, %ecx
	callq	_ether1394_prep_gasp_packet
	jmp	LBB0_4
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	jmp	LBB0_8
LBB0_6:
	movl	(%r12), %esi
	movl	28(%rbx), %edx
	movl	24(%rbx), %ecx
	movq	16(%rbx), %rax
	movl	(%rax), %r8d
	movq	%r14, %rdi
	movl	%r15d, %r9d
	callq	_ether1394_prep_write_packet
	testq	%rax, %rax
	je	LBB0_4
## %bb.7:
	movq	%r14, %rdi
	callq	_hpsb_free_packet
	movq	_EAGAIN@GOTPCREL(%rip), %rcx
	jmp	LBB0_8
LBB0_4:
	movq	%r14, 8(%rbx)
	movq	_ether1394_complete_cb@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movq	%rbx, %rdx
	callq	_hpsb_set_packet_complete_task
	movq	%r14, %rdi
	callq	_hpsb_send_packet
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	jns	LBB0_9
## %bb.5:
	movq	%r14, %rdi
	callq	_ether1394_free_packet
	movq	_EIO@GOTPCREL(%rip), %rcx
LBB0_8:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ETH1394_GASP,8,3               ## @ETH1394_GASP
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_ether1394_complete_cb,4,2      ## @ether1394_complete_cb
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_ether1394_send_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ether1394_send_packet
_ether1394_send_packet:                 ; @ether1394_send_packet
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x21, x1
	mov	x20, x0
	ldr	x22, [x0, #32]
	ldr	w0, [x22]
	bl	_ether1394_alloc_common_packet
	cbz	x0, LBB0_3
; %bb.1:
	mov	x19, x0
	ldr	x8, [x20]
Lloh0:
	adrp	x9, _ETH1394_GASP@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ETH1394_GASP@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.2:
	add	w3, w21, #8
	ldr	x2, [x20, #16]
	mov	x0, x19
	mov	x1, x22
	bl	_ether1394_prep_gasp_packet
	b	LBB0_6
LBB0_3:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_9
LBB0_4:
	ldr	w1, [x22]
	ldp	w3, w2, [x20, #24]
	ldr	x8, [x20, #16]
	ldr	w4, [x8]
	mov	x0, x19
	mov	x5, x21
	bl	_ether1394_prep_write_packet
	cbz	x0, LBB0_6
; %bb.5:
	mov	x0, x19
	bl	_hpsb_free_packet
Lloh5:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
	b	LBB0_9
LBB0_6:
	str	x19, [x20, #8]
Lloh7:
	adrp	x8, _ether1394_complete_cb@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ether1394_complete_cb@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_hpsb_set_packet_complete_task
	mov	x0, x19
	bl	_hpsb_send_packet
	tbnz	x0, #63, LBB0_8
; %bb.7:
	mov	w0, #0
	b	LBB0_10
LBB0_8:
	mov	x0, x19
	bl	_ether1394_free_packet
Lloh10:
	adrp	x8, _EIO@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ETH1394_GASP,8,3               ; @ETH1394_GASP
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_ether1394_complete_cb,4,2      ; @ether1394_complete_cb
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_ether1394_send_packet
.subsections_via_symbols
