	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ataama_set
_ataama_set:                            ## @ataama_set
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%ebx, %ebx
	subq	$1, %r8
	cmovaeq	%r8, %rbx
	movq	%rcx, %r14
	movl	%esi, %r12d
	movq	%rdi, %r15
	movq	_CAM_DIR_NONE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_AP_PROTO_NON_DATA@GOTPCREL(%rip), %rsi
	movq	_AP_EXTEND@GOTPCREL(%rip), %rdi
	movl	(%rdi), %r8d
	orl	(%rsi), %r8d
	movq	_AP_FLAG_CHK_COND@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r9d
	movq	_MSG_SIMPLE_Q_TAG@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r10d
	movq	_ATA_AMAX_ADDR@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r11d
	movq	_ATA_AMAX_ADDR_SET@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r13d
	testl	%edx, %edx
	movl	$30000, %eax                    ## imm = 0x7530
	cmovnel	%edx, %eax
	subq	$8, %rsp
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	%r12d, %edx
	pushq	$1
	pushq	%rax
	pushq	$0
	pushq	$0
	pushq	$0
	pushq	%rbx
	pushq	%r13
	pushq	%r11
	pushq	%r10
	callq	_ata_do_cmd
	addq	$80, %rsp
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	%r15, %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_atahpa_proc_resp               ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_CAM_DIR_NONE,4,2               ## @CAM_DIR_NONE
	.comm	_AP_PROTO_NON_DATA,4,2          ## @AP_PROTO_NON_DATA
	.comm	_AP_EXTEND,4,2                  ## @AP_EXTEND
	.comm	_AP_FLAG_CHK_COND,4,2           ## @AP_FLAG_CHK_COND
	.comm	_MSG_SIMPLE_Q_TAG,4,2           ## @MSG_SIMPLE_Q_TAG
	.comm	_ATA_AMAX_ADDR,4,2              ## @ATA_AMAX_ADDR
	.comm	_ATA_AMAX_ADDR_SET,4,2          ## @ATA_AMAX_ADDR_SET
	.no_dead_strip	_ataama_set
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ataama_set
_ataama_set:                            ; @ataama_set
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x19, x3
	mov	x8, x1
	mov	x20, x0
	sub	x9, x4, #1
Lloh0:
	adrp	x10, _CAM_DIR_NONE@GOTPAGE
Lloh1:
	ldr	x10, [x10, _CAM_DIR_NONE@GOTPAGEOFF]
	cmp	x4, #0
	csel	x9, xzr, x9, eq
Lloh2:
	ldr	w3, [x10]
Lloh3:
	adrp	x10, _AP_PROTO_NON_DATA@GOTPAGE
Lloh4:
	ldr	x10, [x10, _AP_PROTO_NON_DATA@GOTPAGEOFF]
Lloh5:
	adrp	x11, _AP_EXTEND@GOTPAGE
Lloh6:
	ldr	x11, [x11, _AP_EXTEND@GOTPAGEOFF]
Lloh7:
	ldr	w10, [x10]
Lloh8:
	ldr	w11, [x11]
	orr	w4, w11, w10
Lloh9:
	adrp	x10, _AP_FLAG_CHK_COND@GOTPAGE
Lloh10:
	ldr	x10, [x10, _AP_FLAG_CHK_COND@GOTPAGEOFF]
Lloh11:
	ldr	w5, [x10]
Lloh12:
	adrp	x10, _MSG_SIMPLE_Q_TAG@GOTPAGE
Lloh13:
	ldr	x10, [x10, _MSG_SIMPLE_Q_TAG@GOTPAGEOFF]
Lloh14:
	ldr	w6, [x10]
Lloh15:
	adrp	x10, _ATA_AMAX_ADDR@GOTPAGE
Lloh16:
	ldr	x10, [x10, _ATA_AMAX_ADDR@GOTPAGEOFF]
Lloh17:
	ldr	w7, [x10]
Lloh18:
	adrp	x10, _ATA_AMAX_ADDR_SET@GOTPAGE
Lloh19:
	ldr	x10, [x10, _ATA_AMAX_ADDR_SET@GOTPAGEOFF]
Lloh20:
	ldr	w10, [x10]
	mov	w11, #30000
	cmp	w2, #0
	csel	w11, w11, w2, eq
	mov	w12, #1
	stp	w11, w12, [sp, #36]
	str	wzr, [sp, #32]
	str	xzr, [sp, #24]
	str	wzr, [sp, #16]
	str	x9, [sp, #8]
	str	w10, [sp]
	mov	x1, x19
	mov	x2, x8
	bl	_ata_do_cmd
	cbz	w0, LBB0_2
; %bb.1:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_2:
	mov	x0, x20
	mov	x1, x19
	mov	x2, #0
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #80
	b	_atahpa_proc_resp
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_CAM_DIR_NONE,4,2               ; @CAM_DIR_NONE
	.comm	_AP_PROTO_NON_DATA,4,2          ; @AP_PROTO_NON_DATA
	.comm	_AP_EXTEND,4,2                  ; @AP_EXTEND
	.comm	_AP_FLAG_CHK_COND,4,2           ; @AP_FLAG_CHK_COND
	.comm	_MSG_SIMPLE_Q_TAG,4,2           ; @MSG_SIMPLE_Q_TAG
	.comm	_ATA_AMAX_ADDR,4,2              ; @ATA_AMAX_ADDR
	.comm	_ATA_AMAX_ADDR_SET,4,2          ; @ATA_AMAX_ADDR_SET
	.no_dead_strip	_ataama_set
.subsections_via_symbols
