	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_adreno_load_gpu                ## -- Begin function adreno_load_gpu
	.p2align	4, 0x90
_adreno_load_gpu:                       ## @adreno_load_gpu
	.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	%rdi, %r14
	movq	16(%rdi), %rax
	movq	(%rax), %r15
	testq	%r15, %r15
	je	LBB0_2
## %bb.1:
	movq	%r15, %rdi
	callq	_platform_get_drvdata
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_to_adreno_gpu
	movq	%rax, %rdi
	callq	_adreno_load_fw
	testl	%eax, %eax
	jne	LBB0_9
## %bb.4:
	movq	%r15, %rdi
	callq	_pm_runtime_set_active
	movq	%r15, %rdi
	callq	_pm_runtime_get_sync
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	leaq	12(%r14), %r13
	movq	%r13, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	callq	_msm_gpu_hw_init
	movl	%eax, %r12d
	movq	%r13, %rdi
	callq	_mutex_unlock
	movq	%r15, %rdi
	callq	_pm_runtime_put_autosuspend
	testl	%r12d, %r12d
	je	LBB0_10
## %bb.7:
	movl	8(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_8
LBB0_2:
	movl	8(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err_once
LBB0_9:
	xorl	%ebx, %ebx
LBB0_10:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movl	%eax, %r12d
	movq	%r15, %rdi
	callq	_pm_runtime_put_sync
	movl	8(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
LBB0_8:
	movl	%r12d, %edx
	callq	_DRM_DEV_ERROR
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no GPU device was found\n"

L_.str.1:                               ## @.str.1
	.asciz	"Couldn't power up the GPU: %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"gpu hw init failed: %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_adreno_load_gpu                ; -- Begin function adreno_load_gpu
	.p2align	2
_adreno_load_gpu:                       ; @adreno_load_gpu
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldr	x8, [x0, #16]
	ldr	x21, [x8]
	cbz	x21, LBB0_6
; %bb.1:
	mov	x0, x21
	bl	_platform_get_drvdata
	cbz	x0, LBB0_6
; %bb.2:
	mov	x20, x0
	bl	_to_adreno_gpu
	bl	_adreno_load_fw
	cbnz	w0, LBB0_7
; %bb.3:
	mov	x0, x21
	bl	_pm_runtime_set_active
	mov	x0, x21
	bl	_pm_runtime_get_sync
	tbnz	w0, #31, LBB0_9
; %bb.4:
	add	x23, x19, #12
	mov	x0, x23
	bl	_mutex_lock
	mov	x0, x20
	bl	_msm_gpu_hw_init
	mov	x22, x0
	mov	x0, x23
	bl	_mutex_unlock
	mov	x0, x21
	bl	_pm_runtime_put_autosuspend
	cbz	w22, LBB0_8
; %bb.5:
	ldr	w0, [x19, #8]
Lloh0:
	adrp	x1, l_.str.2@PAGE
Lloh1:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_10
LBB0_6:
	ldr	w0, [x19, #8]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err_once
LBB0_7:
	mov	x20, #0
LBB0_8:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_9:
	mov	x22, x0
	mov	x0, x21
	bl	_pm_runtime_put_sync
	ldr	w0, [x19, #8]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_10:
	mov	x2, x22
	bl	_DRM_DEV_ERROR
	b	LBB0_7
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no GPU device was found\n"

l_.str.1:                               ; @.str.1
	.asciz	"Couldn't power up the GPU: %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"gpu hw init failed: %d\n"

.subsections_via_symbols
