	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cdn_dp_firmware_init
_cdn_dp_firmware_init:                  ## @cdn_dp_firmware_init
	.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
	movq	%rdi, %r14
	movq	8(%rdi), %rbx
	movq	(%rbx), %r12
	movq	8(%rbx), %r15
	movl	24(%r15), %edi
	callq	_le32_to_cpu
	cmpq	%rax, %r12
	jne	LBB0_1
## %bb.2:
	movq	16(%r15), %rsi
	addq	8(%rbx), %rsi
	movq	8(%r15), %rdx
	leaq	(%rsi,%rdx), %rcx
	movl	(%r15), %r8d
	movq	%r14, %rdi
	callq	_cdn_dp_load_firmware
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_cdn_dp_set_firmware_active
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	movl	%eax, %ebx
	movl	(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_DRM_DEV_ERROR
	jmp	LBB0_5
LBB0_1:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_DRM_DEV_ERROR
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_5:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_cdn_dp_event_config            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"firmware is invalid\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"active ucpu failed: %d\n"

	.no_dead_strip	_cdn_dp_firmware_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cdn_dp_firmware_init
_cdn_dp_firmware_init:                  ; @cdn_dp_firmware_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x21, [x0, #8]
	ldp	x22, x20, [x21]
	ldr	w0, [x20, #24]
	bl	_le32_to_cpu
	cmp	x22, x0
	b.ne	LBB0_4
; %bb.1:
	ldr	x8, [x21, #8]
	ldp	x2, x9, [x20, #8]
	add	x1, x9, x8
	add	x3, x1, x2
	ldr	w4, [x20]
	mov	x0, x19
	bl	_cdn_dp_load_firmware
	mov	x20, x0
	cbnz	w0, LBB0_5
; %bb.2:
	mov	x0, x19
	mov	w1, #1
	bl	_cdn_dp_set_firmware_active
	cbz	w0, LBB0_6
; %bb.3:
	mov	x20, x0
	ldr	w0, [x19]
	str	x20, [sp]
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_DRM_DEV_ERROR
	b	LBB0_5
LBB0_4:
	ldr	w0, [x19]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_DRM_DEV_ERROR
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_5:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
LBB0_6:
	mov	x0, x19
	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
	add	sp, sp, #64
	b	_cdn_dp_event_config
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"firmware is invalid\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"active ucpu failed: %d\n"

	.no_dead_strip	_cdn_dp_firmware_init
.subsections_via_symbols
