	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function drm_hdcp_parse_hdcp2_srm
_drm_hdcp_parse_hdcp2_srm:              ## @drm_hdcp_parse_hdcp2_srm
	.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
	movq	_DRM_HDCP_2_VRL_LENGTH_SIZE@GOTPCREL(%rip), %r13
	movslq	(%r13), %rax
	movq	_DRM_HDCP_2_DCP_SIG_SIZE@GOTPCREL(%rip), %r14
	movslq	(%r14), %rcx
	addq	%rcx, %rax
	addq	$24, %rax
	cmpq	%rsi, %rax
	jbe	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_7
LBB0_2:
	movq	%rdi, %r12
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	_DRM_HDCP_SRM_ID_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	andl	(%rdi), %r15d
	movl	20(%rdi), %edi
	callq	_be16_to_cpu
	movl	16(%r12), %ecx
	leaq	L_.str.1(%rip), %rdi
	xorl	%ebx, %ebx
	movl	%r15d, %esi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_DRM_DEBUG
	cmpq	$0, 8(%r12)
	je	LBB0_4
## %bb.3:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_4:
	addq	$96, %r12
	movq	%r12, %rdi
	callq	_get_vrl_length
	movslq	%eax, %rcx
	addq	$24, %rcx
	cmpq	-48(%rbp), %rcx                 ## 8-byte Folded Reload
	ja	LBB0_6
## %bb.5:
	movslq	(%r13), %rbx
	movl	(%r14), %ecx
	addl	%ebx, %ecx
	cmpl	%ecx, %eax
	jge	LBB0_11
LBB0_6:
	leaq	L_.str.2(%rip), %rdi
LBB0_7:
	callq	_DRM_ERROR
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_8:
	xorl	%ebx, %ebx
LBB0_9:
	subl	(%rax), %ebx
LBB0_10:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	jne	LBB0_13
## %bb.12:
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_7
LBB0_13:
	movl	(%r12,%rbx,4), %r14d
	movl	4(%r12,%rbx,4), %edi
	shll	$2, %r14d
	callq	_DRM_HDCP_2_KSV_COUNT_2_LSBITS
	movl	%eax, %r15d
	orl	%r14d, %r15d
	je	LBB0_16
## %bb.14:
	movq	_srm_data@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movl	4(%rax), %edi
	callq	_kfree
	movq	_DRM_HDCP_KSV_LEN@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r15d, %edi
	callq	_kcalloc
	movq	(%r14), %rcx
	movl	%eax, 4(%rcx)
	testl	%eax, %eax
	je	LBB0_18
## %bb.15:
	leaq	(%r12,%rbx,4), %rax
	movl	(%r13), %ebx
	imull	%r15d, %ebx
	movq	_DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	leaq	(%rax,%rcx,4), %r12
	leaq	L_.str.6(%rip), %rdi
	movl	%r15d, %esi
	xorl	%eax, %eax
	callq	_DRM_DEBUG
	movq	(%r14), %rax
	movl	4(%rax), %edi
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_memcpy
	movq	(%r14), %rax
	movl	%r15d, (%rax)
	jmp	LBB0_17
LBB0_16:
	leaq	L_.str.4(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_DEBUG
LBB0_17:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, %ebx
	jmp	LBB0_10
LBB0_18:
	leaq	L_.str.5(%rip), %rdi
	callq	_DRM_ERROR
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_DRM_HDCP_2_VRL_LENGTH_SIZE,4,2 ## @DRM_HDCP_2_VRL_LENGTH_SIZE
	.comm	_DRM_HDCP_2_DCP_SIG_SIZE,4,2    ## @DRM_HDCP_2_DCP_SIG_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid blob length\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"SRM ID: 0x%x, SRM Ver: 0x%x, SRM Gen No: 0x%x\n"

	.comm	_DRM_HDCP_SRM_ID_MASK,4,2       ## @DRM_HDCP_SRM_ID_MASK
L_.str.2:                               ## @.str.2
	.asciz	"Invalid blob length or vrl length\n"

L_.str.3:                               ## @.str.3
	.asciz	"No vrl found\n"

L_.str.4:                               ## @.str.4
	.asciz	"Revoked KSV count is 0\n"

	.comm	_srm_data,8,3                   ## @srm_data
	.comm	_DRM_HDCP_KSV_LEN,4,2           ## @DRM_HDCP_KSV_LEN
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
L_.str.5:                               ## @.str.5
	.asciz	"Out of Memory\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ,4,2 ## @DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ
L_.str.6:                               ## @.str.6
	.asciz	"Revoked KSVs: %d\n"

	.no_dead_strip	_drm_hdcp_parse_hdcp2_srm
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function drm_hdcp_parse_hdcp2_srm
_drm_hdcp_parse_hdcp2_srm:              ; @drm_hdcp_parse_hdcp2_srm
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
Lloh0:
	adrp	x21, _DRM_HDCP_2_VRL_LENGTH_SIZE@GOTPAGE
Lloh1:
	ldr	x21, [x21, _DRM_HDCP_2_VRL_LENGTH_SIZE@GOTPAGEOFF]
	ldrsw	x8, [x21]
Lloh2:
	adrp	x22, _DRM_HDCP_2_DCP_SIG_SIZE@GOTPAGE
Lloh3:
	ldr	x22, [x22, _DRM_HDCP_2_DCP_SIG_SIZE@GOTPAGEOFF]
	ldrsw	x9, [x22]
	add	x8, x8, x9
	add	x8, x8, #24
	cmp	x8, x1
	b.ls	LBB0_2
; %bb.1:
Lloh4:
	adrp	x0, l_.str@PAGE
Lloh5:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_6
LBB0_2:
	mov	x19, x1
	mov	x20, x0
	ldr	w8, [x0]
Lloh6:
	adrp	x9, _DRM_HDCP_SRM_ID_MASK@GOTPAGE
Lloh7:
	ldr	x9, [x9, _DRM_HDCP_SRM_ID_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	and	w23, w9, w8
	ldr	w0, [x0, #20]
	bl	_be16_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x20, #16]
	stp	x0, x8, [sp, #8]
	str	x23, [sp]
Lloh9:
	adrp	x0, l_.str.1@PAGE
Lloh10:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_DEBUG
	ldr	x8, [x20, #8]
	cbnz	x8, LBB0_7
; %bb.3:
	add	x20, x20, #96
	mov	x0, x20
	bl	_get_vrl_length
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	add	x8, x8, #24
	cmp	x8, x19
	b.hi	LBB0_5
; %bb.4:
	ldrsw	x8, [x21]
	ldr	w9, [x22]
	add	w9, w9, w8
	cmp	w0, w9
	b.ge	LBB0_10
LBB0_5:
Lloh11:
	adrp	x0, l_.str.2@PAGE
Lloh12:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_6:
	bl	_DRM_ERROR
LBB0_7:
Lloh13:
	adrp	x8, _EINVAL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	neg	w19, w8
LBB0_9:
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_10:
	b.ne	LBB0_12
; %bb.11:
Lloh15:
	adrp	x0, l_.str.3@PAGE
Lloh16:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_6
LBB0_12:
	add	x22, x20, x8, lsl #2
	ldp	w20, w0, [x22]
	bl	_DRM_HDCP_2_KSV_COUNT_2_LSBITS
	orr	w20, w0, w20, lsl #2
	cbz	w20, LBB0_15
; %bb.13:
Lloh17:
	adrp	x23, _srm_data@GOTPAGE
Lloh18:
	ldr	x23, [x23, _srm_data@GOTPAGEOFF]
	ldr	x8, [x23]
	ldr	w0, [x8, #4]
	bl	_kfree
Lloh19:
	adrp	x21, _DRM_HDCP_KSV_LEN@GOTPAGE
Lloh20:
	ldr	x21, [x21, _DRM_HDCP_KSV_LEN@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh21:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_kcalloc
	ldr	x8, [x23]
	str	w0, [x8, #4]
	cbz	w0, LBB0_16
; %bb.14:
	ldr	w8, [x21]
	mul	w21, w8, w20
Lloh24:
	adrp	x8, _DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ@GOTPAGEOFF]
Lloh26:
	ldrsw	x8, [x8]
	add	x22, x22, x8, lsl #2
	str	x20, [sp]
Lloh27:
	adrp	x0, l_.str.6@PAGE
Lloh28:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_DRM_DEBUG
	ldr	x8, [x23]
	ldr	w0, [x8, #4]
	mov	x1, x22
	mov	x2, x21
	bl	_memcpy
	ldr	x8, [x23]
	str	w20, [x8]
	b	LBB0_9
LBB0_15:
Lloh29:
	adrp	x0, l_.str.4@PAGE
Lloh30:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_DRM_DEBUG
	b	LBB0_9
LBB0_16:
Lloh31:
	adrp	x0, l_.str.5@PAGE
Lloh32:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_DRM_ERROR
Lloh33:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh34:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_8
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpAdd	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_DRM_HDCP_2_VRL_LENGTH_SIZE,4,2 ; @DRM_HDCP_2_VRL_LENGTH_SIZE
	.comm	_DRM_HDCP_2_DCP_SIG_SIZE,4,2    ; @DRM_HDCP_2_DCP_SIG_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid blob length\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"SRM ID: 0x%x, SRM Ver: 0x%x, SRM Gen No: 0x%x\n"

	.comm	_DRM_HDCP_SRM_ID_MASK,4,2       ; @DRM_HDCP_SRM_ID_MASK
l_.str.2:                               ; @.str.2
	.asciz	"Invalid blob length or vrl length\n"

l_.str.3:                               ; @.str.3
	.asciz	"No vrl found\n"

l_.str.4:                               ; @.str.4
	.asciz	"Revoked KSV count is 0\n"

	.comm	_srm_data,8,3                   ; @srm_data
	.comm	_DRM_HDCP_KSV_LEN,4,2           ; @DRM_HDCP_KSV_LEN
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
l_.str.5:                               ; @.str.5
	.asciz	"Out of Memory\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ,4,2 ; @DRM_HDCP_2_NO_OF_DEV_PLUS_RESERVED_SZ
l_.str.6:                               ; @.str.6
	.asciz	"Revoked KSVs: %d\n"

	.no_dead_strip	_drm_hdcp_parse_hdcp2_srm
.subsections_via_symbols
