	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_proc_init                  ## -- Begin function drm_proc_init
	.p2align	4, 0x90
_drm_proc_init:                         ## @drm_proc_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
	subq	$80, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -40(%rbp)
	addq	$8, %rdi
	callq	_INIT_LIST_HEAD
	leaq	L_.str(%rip), %rsi
	leaq	-112(%rbp), %r12
	movq	%r12, %rdi
	movl	%r15d, %edx
	callq	_sprintf
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_proc_mkdir
	movq	%rax, (%rbx)
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	_drm_proc_list@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	movq	_DRM_PROC_ENTRIES@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%rax, %rdx
	movq	%rbx, %rcx
	callq	_drm_proc_create_files
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	movl	%eax, %r15d
	leaq	-112(%rbp), %rdi
	movq	%r14, %rsi
	callq	_remove_proc_entry
	movq	$0, (%rbx)
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_ERROR
	jmp	LBB0_5
LBB0_1:
	leaq	L_.str.1(%rip), %rdi
	leaq	-112(%rbp), %rsi
	xorl	%eax, %eax
	callq	_DRM_ERROR
	movl	$-1, %r15d
	jmp	LBB0_5
LBB0_3:
	xorl	%r15d, %r15d
LBB0_5:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-40(%rbp), %rax
	jne	LBB0_7
## %bb.6:
	movl	%r15d, %eax
	addq	$80, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%d"

L_.str.1:                               ## @.str.1
	.asciz	"Cannot create /proc/dri/%s\n"

	.comm	_drm_proc_list,4,2              ## @drm_proc_list
	.comm	_DRM_PROC_ENTRIES,4,2           ## @DRM_PROC_ENTRIES
L_.str.2:                               ## @.str.2
	.asciz	"Failed to create core drm proc files\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_drm_proc_init                  ; -- Begin function drm_proc_init
	.p2align	2
_drm_proc_init:                         ; @drm_proc_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x20, x2
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	add	x0, x0, #8
	bl	_INIT_LIST_HEAD
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x22, sp, #8
	add	x0, sp, #8
	mov	x2, x21
	bl	_sprintf
	add	x0, sp, #8
	mov	x1, x20
	bl	_proc_mkdir
	str	x0, [x19]
	cbz	x0, LBB0_3
; %bb.1:
	mov	x2, x0
Lloh5:
	adrp	x8, _drm_proc_list@GOTPAGE
Lloh6:
	ldr	x8, [x8, _drm_proc_list@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x8, _DRM_PROC_ENTRIES@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DRM_PROC_ENTRIES@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x3, x19
	bl	_drm_proc_create_files
	mov	x21, x0
	cbz	w0, LBB0_4
; %bb.2:
	add	x0, sp, #8
	mov	x1, x20
	bl	_remove_proc_entry
	str	xzr, [x19]
Lloh11:
	adrp	x0, l_.str.2@PAGE
Lloh12:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DRM_ERROR
	b	LBB0_4
LBB0_3:
	str	x22, [sp]
Lloh13:
	adrp	x0, l_.str.1@PAGE
Lloh14:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_ERROR
	mov	w21, #-1
LBB0_4:
	ldur	x8, [x29, #-40]
Lloh15:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh16:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_6
; %bb.5:
	mov	x0, x21
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_6:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%d"

l_.str.1:                               ; @.str.1
	.asciz	"Cannot create /proc/dri/%s\n"

	.comm	_drm_proc_list,4,2              ; @drm_proc_list
	.comm	_DRM_PROC_ENTRIES,4,2           ; @DRM_PROC_ENTRIES
l_.str.2:                               ; @.str.2
	.asciz	"Failed to create core drm proc files\n"

.subsections_via_symbols
