	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_addr
_set_addr:                              ## @set_addr
	.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, %ebx
	movl	%esi, %r12d
	callq	_mtd_to_flctl
	movq	%rax, %r14
	cmpl	$-1, %r12d
	je	LBB0_7
## %bb.1:
	cmpl	$-1, %ebx
	je	LBB0_2
## %bb.3:
	cmpq	$0, 8(%r14)
	je	LBB0_6
## %bb.4:
	andl	$4095, %r12d                    ## imm = 0xFFF
	movl	%ebx, %r15d
	shll	$16, %r15d
	movl	%r15d, %eax
	andl	$16711680, %eax                 ## imm = 0xFF0000
	orl	%r12d, %eax
	andl	$-16777216, %r15d               ## imm = 0xFF000000
	orl	%eax, %r15d
	movq	(%r14), %rax
	movq	_ADRCNT2_E@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_8
## %bb.5:
	shrl	$16, %ebx
	movzbl	%bl, %ebx
	movq	%r14, %rdi
	callq	_FLADR2
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_writel
	jmp	LBB0_8
LBB0_2:
	xorl	%r15d, %r15d
	jmp	LBB0_8
LBB0_6:
	shll	$8, %ebx
	movzwl	%bx, %eax
	orl	%r12d, %eax
	movl	%ebx, %ecx
	andl	$16711680, %ecx                 ## imm = 0xFF0000
	andl	$-16777216, %ebx                ## imm = 0xFF000000
	orl	%ecx, %ebx
	orl	%eax, %ebx
LBB0_7:
	movl	%ebx, %r15d
LBB0_8:
	movq	%r14, %rdi
	callq	_FLADR
	movl	%r15d, %edi
	movl	%eax, %esi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writel                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ADRCNT2_E,8,3                  ## @ADRCNT2_E
	.no_dead_strip	_set_addr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_addr
_set_addr:                              ; @set_addr
	.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	x20, x1
	bl	_mtd_to_flctl
	mov	x19, x0
	cmn	w20, #1
	b.eq	LBB0_5
; %bb.1:
	cmn	w21, #1
	b.eq	LBB0_6
; %bb.2:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_7
; %bb.3:
	and	w20, w20, #0xfff
	lsr	w8, w21, #8
	bfi	w20, w21, #16, #8
	bfi	w20, w8, #24, #8
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _ADRCNT2_E@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ADRCNT2_E@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.4:
	ubfx	w21, w21, #16, #8
	mov	x0, x19
	bl	_FLADR2
	mov	x1, x0
	mov	x0, x21
	bl	_writel
	b	LBB0_8
LBB0_5:
	mov	x20, x21
	b	LBB0_8
LBB0_6:
	mov	w20, #0
	b	LBB0_8
LBB0_7:
	lsl	w8, w21, #8
	and	w9, w8, #0xff00
	orr	w9, w9, w20
	and	w10, w8, #0xff0000
	orr	w9, w9, w10
	and	w8, w8, #0xff000000
	orr	w20, w9, w8
LBB0_8:
	mov	x0, x19
	bl	_FLADR
	mov	x1, x0
	mov	x0, x20
	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	_writel
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_ADRCNT2_E,8,3                  ; @ADRCNT2_E
	.no_dead_strip	_set_addr
.subsections_via_symbols
