	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tegra_devfreq_update_avg_wmark
_tegra_devfreq_update_avg_wmark:        ## @tegra_devfreq_update_avg_wmark
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	_ACTMON_DEFAULT_AVG_BAND@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	imull	(%rdi), %eax
	movq	_KHZ@GOTPCREL(%rip), %rcx
	cltd
	idivl	(%rcx)
	movl	%eax, %ebx
	movq	%rsi, %r14
	movq	_ACTMON_SAMPLING_PERIOD@GOTPCREL(%rip), %rax
	imull	(%rax), %ebx
	movl	(%rsi), %esi
	addl	%ebx, %esi
	movq	_ACTMON_DEV_AVG_UPPER_WMARK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_device_writel
	movl	(%r14), %edi
	movl	%ebx, %esi
	callq	_max
	subl	%ebx, %eax
	movq	_ACTMON_DEV_AVG_LOWER_WMARK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_device_writel                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ACTMON_DEFAULT_AVG_BAND,4,2    ## @ACTMON_DEFAULT_AVG_BAND
	.comm	_KHZ,4,2                        ## @KHZ
	.comm	_ACTMON_SAMPLING_PERIOD,4,2     ## @ACTMON_SAMPLING_PERIOD
	.comm	_ACTMON_DEV_AVG_UPPER_WMARK,4,2 ## @ACTMON_DEV_AVG_UPPER_WMARK
	.comm	_ACTMON_DEV_AVG_LOWER_WMARK,4,2 ## @ACTMON_DEV_AVG_LOWER_WMARK
	.no_dead_strip	_tegra_devfreq_update_avg_wmark
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tegra_devfreq_update_avg_wmark
_tegra_devfreq_update_avg_wmark:        ; @tegra_devfreq_update_avg_wmark
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	ldr	w8, [x1]
	ldr	w9, [x0]
Lloh0:
	adrp	x10, _ACTMON_DEFAULT_AVG_BAND@GOTPAGE
Lloh1:
	ldr	x10, [x10, _ACTMON_DEFAULT_AVG_BAND@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	mul	w9, w10, w9
Lloh3:
	adrp	x10, _KHZ@GOTPAGE
Lloh4:
	ldr	x10, [x10, _KHZ@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	sdiv	w9, w9, w10
Lloh6:
	adrp	x10, _ACTMON_SAMPLING_PERIOD@GOTPAGE
Lloh7:
	ldr	x10, [x10, _ACTMON_SAMPLING_PERIOD@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	mul	w20, w10, w9
	add	w1, w20, w8
Lloh9:
	adrp	x8, _ACTMON_DEV_AVG_UPPER_WMARK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ACTMON_DEV_AVG_UPPER_WMARK@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_device_writel
	ldr	w0, [x19]
	mov	x1, x20
	bl	_max
	sub	w1, w0, w20
Lloh12:
	adrp	x8, _ACTMON_DEV_AVG_LOWER_WMARK@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ACTMON_DEV_AVG_LOWER_WMARK@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_device_writel
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_ACTMON_DEFAULT_AVG_BAND,4,2    ; @ACTMON_DEFAULT_AVG_BAND
	.comm	_KHZ,4,2                        ; @KHZ
	.comm	_ACTMON_SAMPLING_PERIOD,4,2     ; @ACTMON_SAMPLING_PERIOD
	.comm	_ACTMON_DEV_AVG_UPPER_WMARK,4,2 ; @ACTMON_DEV_AVG_UPPER_WMARK
	.comm	_ACTMON_DEV_AVG_LOWER_WMARK,4,2 ; @ACTMON_DEV_AVG_LOWER_WMARK
	.no_dead_strip	_tegra_devfreq_update_avg_wmark
.subsections_via_symbols
