	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nv50_sor_create
_nv50_sor_create:                       ## @nv50_sor_create
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	%rdi, %r15
	callq	_nouveau_connector
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movl	(%r15), %edi
	callq	_nouveau_drm
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_nvxx_bios
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_nvxx_i2c
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	(%r12), %ebx
	movq	_DRM_MODE_ENCODER_LVDS@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	_DRM_MODE_ENCODER_TMDS@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$40, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	cmpl	$129, %ebx
	cmovel	%r13d, %r14d
	movq	%r12, 32(%rax)
	movq	_nv50_sor_update@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 24(%rax)
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%rax, %rdi
	callq	_to_drm_encoder
	movq	%rax, %r13
	movl	16(%r12), %eax
	movl	%eax, 16(%r13)
	movq	$0, 8(%r13)
	movl	(%r15), %edi
	movl	8(%r12), %eax
	movl	12(%r12), %r9d
	movl	%eax, (%rsp)
	movq	_nv50_sor_func@GOTPCREL(%rip), %rdx
	leaq	L_.str(%rip), %r8
	movq	%r13, %rsi
	movl	%r14d, %ecx
	callq	_drm_encoder_init
	movq	_nv50_sor_help@GOTPCREL(%rip), %rsi
	movq	%r13, %rdi
	callq	_drm_encoder_helper_add
	movq	%r15, %rdi
	movq	%r13, %rsi
	callq	_drm_connector_attach_encoder
	cmpl	$130, (%r12)
	jne	LBB0_11
## %bb.3:
	movl	(%r13), %edi
	callq	_nv50_disp
	movq	%rax, %r14
	movl	4(%r12), %esi
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	callq	_nvkm_i2c_aux_find
	testq	%rax, %rax
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	je	LBB0_5
## %bb.4:
	movq	(%r14), %rcx
	movq	(%rcx), %rcx
	movq	_GF110_DISP@GOTPCREL(%rip), %rdx
	leaq	12(%rbx), %rsi
	cmpq	(%rdx), %rcx
	cmovlq	%rax, %rsi
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	%rsi, (%rcx)
	movq	%rax, 16(%rcx)
LBB0_5:
	movq	(%rbx), %rax
	movq	_DCB_CONNECTOR_eDP@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_10
## %bb.6:
	leaq	-52(%rbp), %rsi
	leaq	-92(%rbp), %rdx
	leaq	-88(%rbp), %rcx
	leaq	-84(%rbp), %r8
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_nvbios_dp_table
	testq	%rax, %rax
	je	LBB0_10
## %bb.7:
	cmpl	$64, -52(%rbp)
	jl	LBB0_10
## %bb.8:
	addq	$8, %rax
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%rax, %rsi
	callq	_nvbios_rd08
	testb	$4, %al
	je	LBB0_10
## %bb.9:
	movq	%rbx, %rsi
	addq	$12, %rsi
	movl	8(%rbx), %ecx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rdi, %r8
	addq	$8, %r8
	movl	$16, %edx
	callq	_nv50_mstm_new
	testl	%eax, %eax
	jne	LBB0_13
LBB0_10:
	xorl	%eax, %eax
	jmp	LBB0_13
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_13
LBB0_11:
	movl	4(%r12), %esi
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	callq	_nvkm_i2c_bus_find
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	je	LBB0_13
## %bb.12:
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movq	%rcx, (%rdx)
LBB0_13:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DRM_MODE_ENCODER_LVDS,4,2      ## @DRM_MODE_ENCODER_LVDS
	.comm	_DRM_MODE_ENCODER_TMDS,4,2      ## @DRM_MODE_ENCODER_TMDS
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_nv50_sor_update,4,2            ## @nv50_sor_update
	.comm	_nv50_sor_func,4,2              ## @nv50_sor_func
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sor-%04x-%04x"

	.comm	_nv50_sor_help,4,2              ## @nv50_sor_help
	.comm	_GF110_DISP,8,3                 ## @GF110_DISP
	.comm	_DCB_CONNECTOR_eDP,8,3          ## @DCB_CONNECTOR_eDP
	.no_dead_strip	_nv50_sor_create
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nv50_sor_create
_nv50_sor_create:                       ; @nv50_sor_create
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x22, x1
	mov	x24, x0
	bl	_nouveau_connector
	mov	x19, x0
	ldr	w0, [x24]
	bl	_nouveau_drm
	mov	x20, x0
	bl	_nvxx_bios
	mov	x21, x0
	mov	x0, x20
	bl	_nvxx_i2c
	mov	x23, x0
	ldr	w25, [x22]
Lloh0:
	adrp	x8, _DRM_MODE_ENCODER_LVDS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DRM_MODE_ENCODER_LVDS@GOTPAGEOFF]
Lloh2:
	ldr	w26, [x8]
Lloh3:
	adrp	x8, _DRM_MODE_ENCODER_TMDS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DRM_MODE_ENCODER_TMDS@GOTPAGEOFF]
Lloh5:
	ldr	w27, [x8]
Lloh6:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	w0, #40
	bl	_kzalloc
	cbz	x0, LBB0_10
; %bb.1:
	mov	x20, x0
	cmp	w25, #129
	csel	w26, w26, w27, eq
	str	x22, [x0, #32]
Lloh9:
	adrp	x8, _nv50_sor_update@GOTPAGE
Lloh10:
	ldr	x8, [x8, _nv50_sor_update@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	w8, [x0, #24]
	bl	_to_drm_encoder
	mov	x25, x0
	ldr	w8, [x22, #16]
	str	w8, [x0, #16]
	str	xzr, [x0, #8]
	ldr	w0, [x24]
	ldp	w6, w5, [x22, #8]
Lloh12:
	adrp	x2, _nv50_sor_func@GOTPAGE
Lloh13:
	ldr	x2, [x2, _nv50_sor_func@GOTPAGEOFF]
Lloh14:
	adrp	x4, l_.str@PAGE
Lloh15:
	add	x4, x4, l_.str@PAGEOFF
	mov	x1, x25
	mov	x3, x26
	bl	_drm_encoder_init
Lloh16:
	adrp	x1, _nv50_sor_help@GOTPAGE
Lloh17:
	ldr	x1, [x1, _nv50_sor_help@GOTPAGEOFF]
	mov	x0, x25
	bl	_drm_encoder_helper_add
	mov	x0, x24
	mov	x1, x25
	bl	_drm_connector_attach_encoder
	ldr	w8, [x22]
	cmp	w8, #130
	b.ne	LBB0_11
; %bb.2:
	ldr	w0, [x25]
	bl	_nv50_disp
	mov	x24, x0
	ldr	w1, [x22, #4]
	mov	x0, x23
	bl	_nvkm_i2c_aux_find
	cbz	x0, LBB0_4
; %bb.3:
	ldr	x8, [x24]
	ldr	x8, [x8]
Lloh18:
	adrp	x9, _GF110_DISP@GOTPAGE
Lloh19:
	ldr	x9, [x9, _GF110_DISP@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	add	x10, x19, #12
	cmp	x8, x9
	csel	x8, x0, x10, lt
	str	x8, [x20]
	str	x0, [x20, #16]
LBB0_4:
	ldr	x8, [x19]
Lloh21:
	adrp	x9, _DCB_CONNECTOR_eDP@GOTPAGE
Lloh22:
	ldr	x9, [x9, _DCB_CONNECTOR_eDP@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_9
; %bb.5:
	add	x1, sp, #12
	add	x2, sp, #8
	add	x3, sp, #4
	mov	x4, sp
	mov	x0, x21
	bl	_nvbios_dp_table
	cbz	x0, LBB0_9
; %bb.6:
	ldr	w8, [sp, #12]
	cmp	w8, #64
	b.lt	LBB0_9
; %bb.7:
	add	x1, x0, #8
	mov	x0, x21
	bl	_nvbios_rd08
	tbz	w0, #2, LBB0_9
; %bb.8:
	add	x1, x19, #12
	ldr	w3, [x19, #8]
	add	x4, x20, #8
	mov	x0, x20
	mov	w2, #16
	bl	_nv50_mstm_new
	cbnz	w0, LBB0_13
LBB0_9:
	mov	w0, #0
	b	LBB0_13
LBB0_10:
Lloh24:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_13
LBB0_11:
	ldr	w1, [x22, #4]
	mov	x0, x23
	bl	_nvkm_i2c_bus_find
	cbz	x0, LBB0_13
; %bb.12:
	mov	x8, x0
	mov	w0, #0
	str	x8, [x20]
LBB0_13:
	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
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_DRM_MODE_ENCODER_LVDS,4,2      ; @DRM_MODE_ENCODER_LVDS
	.comm	_DRM_MODE_ENCODER_TMDS,4,2      ; @DRM_MODE_ENCODER_TMDS
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_nv50_sor_update,4,2            ; @nv50_sor_update
	.comm	_nv50_sor_func,4,2              ; @nv50_sor_func
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sor-%04x-%04x"

	.comm	_nv50_sor_help,4,2              ; @nv50_sor_help
	.comm	_GF110_DISP,8,3                 ; @GF110_DISP
	.comm	_DCB_CONNECTOR_eDP,8,3          ; @DCB_CONNECTOR_eDP
	.no_dead_strip	_nv50_sor_create
.subsections_via_symbols
