	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pvr2_hdw_setup
_pvr2_hdw_setup:                        ## @pvr2_hdw_setup
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_PVR2_TRACE_INIT@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_pvr2_trace
	movq	%r14, %rdi
	callq	_pvr2_hdw_setup_low
	movl	(%r15), %ebx
	movq	%r14, %rdi
	callq	_pvr2_hdw_dev_ok
	movq	16(%r14), %r8
	leaq	L_.str.1(%rip), %rsi
	movl	%ebx, %edi
	movq	%r14, %rdx
	movq	%rax, %rcx
	xorl	%eax, %eax
	callq	_pvr2_trace
	movq	%r14, %rdi
	callq	_pvr2_hdw_dev_ok
	testq	%rax, %rax
	je	LBB0_7
## %bb.1:
	cmpq	$0, 16(%r14)
	je	LBB0_3
## %bb.2:
	movq	_PVR2_TRACE_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_12
LBB0_3:
	movq	(%r14), %rax
	movq	_FW1_STATE_RELOAD@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
## %bb.4:
	movq	_PVR2_TRACE_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_12
LBB0_5:
	movq	_PVR2_TRACE_ERROR_LEGS@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	leaq	L_.str.4(%rip), %rsi
	xorl	%eax, %eax
	callq	_pvr2_trace
	movq	(%r14), %rax
	movq	_FW1_STATE_MISSING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_7
## %bb.6:
	movl	(%rbx), %edi
	leaq	L_.str.5(%rip), %rsi
	jmp	LBB0_12
LBB0_7:
	cmpq	$0, 8(%r14)
	je	LBB0_9
## %bb.8:
	movq	_PVR2_TRACE_ERROR_LEGS@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	leaq	L_.str.6(%rip), %rsi
	xorl	%eax, %eax
	callq	_pvr2_trace
	movl	(%rbx), %edi
	leaq	L_.str.7(%rip), %rsi
LBB0_12:
	xorl	%eax, %eax
	callq	_pvr2_trace
LBB0_13:
	movl	(%r15), %edi
	leaq	L_.str.12(%rip), %rsi
	movq	%r14, %rdx
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pvr2_trace                     ## TAILCALL
LBB0_9:
	movq	_procreload@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	movq	_PVR2_TRACE_ERROR_LEGS@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	je	LBB0_11
## %bb.10:
	leaq	L_.str.8(%rip), %rsi
	xorl	%eax, %eax
	callq	_pvr2_trace
	movl	(%rbx), %edi
	leaq	L_.str.9(%rip), %rsi
	xorl	%eax, %eax
	callq	_pvr2_trace
	movq	_FW1_STATE_UNKNOWN@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r14)
	movq	%r14, %rdi
	callq	_pvr2_upload_firmware1
	jmp	LBB0_13
LBB0_11:
	leaq	L_.str.10(%rip), %rsi
	xorl	%eax, %eax
	callq	_pvr2_trace
	movl	(%rbx), %edi
	leaq	L_.str.11(%rip), %rsi
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_PVR2_TRACE_INIT,4,2            ## @PVR2_TRACE_INIT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pvr2_hdw_setup(hdw=%p) begin"

L_.str.1:                               ## @.str.1
	.asciz	"pvr2_hdw_setup(hdw=%p) done, ok=%d init_ok=%d"

	.comm	_PVR2_TRACE_INFO,4,2            ## @PVR2_TRACE_INFO
L_.str.2:                               ## @.str.2
	.asciz	"Device initialization completed successfully."

	.comm	_FW1_STATE_RELOAD,8,3           ## @FW1_STATE_RELOAD
L_.str.3:                               ## @.str.3
	.asciz	"Device microcontroller firmware (re)loaded; it should now reset and reconnect."

	.comm	_PVR2_TRACE_ERROR_LEGS,4,2      ## @PVR2_TRACE_ERROR_LEGS
L_.str.4:                               ## @.str.4
	.asciz	"Device initialization was not successful."

	.comm	_FW1_STATE_MISSING,8,3          ## @FW1_STATE_MISSING
L_.str.5:                               ## @.str.5
	.asciz	"Giving up since device microcontroller firmware appears to be missing."

L_.str.6:                               ## @.str.6
	.asciz	"***WARNING*** pvrusb2 driver initialization failed due to the failure of one or more sub-device kernel modules."

L_.str.7:                               ## @.str.7
	.asciz	"You need to resolve the failing condition before this driver can function.  There should be some earlier messages giving more information about the problem."

	.comm	_procreload,8,3                 ## @procreload
L_.str.8:                               ## @.str.8
	.asciz	"Attempting pvrusb2 recovery by reloading primary firmware."

L_.str.9:                               ## @.str.9
	.asciz	"If this works, device should disconnect and reconnect in a sane state."

	.comm	_FW1_STATE_UNKNOWN,8,3          ## @FW1_STATE_UNKNOWN
L_.str.10:                              ## @.str.10
	.asciz	"***WARNING*** pvrusb2 device hardware appears to be jammed and I can't clear it."

L_.str.11:                              ## @.str.11
	.asciz	"You might need to power cycle the pvrusb2 device in order to recover."

L_.str.12:                              ## @.str.12
	.asciz	"pvr2_hdw_setup(hdw=%p) end"

	.no_dead_strip	_pvr2_hdw_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pvr2_hdw_setup
_pvr2_hdw_setup:                        ; @pvr2_hdw_setup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x0
Lloh0:
	adrp	x21, _PVR2_TRACE_INIT@GOTPAGE
Lloh1:
	ldr	x21, [x21, _PVR2_TRACE_INIT@GOTPAGEOFF]
	ldr	w0, [x21]
	str	x19, [sp]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_pvr2_trace
	mov	x0, x19
	bl	_pvr2_hdw_setup_low
	ldr	w20, [x21]
	mov	x0, x19
	bl	_pvr2_hdw_dev_ok
	ldr	x8, [x19, #16]
	stp	x0, x8, [sp, #8]
	str	x19, [sp]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_pvr2_trace
	mov	x0, x19
	bl	_pvr2_hdw_dev_ok
	cbz	x0, LBB0_7
; %bb.1:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_3
; %bb.2:
Lloh6:
	adrp	x8, _PVR2_TRACE_INFO@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PVR2_TRACE_INFO@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
Lloh9:
	adrp	x1, l_.str.2@PAGE
Lloh10:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_9
LBB0_3:
	ldr	x8, [x19]
Lloh11:
	adrp	x9, _FW1_STATE_RELOAD@GOTPAGE
Lloh12:
	ldr	x9, [x9, _FW1_STATE_RELOAD@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.4:
Lloh14:
	adrp	x8, _PVR2_TRACE_INFO@GOTPAGE
Lloh15:
	ldr	x8, [x8, _PVR2_TRACE_INFO@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
Lloh17:
	adrp	x1, l_.str.3@PAGE
Lloh18:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_9
LBB0_5:
Lloh19:
	adrp	x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGE
Lloh20:
	ldr	x20, [x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGEOFF]
	ldr	w0, [x20]
Lloh21:
	adrp	x1, l_.str.4@PAGE
Lloh22:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_pvr2_trace
	ldr	x8, [x19]
Lloh23:
	adrp	x9, _FW1_STATE_MISSING@GOTPAGE
Lloh24:
	ldr	x9, [x9, _FW1_STATE_MISSING@GOTPAGEOFF]
Lloh25:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.6:
	ldr	w0, [x20]
Lloh26:
	adrp	x1, l_.str.5@PAGE
Lloh27:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_9
LBB0_7:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_11
; %bb.8:
Lloh28:
	adrp	x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGE
Lloh29:
	ldr	x20, [x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGEOFF]
	ldr	w0, [x20]
Lloh30:
	adrp	x1, l_.str.6@PAGE
Lloh31:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_pvr2_trace
	ldr	w0, [x20]
Lloh32:
	adrp	x1, l_.str.7@PAGE
Lloh33:
	add	x1, x1, l_.str.7@PAGEOFF
LBB0_9:
	bl	_pvr2_trace
LBB0_10:
	ldr	w0, [x21]
	str	x19, [sp]
Lloh34:
	adrp	x1, l_.str.12@PAGE
Lloh35:
	add	x1, x1, l_.str.12@PAGEOFF
	bl	_pvr2_trace
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_11:
Lloh36:
	adrp	x8, _procreload@GOTPAGE
Lloh37:
	ldr	x8, [x8, _procreload@GOTPAGEOFF]
Lloh38:
	ldr	x8, [x8]
Lloh39:
	adrp	x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGE
Lloh40:
	ldr	x20, [x20, _PVR2_TRACE_ERROR_LEGS@GOTPAGEOFF]
	ldr	w0, [x20]
	cbz	x8, LBB0_13
; %bb.12:
Lloh41:
	adrp	x1, l_.str.8@PAGE
Lloh42:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_pvr2_trace
	ldr	w0, [x20]
Lloh43:
	adrp	x1, l_.str.9@PAGE
Lloh44:
	add	x1, x1, l_.str.9@PAGEOFF
	bl	_pvr2_trace
Lloh45:
	adrp	x8, _FW1_STATE_UNKNOWN@GOTPAGE
Lloh46:
	ldr	x8, [x8, _FW1_STATE_UNKNOWN@GOTPAGEOFF]
Lloh47:
	ldr	x8, [x8]
	str	x8, [x19]
	mov	x0, x19
	bl	_pvr2_upload_firmware1
	b	LBB0_10
LBB0_13:
Lloh48:
	adrp	x1, l_.str.10@PAGE
Lloh49:
	add	x1, x1, l_.str.10@PAGEOFF
	bl	_pvr2_trace
	ldr	w0, [x20]
Lloh50:
	adrp	x1, l_.str.11@PAGE
Lloh51:
	add	x1, x1, l_.str.11@PAGEOFF
	b	LBB0_9
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpAdd	Lloh41, Lloh42
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpAdd	Lloh48, Lloh49
	.cfi_endproc
                                        ; -- End function
	.comm	_PVR2_TRACE_INIT,4,2            ; @PVR2_TRACE_INIT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pvr2_hdw_setup(hdw=%p) begin"

l_.str.1:                               ; @.str.1
	.asciz	"pvr2_hdw_setup(hdw=%p) done, ok=%d init_ok=%d"

	.comm	_PVR2_TRACE_INFO,4,2            ; @PVR2_TRACE_INFO
l_.str.2:                               ; @.str.2
	.asciz	"Device initialization completed successfully."

	.comm	_FW1_STATE_RELOAD,8,3           ; @FW1_STATE_RELOAD
l_.str.3:                               ; @.str.3
	.asciz	"Device microcontroller firmware (re)loaded; it should now reset and reconnect."

	.comm	_PVR2_TRACE_ERROR_LEGS,4,2      ; @PVR2_TRACE_ERROR_LEGS
l_.str.4:                               ; @.str.4
	.asciz	"Device initialization was not successful."

	.comm	_FW1_STATE_MISSING,8,3          ; @FW1_STATE_MISSING
l_.str.5:                               ; @.str.5
	.asciz	"Giving up since device microcontroller firmware appears to be missing."

l_.str.6:                               ; @.str.6
	.asciz	"***WARNING*** pvrusb2 driver initialization failed due to the failure of one or more sub-device kernel modules."

l_.str.7:                               ; @.str.7
	.asciz	"You need to resolve the failing condition before this driver can function.  There should be some earlier messages giving more information about the problem."

	.comm	_procreload,8,3                 ; @procreload
l_.str.8:                               ; @.str.8
	.asciz	"Attempting pvrusb2 recovery by reloading primary firmware."

l_.str.9:                               ; @.str.9
	.asciz	"If this works, device should disconnect and reconnect in a sane state."

	.comm	_FW1_STATE_UNKNOWN,8,3          ; @FW1_STATE_UNKNOWN
l_.str.10:                              ; @.str.10
	.asciz	"***WARNING*** pvrusb2 device hardware appears to be jammed and I can't clear it."

l_.str.11:                              ; @.str.11
	.asciz	"You might need to power cycle the pvrusb2 device in order to recover."

l_.str.12:                              ; @.str.12
	.asciz	"pvr2_hdw_setup(hdw=%p) end"

	.no_dead_strip	_pvr2_hdw_setup
.subsections_via_symbols
