	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sony_nc_thermal_mode_store
_sony_nc_thermal_mode_store:            ## @sony_nc_thermal_mode_store
	.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
	testq	%rcx, %rcx
	je	LBB0_1
## %bb.2:
	movq	%rcx, %r14
	movq	%rdx, %r15
	leaq	-1(%rcx), %r12
	cmpb	$10, -1(%rdx,%rcx)
	cmovneq	%rcx, %r12
	movq	_THM_PROFILE_MAX@GOTPCREL(%rip), %rax
	cmpw	$0, (%rax)
	je	LBB0_3
## %bb.4:
	xorl	%ebx, %ebx
	movq	_snc_thermal_profiles@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rax
	movl	(%rax,%rbx,4), %esi
	movq	%r15, %rdi
	movq	%r12, %rdx
	callq	_strncmp
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	incq	%rbx
	movq	_THM_PROFILE_MAX@GOTPCREL(%rip), %rax
	movzwl	(%rax), %eax
	cmpq	%rax, %rbx
	jb	LBB0_5
	jmp	LBB0_7
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_3:
	xorl	%ebx, %ebx
LBB0_7:
	movzwl	%bx, %edi
	callq	_sony_nc_thermal_mode_set
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_9:
	xorl	%r14d, %r14d
	subq	(%rax), %r14
LBB0_10:
	movq	%r14, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,8,3                     ## @EINVAL
	.comm	_THM_PROFILE_MAX,2,1            ## @THM_PROFILE_MAX
	.comm	_snc_thermal_profiles,8,3       ## @snc_thermal_profiles
	.comm	_EIO,8,3                        ## @EIO
	.no_dead_strip	_sony_nc_thermal_mode_store
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sony_nc_thermal_mode_store
_sony_nc_thermal_mode_store:            ; @sony_nc_thermal_mode_store
	.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
	cbz	x3, LBB0_5
; %bb.1:
	mov	x19, x3
	mov	x20, x2
	sub	x8, x3, #1
	ldrb	w9, [x2, x8]
	cmp	w9, #10
	csel	x21, x8, x3, eq
Lloh0:
	adrp	x23, _THM_PROFILE_MAX@GOTPAGE
Lloh1:
	ldr	x23, [x23, _THM_PROFILE_MAX@GOTPAGEOFF]
	ldrh	w8, [x23]
	cbz	w8, LBB0_6
; %bb.2:
	mov	x22, #0
Lloh2:
	adrp	x24, _snc_thermal_profiles@GOTPAGE
Lloh3:
	ldr	x24, [x24, _snc_thermal_profiles@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	w1, [x8, x22, lsl #2]
	mov	x0, x20
	mov	x2, x21
	bl	_strncmp
	cbz	x0, LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, #1
	ldrh	w8, [x23]
	cmp	x22, x8
	b.lo	LBB0_3
	b	LBB0_7
LBB0_5:
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_9
LBB0_6:
	mov	w22, #0
LBB0_7:
	and	w0, w22, #0xffff
	bl	_sony_nc_thermal_mode_set
	cbz	x0, LBB0_10
; %bb.8:
Lloh6:
	adrp	x8, _EIO@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_9:
	ldr	x8, [x8]
	neg	x19, x8
LBB0_10:
	mov	x0, x19
	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	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,8,3                     ; @EINVAL
	.comm	_THM_PROFILE_MAX,2,1            ; @THM_PROFILE_MAX
	.comm	_snc_thermal_profiles,8,3       ; @snc_thermal_profiles
	.comm	_EIO,8,3                        ; @EIO
	.no_dead_strip	_sony_nc_thermal_mode_store
.subsections_via_symbols
