	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_avc_tuner_status               ## -- Begin function avc_tuner_status
	.p2align	4, 0x90
_avc_tuner_status:                      ## @avc_tuner_status
	.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	%rsi, %r15
	movq	%rdi, %r13
	movq	16(%rdi), %rbx
	leaq	8(%rdi), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	_AVC_CTYPE_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	movq	_AVC_SUBUNIT_TYPE_TUNER@GOTPCREL(%rip), %rax
	movl	(%r13), %ecx
	orl	(%rax), %ecx
	movl	%ecx, (%rbx)
	movq	_AVC_OPCODE_READ_DESCRIPTOR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%rbx)
	movq	_DESCRIPTOR_TUNER_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	8(%rbx), %rcx
	movl	%eax, (%rcx)
	movl	$255, 4(%rcx)
	movq	%rbx, %rdi
	movl	$2, %esi
	movl	$31, %edx
	callq	_clear_operands
	movl	$12, 4(%r13)
	movq	%r13, %rdi
	callq	_avc_write
	movl	%eax, %r12d
	testl	%eax, %eax
	js	LBB0_9
## %bb.1:
	movq	(%rbx), %rax
	movq	_AVC_RESPONSE_STABLE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
## %bb.2:
	movq	_AVC_RESPONSE_ACCEPTED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
## %bb.3:
	movl	12(%r13), %edi
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_4
LBB0_5:
	movq	8(%rbx), %rax
	cmpl	$16, 4(%rax)
	jne	LBB0_7
## %bb.6:
	movl	36(%rax), %ecx
	movq	_SIZEOF_ANTENNA_INPUT_INFO@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	jne	LBB0_7
## %bb.8:
	movl	40(%rax), %ecx
	movl	%ecx, (%r15)
	movl	44(%rax), %ecx
	shrl	$7, %ecx
	andl	$1, %ecx
	movl	%ecx, 4(%r15)
	movl	44(%rax), %ecx
	shrl	$6, %ecx
	andl	$1, %ecx
	movl	%ecx, 8(%r15)
	movl	44(%rax), %ecx
	shrl	$5, %ecx
	andl	$1, %ecx
	movl	%ecx, 12(%r15)
	movl	48(%rax), %ecx
	shrl	$7, %ecx
	andl	$1, %ecx
	movl	%ecx, 16(%r15)
	movl	48(%rax), %ecx
	andl	$127, %ecx
	movl	%ecx, 20(%r15)
	movl	52(%rax), %ecx
	movl	56(%rax), %edx
	shll	$24, %ecx
	shll	$16, %edx
	orl	%ecx, %edx
	movl	60(%rax), %ecx
	shll	$8, %ecx
	orl	%edx, %ecx
	orl	64(%rax), %ecx
	movl	%ecx, 24(%r15)
	movl	68(%rax), %ecx
	movl	%ecx, 28(%r15)
	movl	72(%rax), %ecx
	shrl	$6, %ecx
	andl	$2, %ecx
	movl	%ecx, 32(%r15)
	movl	72(%rax), %ecx
	movl	76(%rax), %edx
	andl	$63, %ecx
	shll	$16, %ecx
	shll	$8, %edx
	orl	%ecx, %edx
	orl	80(%rax), %edx
	movl	%edx, 36(%r15)
	movl	84(%rax), %ecx
	movl	%ecx, 40(%r15)
	movl	88(%rax), %ecx
	shrl	$4, %ecx
	andl	$1, %ecx
	movl	%ecx, 44(%r15)
	movl	88(%rax), %ecx
	shrl	$3, %ecx
	andl	$1, %ecx
	movl	%ecx, 48(%r15)
	movl	88(%rax), %ecx
	shrl	%ecx
	andl	$1, %ecx
	movl	%ecx, 52(%r15)
	movl	88(%rax), %ecx
	andl	$1, %ecx
	movl	%ecx, 56(%r15)
	movl	92(%rax), %ecx
	shll	$8, %ecx
	orl	96(%rax), %ecx
	movl	%ecx, 60(%r15)
	movl	108(%rax), %ecx
	movl	%ecx, 64(%r15)
	movl	112(%rax), %ecx
	movl	%ecx, 68(%r15)
	movl	116(%rax), %ecx
	movl	%ecx, 72(%r15)
	movl	120(%rax), %ecx
	andl	$1, %ecx
	movl	%ecx, 76(%r15)
	movl	124(%rax), %ecx
	shrl	$7, %ecx
	andl	$1, %ecx
	movl	%ecx, 80(%r15)
	movl	124(%rax), %ecx
	shrl	$6, %ecx
	andl	$1, %ecx
	movl	%ecx, 84(%r15)
	movl	124(%rax), %ecx
	shrl	$5, %ecx
	andl	$1, %ecx
	movl	%ecx, 88(%r15)
	movl	124(%rax), %ecx
	shrl	$4, %ecx
	andl	$1, %ecx
	movl	%ecx, 92(%r15)
	movl	124(%rax), %ecx
	shrl	$3, %ecx
	andl	$1, %ecx
	movl	%ecx, 96(%r15)
	movl	124(%rax), %ecx
	shrl	$2, %ecx
	andl	$1, %ecx
	movl	%ecx, 100(%r15)
	movl	124(%rax), %eax
	shrl	%eax
	andl	$1, %eax
	movl	%eax, 104(%r15)
	jmp	LBB0_9
LBB0_7:
	movl	12(%r13), %edi
	leaq	L_.str.1(%rip), %rsi
LBB0_4:
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
LBB0_9:
	movq	%r14, %rdi
	callq	_mutex_unlock
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AVC_CTYPE_CONTROL,4,2          ## @AVC_CTYPE_CONTROL
	.comm	_AVC_SUBUNIT_TYPE_TUNER,4,2     ## @AVC_SUBUNIT_TYPE_TUNER
	.comm	_AVC_OPCODE_READ_DESCRIPTOR,4,2 ## @AVC_OPCODE_READ_DESCRIPTOR
	.comm	_DESCRIPTOR_TUNER_STATUS,4,2    ## @DESCRIPTOR_TUNER_STATUS
	.comm	_AVC_RESPONSE_STABLE,8,3        ## @AVC_RESPONSE_STABLE
	.comm	_AVC_RESPONSE_ACCEPTED,8,3      ## @AVC_RESPONSE_ACCEPTED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cannot read tuner status\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SIZEOF_ANTENNA_INPUT_INFO,4,2  ## @SIZEOF_ANTENNA_INPUT_INFO
L_.str.1:                               ## @.str.1
	.asciz	"got invalid tuner status\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_avc_tuner_status               ; -- Begin function avc_tuner_status
	.p2align	2
_avc_tuner_status:                      ; @avc_tuner_status
	.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	x20, x1
	mov	x22, x0
	ldr	x23, [x0, #16]
	add	x19, x0, #8
	mov	x0, x19
	bl	_mutex_lock
Lloh0:
	adrp	x8, _AVC_CTYPE_CONTROL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVC_CTYPE_CONTROL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _AVC_SUBUNIT_TYPE_TUNER@GOTPAGE
Lloh4:
	ldr	x9, [x9, _AVC_SUBUNIT_TYPE_TUNER@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	ldr	w10, [x22]
	orr	w9, w10, w9
	str	w9, [x23]
Lloh6:
	adrp	x9, _AVC_OPCODE_READ_DESCRIPTOR@GOTPAGE
Lloh7:
	ldr	x9, [x9, _AVC_OPCODE_READ_DESCRIPTOR@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
Lloh9:
	adrp	x10, _DESCRIPTOR_TUNER_STATUS@GOTPAGE
Lloh10:
	ldr	x10, [x10, _DESCRIPTOR_TUNER_STATUS@GOTPAGEOFF]
	stp	w9, w8, [x23, #16]
Lloh11:
	ldr	w8, [x10]
	ldr	x9, [x23, #8]
	mov	w10, #255
	stp	w8, w10, [x9]
	mov	x0, x23
	mov	w1, #2
	mov	w2, #31
	bl	_clear_operands
	mov	w8, #12
	str	w8, [x22, #4]
	mov	x0, x22
	bl	_avc_write
	mov	x21, x0
	tbnz	w0, #31, LBB0_9
; %bb.1:
	ldr	x8, [x23]
Lloh12:
	adrp	x9, _AVC_RESPONSE_STABLE@GOTPAGE
Lloh13:
	ldr	x9, [x9, _AVC_RESPONSE_STABLE@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_4
; %bb.2:
Lloh15:
	adrp	x9, _AVC_RESPONSE_ACCEPTED@GOTPAGE
Lloh16:
	ldr	x9, [x9, _AVC_RESPONSE_ACCEPTED@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_4
; %bb.3:
	ldr	w0, [x22, #12]
Lloh18:
	adrp	x1, l_.str@PAGE
Lloh19:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_8
LBB0_4:
	ldr	x8, [x23, #8]
	ldr	w9, [x8, #4]
	cmp	w9, #16
	b.ne	LBB0_7
; %bb.5:
	ldr	w9, [x8, #36]
Lloh20:
	adrp	x10, _SIZEOF_ANTENNA_INPUT_INFO@GOTPAGE
Lloh21:
	ldr	x10, [x10, _SIZEOF_ANTENNA_INPUT_INFO@GOTPAGEOFF]
Lloh22:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ne	LBB0_7
; %bb.6:
	ldr	w9, [x8, #40]
	str	w9, [x20]
	ldr	w9, [x8, #44]
	ubfx	w9, w9, #7, #1
	str	w9, [x20, #4]
	ldr	w9, [x8, #44]
	ubfx	w9, w9, #6, #1
	str	w9, [x20, #8]
	ldr	w9, [x8, #44]
	ubfx	w9, w9, #5, #1
	str	w9, [x20, #12]
	ldr	w9, [x8, #48]
	ubfx	w9, w9, #7, #1
	str	w9, [x20, #16]
	ldr	w9, [x8, #48]
	and	w9, w9, #0x7f
	str	w9, [x20, #20]
	ldp	w9, w10, [x8, #52]
	lsl	w10, w10, #16
	orr	w9, w10, w9, lsl #24
	ldp	w10, w11, [x8, #60]
	orr	w9, w9, w10, lsl #8
	orr	w9, w9, w11
	str	w9, [x20, #24]
	ldr	w9, [x8, #68]
	str	w9, [x20, #28]
	ldr	w9, [x8, #72]
	lsr	w9, w9, #6
	and	w9, w9, #0x2
	str	w9, [x20, #32]
	ldp	w9, w10, [x8, #72]
	ubfiz	w9, w9, #16, #6
	orr	w9, w9, w10, lsl #8
	ldr	w10, [x8, #80]
	orr	w9, w9, w10
	str	w9, [x20, #36]
	ldr	w9, [x8, #84]
	str	w9, [x20, #40]
	ldr	w9, [x8, #88]
	ubfx	w9, w9, #4, #1
	str	w9, [x20, #44]
	ldr	w9, [x8, #88]
	ubfx	w9, w9, #3, #1
	str	w9, [x20, #48]
	ldr	w9, [x8, #88]
	ubfx	w9, w9, #1, #1
	str	w9, [x20, #52]
	ldr	w9, [x8, #88]
	and	w9, w9, #0x1
	str	w9, [x20, #56]
	ldp	w9, w10, [x8, #92]
	orr	w9, w10, w9, lsl #8
	str	w9, [x20, #60]
	ldr	w9, [x8, #108]
	str	w9, [x20, #64]
	ldr	w9, [x8, #112]
	str	w9, [x20, #68]
	ldr	w9, [x8, #116]
	str	w9, [x20, #72]
	ldr	w9, [x8, #120]
	and	w9, w9, #0x1
	str	w9, [x20, #76]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #7, #1
	str	w9, [x20, #80]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #6, #1
	str	w9, [x20, #84]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #5, #1
	str	w9, [x20, #88]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #4, #1
	str	w9, [x20, #92]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #3, #1
	str	w9, [x20, #96]
	ldr	w9, [x8, #124]
	ubfx	w9, w9, #2, #1
	str	w9, [x20, #100]
	ldr	w8, [x8, #124]
	ubfx	w8, w8, #1, #1
	str	w8, [x20, #104]
	b	LBB0_9
LBB0_7:
	ldr	w0, [x22, #12]
Lloh23:
	adrp	x1, l_.str.1@PAGE
Lloh24:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_8:
	bl	_dev_err
Lloh25:
	adrp	x8, _EINVAL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_9:
	mov	x0, x19
	bl	_mutex_unlock
	mov	x0, x21
	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
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_AVC_CTYPE_CONTROL,4,2          ; @AVC_CTYPE_CONTROL
	.comm	_AVC_SUBUNIT_TYPE_TUNER,4,2     ; @AVC_SUBUNIT_TYPE_TUNER
	.comm	_AVC_OPCODE_READ_DESCRIPTOR,4,2 ; @AVC_OPCODE_READ_DESCRIPTOR
	.comm	_DESCRIPTOR_TUNER_STATUS,4,2    ; @DESCRIPTOR_TUNER_STATUS
	.comm	_AVC_RESPONSE_STABLE,8,3        ; @AVC_RESPONSE_STABLE
	.comm	_AVC_RESPONSE_ACCEPTED,8,3      ; @AVC_RESPONSE_ACCEPTED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cannot read tuner status\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SIZEOF_ANTENNA_INPUT_INFO,4,2  ; @SIZEOF_ANTENNA_INPUT_INFO
l_.str.1:                               ; @.str.1
	.asciz	"got invalid tuner status\n"

.subsections_via_symbols
