	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sata_oxnas_reset_ucode
_sata_oxnas_reset_ucode:                ## @sata_oxnas_reset_ucode
	.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	%edx, %r15d
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	(%rdi), %r12
	leaq	L_.str(%rip), %rdi
	callq	_DPRINTK
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.1:
	movq	_UNKNOWN_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_sata_oxnas_set_mode
	movq	_DEVICE_CONTROL@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	addq	(%r12), %rdi
	callq	_ioread32
	movl	%eax, %edi
	movq	_DEVICE_CONTROL_ATA_ERR_OVERRIDE@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	jmp	LBB0_3
LBB0_2:
	movq	_OXNASSATA_NOTRAID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_sata_oxnas_set_mode
	xorl	%edi, %edi
	movq	_PORT_ERROR_MASK@GOTPCREL(%rip), %rbx
LBB0_3:
	movq	(%rbx), %rsi
	addq	(%r12), %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_iowrite32                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ENTER\n"

	.comm	_UNKNOWN_MODE,4,2               ## @UNKNOWN_MODE
	.comm	_DEVICE_CONTROL,8,3             ## @DEVICE_CONTROL
	.comm	_DEVICE_CONTROL_ATA_ERR_OVERRIDE,4,2 ## @DEVICE_CONTROL_ATA_ERR_OVERRIDE
	.comm	_OXNASSATA_NOTRAID,4,2          ## @OXNASSATA_NOTRAID
	.comm	_PORT_ERROR_MASK,8,3            ## @PORT_ERROR_MASK
	.no_dead_strip	_sata_oxnas_reset_ucode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sata_oxnas_reset_ucode
_sata_oxnas_reset_ucode:                ; @sata_oxnas_reset_ucode
	.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, x2
	mov	x19, x1
	mov	x20, x0
	ldr	x22, [x0]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DPRINTK
	cbz	w21, LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _UNKNOWN_MODE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _UNKNOWN_MODE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x19
	bl	_sata_oxnas_set_mode
	ldr	x8, [x22]
Lloh5:
	adrp	x19, _DEVICE_CONTROL@GOTPAGE
Lloh6:
	ldr	x19, [x19, _DEVICE_CONTROL@GOTPAGEOFF]
	ldr	x9, [x19]
	add	x0, x9, x8
	bl	_ioread32
Lloh7:
	adrp	x8, _DEVICE_CONTROL_ATA_ERR_OVERRIDE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _DEVICE_CONTROL_ATA_ERR_OVERRIDE@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	orr	w0, w8, w0
	b	LBB0_3
LBB0_2:
Lloh10:
	adrp	x8, _OXNASSATA_NOTRAID@GOTPAGE
Lloh11:
	ldr	x8, [x8, _OXNASSATA_NOTRAID@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x19
	bl	_sata_oxnas_set_mode
	mov	w0, #0
Lloh13:
	adrp	x19, _PORT_ERROR_MASK@GOTPAGE
Lloh14:
	ldr	x19, [x19, _PORT_ERROR_MASK@GOTPAGEOFF]
LBB0_3:
	ldr	x8, [x22]
	ldr	x9, [x19]
	add	x1, x9, x8
	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
	b	_iowrite32
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ENTER\n"

	.comm	_UNKNOWN_MODE,4,2               ; @UNKNOWN_MODE
	.comm	_DEVICE_CONTROL,8,3             ; @DEVICE_CONTROL
	.comm	_DEVICE_CONTROL_ATA_ERR_OVERRIDE,4,2 ; @DEVICE_CONTROL_ATA_ERR_OVERRIDE
	.comm	_OXNASSATA_NOTRAID,4,2          ; @OXNASSATA_NOTRAID
	.comm	_PORT_ERROR_MASK,8,3            ; @PORT_ERROR_MASK
	.no_dead_strip	_sata_oxnas_reset_ucode
.subsections_via_symbols
