	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_via8233_pcmdxs_volume_put
_snd_via8233_pcmdxs_volume_put:         ## @snd_via8233_pcmdxs_volume_put
	.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, %r14
	callq	_snd_kcontrol_chip
	movq	(%r14), %rsi
	movq	_VIA_DXS_MAX_VOLUME@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	xorl	%edi, %edi
	movl	%ecx, %edx
	subb	(%rsi), %dl
	movzbl	%dl, %ebx
	cmovbl	%edi, %ebx
	movq	%rax, %r12
	movq	(%rax), %rdx
	cmpb	(%rdx), %bl
	jne	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	jmp	LBB0_3
LBB0_2:
	movb	%bl, (%rdx)
	movl	8(%r12), %esi
	movq	16(%r12), %rax
	movq	(%rax), %rax
	movb	%bl, (%rax)
	movq	_VIA_REG_OFS_PLAYBACK_VOLUME_L@GOTPCREL(%rip), %r13
	addq	(%r13), %rsi
	movzbl	%bl, %r15d
	movl	%r15d, %edi
	callq	_outb
	movl	8(%r12), %esi
	addl	$16, %esi
	movq	16(%r12), %rax
	movq	8(%rax), %rax
	movb	%bl, (%rax)
	addq	(%r13), %rsi
	movl	%r15d, %edi
	callq	_outb
	movl	8(%r12), %esi
	addl	$32, %esi
	movq	16(%r12), %rax
	movq	16(%rax), %rax
	movb	%bl, (%rax)
	addq	(%r13), %rsi
	movl	%r15d, %edi
	callq	_outb
	movl	8(%r12), %esi
	addl	$48, %esi
	movq	16(%r12), %rax
	movq	24(%rax), %rax
	movb	%bl, (%rax)
	addq	(%r13), %rsi
	movl	%r15d, %edi
	callq	_outb
	xorl	%edi, %edi
	movq	(%r14), %rsi
	movq	_VIA_DXS_MAX_VOLUME@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movq	(%r12), %rdx
	movl	$1, %eax
LBB0_3:
	subb	1(%rsi), %cl
	movzbl	%cl, %ebx
	cmovbl	%edi, %ebx
	cmpb	1(%rdx), %bl
	je	LBB0_5
## %bb.4:
	movb	%bl, 1(%rdx)
	movl	8(%r12), %eax
	movq	16(%r12), %rcx
	movq	(%rcx), %rcx
	movb	%bl, 1(%rcx)
	movq	_VIA_REG_OFS_PLAYBACK_VOLUME_L@GOTPCREL(%rip), %r15
	movq	(%r15), %rcx
	leaq	(%rax,%rcx), %rsi
	incq	%rsi
	movzbl	%bl, %r14d
	movl	%r14d, %edi
	callq	_outb
	movl	8(%r12), %eax
	addl	$16, %eax
	movq	16(%r12), %rcx
	movq	8(%rcx), %rcx
	movb	%bl, 1(%rcx)
	movq	(%r15), %rcx
	leaq	(%rax,%rcx), %rsi
	incq	%rsi
	movl	%r14d, %edi
	callq	_outb
	movl	8(%r12), %eax
	addl	$32, %eax
	movq	16(%r12), %rcx
	movq	16(%rcx), %rcx
	movb	%bl, 1(%rcx)
	movq	(%r15), %rcx
	leaq	(%rax,%rcx), %rsi
	incq	%rsi
	movl	%r14d, %edi
	callq	_outb
	movl	8(%r12), %eax
	addl	$48, %eax
	movq	16(%r12), %rcx
	movq	24(%rcx), %rcx
	movb	%bl, 1(%rcx)
	movq	(%r15), %rcx
	leaq	(%rax,%rcx), %rsi
	incq	%rsi
	movl	%r14d, %edi
	callq	_outb
	movl	$1, %eax
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VIA_DXS_MAX_VOLUME,1,0         ## @VIA_DXS_MAX_VOLUME
	.comm	_VIA_REG_OFS_PLAYBACK_VOLUME_L,8,3 ## @VIA_REG_OFS_PLAYBACK_VOLUME_L
	.no_dead_strip	_snd_via8233_pcmdxs_volume_put
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_via8233_pcmdxs_volume_put
_snd_via8233_pcmdxs_volume_put:         ; @snd_via8233_pcmdxs_volume_put
	.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
	bl	_snd_kcontrol_chip
	mov	x19, x0
	ldr	x9, [x20]
	ldrb	w8, [x9]
Lloh0:
	adrp	x23, _VIA_DXS_MAX_VOLUME@GOTPAGE
Lloh1:
	ldr	x23, [x23, _VIA_DXS_MAX_VOLUME@GOTPAGEOFF]
	ldrb	w10, [x23]
	subs	w8, w10, w8
	csel	w24, wzr, w8, lo
	ldr	x8, [x0]
	ldrb	w11, [x8]
Lloh2:
	adrp	x22, _VIA_REG_OFS_PLAYBACK_VOLUME_L@GOTPAGE
Lloh3:
	ldr	x22, [x22, _VIA_REG_OFS_PLAYBACK_VOLUME_L@GOTPAGEOFF]
	cmp	w24, w11
	b.ne	LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_3
LBB0_2:
	strb	w24, [x8]
	ldr	w8, [x19, #8]
	ldr	x9, [x19, #16]
	ldr	x9, [x9]
	strb	w24, [x9]
	ldr	x9, [x22]
	add	x1, x9, x8
	and	w21, w24, #0xff
	mov	x0, x21
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #16
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #8]
	strb	w24, [x9]
	ldr	x9, [x22]
	add	x1, x9, x8
	mov	x0, x21
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #32
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #16]
	strb	w24, [x9]
	ldr	x9, [x22]
	add	x1, x9, x8
	mov	x0, x21
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #48
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #24]
	strb	w24, [x9]
	ldr	x9, [x22]
	add	x1, x9, x8
	mov	x0, x21
	bl	_outb
	ldr	x9, [x20]
	ldrb	w10, [x23]
	mov	w0, #1
	ldr	x8, [x19]
LBB0_3:
	ldrb	w9, [x9, #1]
	subs	w9, w10, w9
	csel	w21, wzr, w9, lo
	ldrb	w9, [x8, #1]
	cmp	w21, w9
	b.eq	LBB0_5
; %bb.4:
	strb	w21, [x8, #1]
	ldr	w8, [x19, #8]
	ldr	x9, [x19, #16]
	ldr	x9, [x9]
	strb	w21, [x9, #1]
	ldr	x9, [x22]
	add	x8, x8, x9
	add	x1, x8, #1
	and	w20, w21, #0xff
	mov	x0, x20
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #16
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #8]
	strb	w21, [x9, #1]
	ldr	x9, [x22]
	add	x8, x8, x9
	add	x1, x8, #1
	mov	x0, x20
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #32
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #16]
	strb	w21, [x9, #1]
	ldr	x9, [x22]
	add	x8, x8, x9
	add	x1, x8, #1
	mov	x0, x20
	bl	_outb
	ldr	w8, [x19, #8]
	add	w8, w8, #48
	ldr	x9, [x19, #16]
	ldr	x9, [x9, #24]
	strb	w21, [x9, #1]
	ldr	x9, [x22]
	add	x8, x8, x9
	add	x1, x8, #1
	mov	x0, x20
	bl	_outb
	mov	w0, #1
LBB0_5:
	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 AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_VIA_DXS_MAX_VOLUME,1,0         ; @VIA_DXS_MAX_VOLUME
	.comm	_VIA_REG_OFS_PLAYBACK_VOLUME_L,8,3 ; @VIA_REG_OFS_PLAYBACK_VOLUME_L
	.no_dead_strip	_snd_via8233_pcmdxs_volume_put
.subsections_via_symbols
