	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hdcp2_authenticate_repeater_topology
_hdcp2_authenticate_repeater_topology:  ## @hdcp2_authenticate_repeater_topology
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_conn_to_dig_port
	movq	%rax, %r14
	movq	(%rbx), %r15
	movq	16(%rbx), %r12
	movq	_HDCP_2_2_REP_SEND_RECVID_LIST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-80(%rbp), %rdx
	movq	%r14, %rdi
	movl	$24, %ecx
	callq	*(%r12)
	testl	%eax, %eax
	js	LBB0_12
## %bb.1:
	movq	-64(%rbp), %r13
	movl	4(%r13), %edi
	callq	_HDCP_2_2_MAX_CASCADE_EXCEEDED
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	movl	4(%r13), %edi
	callq	_HDCP_2_2_MAX_DEVS_EXCEEDED
	testq	%rax, %rax
	je	LBB0_6
LBB0_3:
	leaq	L_.str(%rip), %rdi
LBB0_4:
	callq	_DRM_DEBUG_KMS
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_5:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_12:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	-72(%rbp), %rdi
	callq	_drm_hdcp_be24_to_cpu
	cmpq	8(%rbx), %rax
	jge	LBB0_8
## %bb.7:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_4
LBB0_8:
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	(%r13), %edi
	callq	_HDCP_2_2_DEV_COUNT_HI
	shll	$4, %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	4(%r13), %edi
	callq	_HDCP_2_2_DEV_COUNT_LO
	orl	-44(%rbp), %eax                 ## 4-byte Folded Reload
	movslq	%eax, %rdx
	movl	-80(%rbp), %esi
	movq	%r15, %rdi
	callq	_drm_hdcp_check_ksvs_revoked
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	leaq	L_.str.2(%rip), %rdi
	callq	_DRM_ERROR
	movq	_EPERM@GOTPCREL(%rip), %rcx
	jmp	LBB0_5
LBB0_10:
	leaq	-80(%rbp), %rdx
	movq	%rbx, %rdi
	movq	%rdx, %rsi
	callq	_hdcp2_verify_rep_topology_prepare_ack
	testl	%eax, %eax
	js	LBB0_12
## %bb.11:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, 8(%rbx)
	leaq	-80(%rbp), %rsi
	movq	%r14, %rdi
	movl	$4, %edx
	callq	*8(%r12)
	movl	%eax, %ecx
	sarl	$31, %eax
	andl	%ecx, %eax
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_HDCP_2_2_REP_SEND_RECVID_LIST,4,2 ## @HDCP_2_2_REP_SEND_RECVID_LIST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Topology Max Size Exceeded\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"Seq_num_v roll over.\n"

L_.str.2:                               ## @.str.2
	.asciz	"Revoked receiver ID(s) is in list\n"

	.comm	_EPERM,4,2                      ## @EPERM
	.no_dead_strip	_hdcp2_authenticate_repeater_topology
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hdcp2_authenticate_repeater_topology
_hdcp2_authenticate_repeater_topology:  ; @hdcp2_authenticate_repeater_topology
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x0
	bl	_conn_to_dig_port
	mov	x19, x0
	ldr	x21, [x20]
	ldr	x24, [x20, #16]
	ldr	x8, [x24]
Lloh0:
	adrp	x9, _HDCP_2_2_REP_SEND_RECVID_LIST@GOTPAGE
Lloh1:
	ldr	x9, [x9, _HDCP_2_2_REP_SEND_RECVID_LIST@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x9]
	add	x2, sp, #8
	mov	w3, #24
	blr	x8
	tbnz	w0, #31, LBB0_6
; %bb.1:
	ldr	x25, [sp, #24]
	ldr	w0, [x25, #4]
	bl	_HDCP_2_2_MAX_CASCADE_EXCEEDED
	cbnz	x0, LBB0_3
; %bb.2:
	ldr	w0, [x25, #4]
	bl	_HDCP_2_2_MAX_DEVS_EXCEEDED
	cbz	x0, LBB0_7
LBB0_3:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
LBB0_4:
	bl	_DRM_DEBUG_KMS
Lloh5:
	adrp	x8, _EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_7:
	ldr	x0, [sp, #16]
	bl	_drm_hdcp_be24_to_cpu
	ldr	x8, [x20, #8]
	cmp	x0, x8
	b.ge	LBB0_9
; %bb.8:
Lloh7:
	adrp	x0, l_.str.1@PAGE
Lloh8:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_4
LBB0_9:
	mov	x22, x0
	ldr	w0, [x25]
	bl	_HDCP_2_2_DEV_COUNT_HI
	mov	x23, x0
	ldr	w0, [x25, #4]
	bl	_HDCP_2_2_DEV_COUNT_LO
	orr	w8, w0, w23, lsl #4
	sxtw	x2, w8
	ldr	w1, [sp, #8]
	mov	x0, x21
	bl	_drm_hdcp_check_ksvs_revoked
	cbz	x0, LBB0_11
; %bb.10:
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DRM_ERROR
Lloh11:
	adrp	x8, _EPERM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EPERM@GOTPAGEOFF]
	b	LBB0_5
LBB0_11:
	add	x1, sp, #8
	add	x2, sp, #8
	mov	x0, x20
	bl	_hdcp2_verify_rep_topology_prepare_ack
	tbnz	w0, #31, LBB0_6
; %bb.12:
	str	x22, [x20, #8]
	ldr	x8, [x24, #8]
	add	x1, sp, #8
	mov	x0, x19
	mov	w2, #4
	blr	x8
	cmp	w0, #0
	csel	w0, w0, wzr, lt
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_HDCP_2_2_REP_SEND_RECVID_LIST,4,2 ; @HDCP_2_2_REP_SEND_RECVID_LIST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Topology Max Size Exceeded\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"Seq_num_v roll over.\n"

l_.str.2:                               ; @.str.2
	.asciz	"Revoked receiver ID(s) is in list\n"

	.comm	_EPERM,4,2                      ; @EPERM
	.no_dead_strip	_hdcp2_authenticate_repeater_topology
.subsections_via_symbols
