	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rpi_firmware_get_throttled
_rpi_firmware_get_throttled:            ## @rpi_firmware_get_throttled
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	movl	$65535, -12(%rbp)               ## imm = 0xFFFF
	movl	16(%rdi), %edi
	movq	_RPI_FIRMWARE_GET_THROTTLED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-12(%rbp), %rdx
	movl	$4, %ecx
	callq	_rpi_firmware_property
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movq	8(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edx
	callq	_dev_err_once
	jmp	LBB0_7
LBB0_2:
	movl	-12(%rbp), %ecx
	movq	_UNDERVOLTAGE_STICKY_BIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%edx, %eax
	andl	%ecx, %eax
	andl	(%rbx), %edx
	movl	%ecx, (%rbx)
	cmpl	%edx, %eax
	je	LBB0_7
## %bb.3:
	movq	8(%rbx), %rdi
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_crit
	jmp	LBB0_6
LBB0_5:
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_info
LBB0_6:
	movq	8(%rbx), %rdi
	leaq	L_.str.3(%rip), %rdx
	xorl	%esi, %esi
	callq	_sysfs_notify
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RPI_FIRMWARE_GET_THROTTLED,4,2 ## @RPI_FIRMWARE_GET_THROTTLED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to get throttled (%d)\n"

	.comm	_UNDERVOLTAGE_STICKY_BIT,4,2    ## @UNDERVOLTAGE_STICKY_BIT
L_.str.1:                               ## @.str.1
	.asciz	"Undervoltage detected!\n"

L_.str.2:                               ## @.str.2
	.asciz	"Voltage normalised\n"

L_.str.3:                               ## @.str.3
	.asciz	"in0_lcrit_alarm"

	.no_dead_strip	_rpi_firmware_get_throttled
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rpi_firmware_get_throttled
_rpi_firmware_get_throttled:            ; @rpi_firmware_get_throttled
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	mov	w8, #65535
	str	w8, [sp, #12]
	ldr	w0, [x0, #16]
Lloh0:
	adrp	x8, _RPI_FIRMWARE_GET_THROTTLED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RPI_FIRMWARE_GET_THROTTLED@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	w3, #4
	bl	_rpi_firmware_property
	cbz	w0, LBB0_2
; %bb.1:
	mov	x2, x0
	ldr	x0, [x19, #8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err_once
	b	LBB0_7
LBB0_2:
	ldr	w9, [sp, #12]
Lloh5:
	adrp	x8, _UNDERVOLTAGE_STICKY_BIT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _UNDERVOLTAGE_STICKY_BIT@GOTPAGEOFF]
Lloh7:
	ldr	w10, [x8]
	and	w8, w10, w9
	ldr	w11, [x19]
	and	w10, w11, w10
	str	w9, [x19]
	cmp	w8, w10
	b.eq	LBB0_7
; %bb.3:
	ldr	x0, [x19, #8]
	cbz	w8, LBB0_5
; %bb.4:
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_crit
	b	LBB0_6
LBB0_5:
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_info
LBB0_6:
	ldr	x0, [x19, #8]
Lloh12:
	adrp	x2, l_.str.3@PAGE
Lloh13:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x1, #0
	bl	_sysfs_notify
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_RPI_FIRMWARE_GET_THROTTLED,4,2 ; @RPI_FIRMWARE_GET_THROTTLED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to get throttled (%d)\n"

	.comm	_UNDERVOLTAGE_STICKY_BIT,4,2    ; @UNDERVOLTAGE_STICKY_BIT
l_.str.1:                               ; @.str.1
	.asciz	"Undervoltage detected!\n"

l_.str.2:                               ; @.str.2
	.asciz	"Voltage normalised\n"

l_.str.3:                               ; @.str.3
	.asciz	"in0_lcrit_alarm"

	.no_dead_strip	_rpi_firmware_get_throttled
.subsections_via_symbols
