	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_jack_kctl
_add_jack_kctl:                         ## @add_jack_kctl
	.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	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	xorl	%ebx, %ebx
	testl	%esi, %esi
	je	LBB0_12
## %bb.1:
	movq	%rcx, %r13
	movq	%rdx, %r12
	movl	%esi, %r15d
	movq	%rdi, %r14
	callq	_snd_hda_codec_get_pincfg
	movl	%eax, %edi
	callq	_get_defcfg_connect
	movq	_AC_JACK_PORT_NONE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	je	LBB0_12
## %bb.2:
	movq	_AC_JACK_PORT_COMPLEX@GOTPCREL(%rip), %rcx
	movb	$1, %dl
	cmpl	(%rcx), %eax
	jne	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_is_jack_detectable
	testl	%eax, %eax
	sete	%dl
LBB0_4:
	movb	%dl, -97(%rbp)                  ## 1-byte Spill
	movzbl	%dl, %ebx
	testq	%r13, %r13
	je	LBB0_6
## %bb.5:
	leaq	-96(%rbp), %rdi
	movq	%r13, %rsi
	movl	$44, %edx
	callq	_strlcpy
	movl	$0, -104(%rbp)
	jmp	LBB0_7
LBB0_6:
	leaq	-96(%rbp), %rcx
	leaq	-104(%rbp), %r9
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%r12, %rdx
	movl	$44, %r8d
	callq	_snd_hda_get_pin_label
LBB0_7:
	movl	%ebx, %r13d
	testl	%ebx, %ebx
	je	LBB0_9
## %bb.8:
	leaq	-96(%rbp), %r12
	movq	%r12, %rdi
	callq	_strlen
	movl	$43, %edx
	subl	%eax, %edx
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	callq	_strncat
LBB0_9:
	movl	-104(%rbp), %edx
	leaq	-96(%rbp), %rbx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_get_unique_index
	movl	%eax, -104(%rbp)
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	%rbx, %rdx
	movl	%eax, %ecx
	movl	%r13d, %r8d
	callq	___snd_hda_jack_add_kctl
	xorl	%ebx, %ebx
	testl	%eax, %eax
	cmovsl	%eax, %ebx
	js	LBB0_12
## %bb.10:
	cmpb	$0, -97(%rbp)                   ## 1-byte Folded Reload
	jne	LBB0_12
## %bb.11:
	movq	%r14, %rdi
	movl	%r15d, %esi
	xorl	%edx, %edx
	callq	_snd_hda_jack_detect_enable
	movl	%eax, %ebx
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AC_JACK_PORT_NONE,4,2          ## @AC_JACK_PORT_NONE
	.comm	_AC_JACK_PORT_COMPLEX,4,2       ## @AC_JACK_PORT_COMPLEX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	" Phantom"

	.no_dead_strip	_add_jack_kctl
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_jack_kctl
_add_jack_kctl:                         ; @add_jack_kctl
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #56]
	cbz	w1, LBB0_2
; %bb.1:
	mov	x23, x3
	mov	x22, x2
	mov	x19, x1
	mov	x20, x0
	bl	_snd_hda_codec_get_pincfg
	bl	_get_defcfg_connect
Lloh3:
	adrp	x8, _AC_JACK_PORT_NONE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AC_JACK_PORT_NONE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_5
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldr	x8, [sp, #56]
Lloh6:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh7:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.4:
	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
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_5:
Lloh9:
	adrp	x8, _AC_JACK_PORT_COMPLEX@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AC_JACK_PORT_COMPLEX@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_12
; %bb.6:
	mov	x0, x20
	mov	x1, x19
	bl	_is_jack_detectable
	cmp	w0, #0
	cset	w21, eq
	cbz	x23, LBB0_13
LBB0_7:
	add	x0, sp, #12
	mov	x1, x23
	mov	w2, #44
	bl	_strlcpy
	str	wzr, [sp, #8]
	cbz	w21, LBB0_9
LBB0_8:
	add	x0, sp, #12
	bl	_strlen
	mov	w8, #43
	sub	w2, w8, w0
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	add	x0, sp, #12
	bl	_strncat
LBB0_9:
	ldr	w2, [sp, #8]
	add	x1, sp, #12
	mov	x0, x20
	bl	_get_unique_index
	mov	x3, x0
	str	w0, [sp, #8]
	add	x2, sp, #12
	mov	x0, x20
	mov	x1, x19
	mov	x4, x21
	bl	___snd_hda_jack_add_kctl
	mov	x8, x0
	cmp	w0, #0
	csel	w0, w0, wzr, lt
	tbnz	w8, #31, LBB0_3
; %bb.10:
	tbnz	w21, #0, LBB0_3
; %bb.11:
	mov	x0, x20
	mov	x1, x19
	mov	w2, #0
	bl	_snd_hda_jack_detect_enable
	b	LBB0_3
LBB0_12:
	mov	w21, #1
	cbnz	x23, LBB0_7
LBB0_13:
	add	x3, sp, #12
	add	x5, sp, #8
	mov	x0, x20
	mov	x1, x19
	mov	x2, x22
	mov	w4, #44
	bl	_snd_hda_get_pin_label
	cbnz	w21, LBB0_8
	b	LBB0_9
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_AC_JACK_PORT_NONE,4,2          ; @AC_JACK_PORT_NONE
	.comm	_AC_JACK_PORT_COMPLEX,4,2       ; @AC_JACK_PORT_COMPLEX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	" Phantom"

	.no_dead_strip	_add_jack_kctl
.subsections_via_symbols
