	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fwphy_rddata
_fwphy_rddata:                          ## @fwphy_rddata
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	andl	$15, %esi
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movq	_PHYDEV_RDCMD@GOTPCREL(%rip), %r14
	movq	_OHCI_PHYACCESS@GOTPCREL(%rip), %r15
	xorl	%eax, %eax
	jmp	LBB0_1
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_1 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	leal	1(%rax), %r8d
	cmpl	$99, %eax
	jge	LBB0_17
LBB0_8:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	$100, %edi
	movl	%r8d, %ebx
	callq	_DELAY
	movl	%ebx, %eax
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_2 Depth 2
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	_FWOHCI_INTSTATCLR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_OHCI_INT_REG_FAIL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	callq	_OWRITE
	movq	_PHYDEV_REGADDR@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	shll	%cl, %edx
	orl	(%r14), %edx
	movl	(%r15), %esi
	movq	%r13, %rdi
	callq	_OWRITE
	xorl	%r12d, %r12d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=2
	movl	$100, %edi
	callq	_DELAY
	incl	%r12d
	cmpl	$100, %r12d
	je	LBB0_5
LBB0_2:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15), %esi
	movq	%r13, %rdi
	callq	_OREAD
	movl	%eax, %ebx
	testl	%eax, (%r14)
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=2
	movq	_PHYDEV_RDDONE@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_4
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	_firewire_debug@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	(%r13), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_device_printf
LBB0_7:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	leal	1(%rax), %r8d
	movl	$100, %r12d
	cmpl	$98, %eax
	movl	%r8d, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	jle	LBB0_8
LBB0_9:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	_FWOHCI_INTSTAT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_OREAD
	movq	_OHCI_INT_REG_FAIL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_1 Depth=1
	movq	_PHYDEV_REGADDR@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	%ebx, %eax
	sarl	%cl, %eax
	andl	$15, %eax
	cmpl	-44(%rbp), %eax                 ## 4-byte Folded Reload
	je	LBB0_14
LBB0_11:                                ##   in Loop: Header=BB0_1 Depth=1
	movq	_firewire_debug@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_1 Depth=1
	movl	(%r13), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_device_printf
	jmp	LBB0_13
LBB0_14:
	movq	_firewire_debug@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_15
## %bb.16:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, %r8d
	cmpl	$100, %eax
	jl	LBB0_18
	jmp	LBB0_17
LBB0_15:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, %r8d
LBB0_17:
	movl	(%r13), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_device_printf
LBB0_18:
	movq	_PHYDEV_RDDATA@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %ebx
	movzbl	%bl, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FWOHCI_INTSTATCLR,4,2          ## @FWOHCI_INTSTATCLR
	.comm	_OHCI_INT_REG_FAIL,4,2          ## @OHCI_INT_REG_FAIL
	.comm	_PHYDEV_RDCMD,4,2               ## @PHYDEV_RDCMD
	.comm	_PHYDEV_REGADDR,4,2             ## @PHYDEV_REGADDR
	.comm	_OHCI_PHYACCESS,4,2             ## @OHCI_PHYACCESS
	.comm	_PHYDEV_RDDONE,4,2              ## @PHYDEV_RDDONE
	.comm	_firewire_debug,8,3             ## @firewire_debug
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"phy read failed(1).\n"

	.comm	_FWOHCI_INTSTAT,4,2             ## @FWOHCI_INTSTAT
L_.str.1:                               ## @.str.1
	.asciz	"phy read failed(2).\n"

L_.str.2:                               ## @.str.2
	.asciz	"fwphy_rddata: 0x%x loop=%d, retry=%d\n"

	.comm	_PHYDEV_RDDATA,4,2              ## @PHYDEV_RDDATA
	.comm	_MAX_RETRY,4,2                  ## @MAX_RETRY
	.no_dead_strip	_fwphy_rddata
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fwphy_rddata
_fwphy_rddata:                          ; @fwphy_rddata
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	mov	w20, #0
	and	w23, w1, #0xf
Lloh0:
	adrp	x25, _OHCI_INT_REG_FAIL@GOTPAGE
Lloh1:
	ldr	x25, [x25, _OHCI_INT_REG_FAIL@GOTPAGEOFF]
Lloh2:
	adrp	x26, _PHYDEV_RDCMD@GOTPAGE
Lloh3:
	ldr	x26, [x26, _PHYDEV_RDCMD@GOTPAGEOFF]
Lloh4:
	adrp	x28, _OHCI_PHYACCESS@GOTPAGE
Lloh5:
	ldr	x28, [x28, _OHCI_PHYACCESS@GOTPAGEOFF]
Lloh6:
	adrp	x21, _PHYDEV_RDDONE@GOTPAGE
Lloh7:
	ldr	x21, [x21, _PHYDEV_RDDONE@GOTPAGEOFF]
	b	LBB0_3
LBB0_1:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w8, w27, #1
	cmp	w27, #99
	mov	x27, x8
	b.ge	LBB0_19
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	w0, #100
	bl	_DELAY
	mov	x20, x27
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
Lloh8:
	adrp	x8, _FWOHCI_INTSTATCLR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _FWOHCI_INTSTATCLR@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	ldr	w2, [x25]
	mov	x0, x19
	bl	_OWRITE
	ldr	w8, [x26]
Lloh11:
	adrp	x9, _PHYDEV_REGADDR@GOTPAGE
Lloh12:
	ldr	x9, [x9, _PHYDEV_REGADDR@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	lsl	w9, w23, w9
	orr	w2, w9, w8
	ldr	w1, [x28]
	mov	x0, x19
	bl	_OWRITE
	mov	w24, #0
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=2
	mov	w0, #100
	bl	_DELAY
	add	w24, w24, #1
	cmp	w24, #100
	b.eq	LBB0_8
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w1, [x28]
	mov	x0, x19
	bl	_OREAD
	mov	x22, x0
	ldr	w8, [x26]
	tst	w8, w0
	b.ne	LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=2
	ldr	w8, [x21]
	tst	w8, w22
	b.eq	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x27, x20
	b	LBB0_12
LBB0_8:                                 ;   in Loop: Header=BB0_3 Depth=1
Lloh14:
	adrp	x8, _firewire_debug@GOTPAGE
Lloh15:
	ldr	x8, [x8, _firewire_debug@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cbz	x8, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x19]
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	bl	_device_printf
LBB0_10:                                ;   in Loop: Header=BB0_3 Depth=1
	add	w27, w20, #1
	cmp	w20, #98
	b.le	LBB0_2
; %bb.11:                               ;   in Loop: Header=BB0_3 Depth=1
	mov	w24, #100
LBB0_12:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh19:
	adrp	x8, _FWOHCI_INTSTAT@GOTPAGE
Lloh20:
	ldr	x8, [x8, _FWOHCI_INTSTAT@GOTPAGEOFF]
Lloh21:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_OREAD
	ldr	w8, [x25]
	tst	w8, w0
	b.ne	LBB0_14
; %bb.13:                               ;   in Loop: Header=BB0_3 Depth=1
Lloh22:
	adrp	x8, _PHYDEV_REGADDR@GOTPAGE
Lloh23:
	ldr	x8, [x8, _PHYDEV_REGADDR@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	asr	w8, w22, w8
	and	w8, w8, #0xf
	cmp	w8, w23
	b.eq	LBB0_16
LBB0_14:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh25:
	adrp	x8, _firewire_debug@GOTPAGE
Lloh26:
	ldr	x8, [x8, _firewire_debug@GOTPAGEOFF]
Lloh27:
	ldr	x8, [x8]
	cbz	x8, LBB0_1
; %bb.15:                               ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x19]
Lloh28:
	adrp	x1, l_.str.1@PAGE
Lloh29:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_device_printf
	b	LBB0_1
LBB0_16:
Lloh30:
	adrp	x8, _firewire_debug@GOTPAGE
Lloh31:
	ldr	x8, [x8, _firewire_debug@GOTPAGEOFF]
Lloh32:
	ldr	x8, [x8]
	cbnz	x8, LBB0_18
; %bb.17:
	mov	x8, x27
	cmp	w27, #100
	b.lt	LBB0_20
	b	LBB0_19
LBB0_18:
	mov	x8, x27
LBB0_19:
	ldr	w0, [x19]
	stp	x24, x8, [sp, #8]
	str	x23, [sp]
Lloh33:
	adrp	x1, l_.str.2@PAGE
Lloh34:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_device_printf
LBB0_20:
Lloh35:
	adrp	x8, _PHYDEV_RDDATA@GOTPAGE
Lloh36:
	ldr	x8, [x8, _PHYDEV_RDDATA@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
	asr	w8, w22, w8
	and	w0, w8, #0xff
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_FWOHCI_INTSTATCLR,4,2          ; @FWOHCI_INTSTATCLR
	.comm	_OHCI_INT_REG_FAIL,4,2          ; @OHCI_INT_REG_FAIL
	.comm	_PHYDEV_RDCMD,4,2               ; @PHYDEV_RDCMD
	.comm	_PHYDEV_REGADDR,4,2             ; @PHYDEV_REGADDR
	.comm	_OHCI_PHYACCESS,4,2             ; @OHCI_PHYACCESS
	.comm	_PHYDEV_RDDONE,4,2              ; @PHYDEV_RDDONE
	.comm	_firewire_debug,8,3             ; @firewire_debug
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"phy read failed(1).\n"

	.comm	_FWOHCI_INTSTAT,4,2             ; @FWOHCI_INTSTAT
l_.str.1:                               ; @.str.1
	.asciz	"phy read failed(2).\n"

l_.str.2:                               ; @.str.2
	.asciz	"fwphy_rddata: 0x%x loop=%d, retry=%d\n"

	.comm	_PHYDEV_RDDATA,4,2              ; @PHYDEV_RDDATA
	.comm	_MAX_RETRY,4,2                  ; @MAX_RETRY
	.no_dead_strip	_fwphy_rddata
.subsections_via_symbols
