	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_mpegtei_handling
_set_mpegtei_handling:                  ## @set_mpegtei_handling
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	$0, -52(%rbp)
	movl	$0, -48(%rbp)
	movl	$0, -44(%rbp)
	movq	(%rdi), %r13
	movq	8(%rdi), %r14
	movq	_FEC_OC_DPR_MODE__A@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	leaq	-52(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_read_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.1:
	movq	_FEC_OC_SNC_MODE__A@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_read_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.2:
	movq	_FEC_OC_EMS_MODE__A@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_read_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.3:
	movq	_FEC_OC_DPR_MODE_ERR_DISABLE__M@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%ecx, %edx
	notl	%edx
	movl	-52(%rbp), %eax
	andl	%eax, %edx
	movl	%edx, -52(%rbp)
	movq	_FEC_OC_SNC_MODE_ERROR_CTL__M@GOTPCREL(%rip), %rsi
	movq	_FEC_OC_SNC_MODE_CORR_DISABLE__M@GOTPCREL(%rip), %rdi
	movl	(%rdi), %edi
	movl	(%rsi), %esi
	orl	%edi, %esi
	notl	%esi
	andl	-48(%rbp), %esi
	movq	_FEC_OC_EMS_MODE_MODE__M@GOTPCREL(%rip), %rbx
	movl	(%rbx), %ebx
	notl	%ebx
	andl	-44(%rbp), %ebx
	movl	%esi, -48(%rbp)
	movl	%ebx, -44(%rbp)
	cmpq	$0, (%r13)
	je	LBB0_5
## %bb.4:
	orl	%ecx, %eax
	movq	_FEC_OC_SNC_MODE_ERROR_CTL__B@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movl	$2, %edx
	shll	%cl, %edx
	movl	%eax, -52(%rbp)
	orl	%edi, %esi
	orl	%edx, %esi
	movl	%esi, -48(%rbp)
	movq	_FEC_OC_EMS_MODE_MODE__B@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	btsl	%ecx, %ebx
	movl	%ebx, -44(%rbp)
	movl	%eax, %edx
LBB0_5:
	movl	(%r15), %esi
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_write_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.6:
	movl	(%r12), %esi
	movl	-48(%rbp), %edx
	xorl	%r15d, %r15d
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_write_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_8
## %bb.7:
	movq	_FEC_OC_EMS_MODE__A@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-44(%rbp), %edx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_drxj_dap_write_reg16
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_9
LBB0_8:
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	callq	_pr_err
	movl	%ebx, %r15d
LBB0_9:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FEC_OC_DPR_MODE__A,4,2         ## @FEC_OC_DPR_MODE__A
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"error %d\n"

	.comm	_FEC_OC_SNC_MODE__A,4,2         ## @FEC_OC_SNC_MODE__A
	.comm	_FEC_OC_EMS_MODE__A,4,2         ## @FEC_OC_EMS_MODE__A
	.comm	_FEC_OC_DPR_MODE_ERR_DISABLE__M,4,2 ## @FEC_OC_DPR_MODE_ERR_DISABLE__M
	.comm	_FEC_OC_SNC_MODE_ERROR_CTL__M,4,2 ## @FEC_OC_SNC_MODE_ERROR_CTL__M
	.comm	_FEC_OC_SNC_MODE_CORR_DISABLE__M,4,2 ## @FEC_OC_SNC_MODE_CORR_DISABLE__M
	.comm	_FEC_OC_EMS_MODE_MODE__M,4,2    ## @FEC_OC_EMS_MODE_MODE__M
	.comm	_FEC_OC_SNC_MODE_ERROR_CTL__B,4,2 ## @FEC_OC_SNC_MODE_ERROR_CTL__B
	.comm	_FEC_OC_EMS_MODE_MODE__B,4,2    ## @FEC_OC_EMS_MODE_MODE__B
	.no_dead_strip	_set_mpegtei_handling
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_mpegtei_handling
_set_mpegtei_handling:                  ; @set_mpegtei_handling
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	str	xzr, [sp, #8]
	str	wzr, [sp, #4]
	ldp	x24, x19, [x0]
Lloh0:
	adrp	x21, _FEC_OC_DPR_MODE__A@GOTPAGE
Lloh1:
	ldr	x21, [x21, _FEC_OC_DPR_MODE__A@GOTPAGEOFF]
	ldr	w1, [x21]
	add	x2, sp, #12
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_read_reg16
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.1:
Lloh2:
	adrp	x22, _FEC_OC_SNC_MODE__A@GOTPAGE
Lloh3:
	ldr	x22, [x22, _FEC_OC_SNC_MODE__A@GOTPAGEOFF]
	ldr	w1, [x22]
	add	x2, sp, #8
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_read_reg16
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.2:
Lloh4:
	adrp	x23, _FEC_OC_EMS_MODE__A@GOTPAGE
Lloh5:
	ldr	x23, [x23, _FEC_OC_EMS_MODE__A@GOTPAGEOFF]
	ldr	w1, [x23]
	add	x2, sp, #4
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_read_reg16
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.3:
Lloh6:
	adrp	x8, _FEC_OC_DPR_MODE_ERR_DISABLE__M@GOTPAGE
Lloh7:
	ldr	x8, [x8, _FEC_OC_DPR_MODE_ERR_DISABLE__M@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x8]
	ldp	w12, w11, [sp, #8]
	bic	w2, w11, w10
	str	w2, [sp, #12]
Lloh9:
	adrp	x8, _FEC_OC_SNC_MODE_ERROR_CTL__M@GOTPAGE
Lloh10:
	ldr	x8, [x8, _FEC_OC_SNC_MODE_ERROR_CTL__M@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _FEC_OC_SNC_MODE_CORR_DISABLE__M@GOTPAGE
Lloh13:
	ldr	x9, [x9, _FEC_OC_SNC_MODE_CORR_DISABLE__M@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	orr	w8, w9, w8
	bic	w12, w12, w8
Lloh15:
	adrp	x8, _FEC_OC_EMS_MODE_MODE__M@GOTPAGE
Lloh16:
	ldr	x8, [x8, _FEC_OC_EMS_MODE_MODE__M@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	ldr	w13, [sp, #4]
	bic	w8, w13, w8
	stp	w8, w12, [sp, #4]
	ldr	x13, [x24]
	cbz	x13, LBB0_5
; %bb.4:
	orr	w2, w11, w10
	str	w2, [sp, #12]
Lloh18:
	adrp	x10, _FEC_OC_SNC_MODE_ERROR_CTL__B@GOTPAGE
Lloh19:
	ldr	x10, [x10, _FEC_OC_SNC_MODE_ERROR_CTL__B@GOTPAGEOFF]
Lloh20:
	ldr	w10, [x10]
	mov	w11, #2
	lsl	w10, w11, w10
	orr	w9, w12, w9
	orr	w9, w9, w10
Lloh21:
	adrp	x10, _FEC_OC_EMS_MODE_MODE__B@GOTPAGE
Lloh22:
	ldr	x10, [x10, _FEC_OC_EMS_MODE_MODE__B@GOTPAGEOFF]
	str	w9, [sp, #8]
Lloh23:
	ldr	w9, [x10]
	mov	w10, #1
	lsl	w9, w10, w9
	orr	w8, w9, w8
	str	w8, [sp, #4]
LBB0_5:
	ldr	w1, [x21]
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_write_reg16
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.6:
	ldr	w1, [x22]
	ldr	w2, [sp, #8]
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_write_reg16
	mov	x20, x0
	cbnz	w0, LBB0_8
; %bb.7:
	ldr	w1, [x23]
	ldr	w2, [sp, #4]
	mov	x0, x19
	mov	w3, #0
	bl	_drxj_dap_write_reg16
	mov	x20, x0
	cbz	w0, LBB0_9
LBB0_8:
Lloh24:
	adrp	x0, l_.str@PAGE
Lloh25:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x20
	bl	_pr_err
LBB0_9:
	mov	x0, x20
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_FEC_OC_DPR_MODE__A,4,2         ; @FEC_OC_DPR_MODE__A
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"error %d\n"

	.comm	_FEC_OC_SNC_MODE__A,4,2         ; @FEC_OC_SNC_MODE__A
	.comm	_FEC_OC_EMS_MODE__A,4,2         ; @FEC_OC_EMS_MODE__A
	.comm	_FEC_OC_DPR_MODE_ERR_DISABLE__M,4,2 ; @FEC_OC_DPR_MODE_ERR_DISABLE__M
	.comm	_FEC_OC_SNC_MODE_ERROR_CTL__M,4,2 ; @FEC_OC_SNC_MODE_ERROR_CTL__M
	.comm	_FEC_OC_SNC_MODE_CORR_DISABLE__M,4,2 ; @FEC_OC_SNC_MODE_CORR_DISABLE__M
	.comm	_FEC_OC_EMS_MODE_MODE__M,4,2    ; @FEC_OC_EMS_MODE_MODE__M
	.comm	_FEC_OC_SNC_MODE_ERROR_CTL__B,4,2 ; @FEC_OC_SNC_MODE_ERROR_CTL__B
	.comm	_FEC_OC_EMS_MODE_MODE__B,4,2    ; @FEC_OC_EMS_MODE_MODE__B
	.no_dead_strip	_set_mpegtei_handling
.subsections_via_symbols
