	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_hwmon_get_fan1_input
_amdgpu_hwmon_get_fan1_input:           ## @amdgpu_hwmon_get_fan1_input
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	callq	_dev_get_drvdata
	movq	%rax, %rbx
	movl	$0, -20(%rbp)
	movq	_AMD_IS_PX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rbx)
	je	LBB0_3
## %bb.1:
	movq	24(%rbx), %rax
	movq	(%rax), %rax
	movq	_DRM_SWITCH_POWER_ON@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
LBB0_3:
	movq	%rbx, %rdi
	callq	_is_support_sw_smu
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	addq	$16, %rbx
	leaq	-20(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_smu_get_fan_speed_rpm
	testl	%eax, %eax
	jne	LBB0_9
	jmp	LBB0_8
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_9
LBB0_5:
	movq	8(%rbx), %rax
	cmpq	$0, (%rax)
	je	LBB0_8
## %bb.6:
	leaq	-20(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_amdgpu_dpm_get_fan_speed_rpm
	testl	%eax, %eax
	jne	LBB0_9
LBB0_8:
	movl	-20(%rbp), %edx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_sprintf
LBB0_9:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AMD_IS_PX,4,2                  ## @AMD_IS_PX
	.comm	_DRM_SWITCH_POWER_ON,8,3        ## @DRM_SWITCH_POWER_ON
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%i\n"

	.no_dead_strip	_amdgpu_hwmon_get_fan1_input
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_hwmon_get_fan1_input
_amdgpu_hwmon_get_fan1_input:           ; @amdgpu_hwmon_get_fan1_input
	.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, x2
	bl	_dev_get_drvdata
	mov	x20, x0
	str	wzr, [sp, #12]
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _AMD_IS_PX@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AMD_IS_PX@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x20, #24]
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _DRM_SWITCH_POWER_ON@GOTPAGE
Lloh4:
	ldr	x9, [x9, _DRM_SWITCH_POWER_ON@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
LBB0_2:
	mov	x0, x20
	bl	_is_support_sw_smu
	cbz	x0, LBB0_5
; %bb.3:
	add	x0, x20, #16
	add	x1, sp, #12
	bl	_smu_get_fan_speed_rpm
	cbnz	w0, LBB0_8
	b	LBB0_7
LBB0_4:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_8
LBB0_5:
	ldr	x8, [x20, #8]
	ldr	x8, [x8]
	cbz	x8, LBB0_7
; %bb.6:
	add	x1, sp, #12
	mov	x0, x20
	bl	_amdgpu_dpm_get_fan_speed_rpm
	cbnz	w0, LBB0_8
LBB0_7:
	ldr	w2, [sp, #12]
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_sprintf
LBB0_8:
	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 AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_AMD_IS_PX,4,2                  ; @AMD_IS_PX
	.comm	_DRM_SWITCH_POWER_ON,8,3        ; @DRM_SWITCH_POWER_ON
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%i\n"

	.no_dead_strip	_amdgpu_hwmon_get_fan1_input
.subsections_via_symbols
