	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mei_txe_setup_satt2            ## -- Begin function mei_txe_setup_satt2
	.p2align	4, 0x90
_mei_txe_setup_satt2:                   ## @mei_txe_setup_satt2
	.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
	movl	%edx, %r14d
	movl	%esi, %ebx
	movq	%rdi, %r12
	callq	_to_txe_hw
	movq	%rax, %r13
	movl	%ebx, %edi
	callq	_lower_32_bits
	movl	%eax, %r15d
	movl	%ebx, %edi
	callq	_upper_32_bits
	cmpl	$16, %eax
	jae	LBB0_1
## %bb.2:
	testb	$15, %r15b
	jne	LBB0_1
## %bb.3:
	testb	$4, %r14b
	jne	LBB0_1
## %bb.4:
	movl	%eax, %ebx
	movq	_SATT_RANGE_MAX@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	jge	LBB0_5
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_SATT2_CTRL_VALID_MSK@GOTPCREL(%rip), %rax
	movq	_SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %ebx
	orl	(%rax), %ebx
	movq	_SATT2_SAP_SIZE_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%r14d, %edx
	callq	_mei_txe_br_reg_write
	movq	_SATT2_BRG_BA_LSB_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%r15d, %edx
	callq	_mei_txe_br_reg_write
	movq	_SATT2_CTRL_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	movl	%ebx, %edx
	callq	_mei_txe_br_reg_write
	movl	(%r12), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edx
	movl	%r15d, %ecx
	movl	%ebx, %r8d
	callq	_dev_dbg
	xorl	%eax, %eax
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SATT_RANGE_MAX,4,2             ## @SATT_RANGE_MAX
	.comm	_SATT2_CTRL_VALID_MSK,4,2       ## @SATT2_CTRL_VALID_MSK
	.comm	_SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT,4,2 ## @SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT
	.comm	_SATT2_SAP_SIZE_REG,4,2         ## @SATT2_SAP_SIZE_REG
	.comm	_SATT2_BRG_BA_LSB_REG,4,2       ## @SATT2_BRG_BA_LSB_REG
	.comm	_SATT2_CTRL_REG,4,2             ## @SATT2_CTRL_REG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SATT2: SAP_SIZE_OFFSET=0x%08X, BRG_BA_LSB_OFFSET=0x%08X, CTRL_OFFSET=0x%08X\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mei_txe_setup_satt2            ; -- Begin function mei_txe_setup_satt2
	.p2align	2
_mei_txe_setup_satt2:                   ; @mei_txe_setup_satt2
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x2
	mov	x23, x1
	mov	x20, x0
	bl	_to_txe_hw
	mov	x22, x0
	mov	x0, x23
	bl	_lower_32_bits
	mov	x21, x0
	mov	x0, x23
	bl	_upper_32_bits
	cmp	w0, #16
	b.hs	LBB0_4
; %bb.1:
	tst	w21, #0xf
	b.ne	LBB0_4
; %bb.2:
	tbnz	w19, #2, LBB0_4
; %bb.3:
Lloh0:
	adrp	x8, _SATT_RANGE_MAX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SATT_RANGE_MAX@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w19
	b.ge	LBB0_6
LBB0_4:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_6:
Lloh6:
	adrp	x8, _SATT2_CTRL_VALID_MSK@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SATT2_CTRL_VALID_MSK@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	lsl	w9, w0, w9
	orr	w23, w9, w8
Lloh12:
	adrp	x8, _SATT2_SAP_SIZE_REG@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SATT2_SAP_SIZE_REG@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x22
	mov	x2, x19
	bl	_mei_txe_br_reg_write
Lloh15:
	adrp	x8, _SATT2_BRG_BA_LSB_REG@GOTPAGE
Lloh16:
	ldr	x8, [x8, _SATT2_BRG_BA_LSB_REG@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x22
	mov	x2, x21
	bl	_mei_txe_br_reg_write
Lloh18:
	adrp	x8, _SATT2_CTRL_REG@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SATT2_CTRL_REG@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x22
	mov	x2, x23
	bl	_mei_txe_br_reg_write
	ldr	w0, [x20]
Lloh21:
	adrp	x1, l_.str@PAGE
Lloh22:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	mov	x3, x21
	mov	x4, x23
	bl	_dev_dbg
	mov	w0, #0
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SATT_RANGE_MAX,4,2             ; @SATT_RANGE_MAX
	.comm	_SATT2_CTRL_VALID_MSK,4,2       ; @SATT2_CTRL_VALID_MSK
	.comm	_SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT,4,2 ; @SATT2_CTRL_BR_BASE_ADDR_REG_SHIFT
	.comm	_SATT2_SAP_SIZE_REG,4,2         ; @SATT2_SAP_SIZE_REG
	.comm	_SATT2_BRG_BA_LSB_REG,4,2       ; @SATT2_BRG_BA_LSB_REG
	.comm	_SATT2_CTRL_REG,4,2             ; @SATT2_CTRL_REG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SATT2: SAP_SIZE_OFFSET=0x%08X, BRG_BA_LSB_OFFSET=0x%08X, CTRL_OFFSET=0x%08X\n"

.subsections_via_symbols
