	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function adm1025_detect
_adm1025_detect:                        ## @adm1025_detect
	.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	%rdx, %r14
	movl	%esi, %ebx
	movq	%rdi, %r13
	movq	8(%rdi), %r15
	movq	_I2C_FUNC_SMBUS_BYTE_DATA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_i2c_check_functionality
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	_ADM1025_REG_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_i2c_smbus_read_byte_data
	testl	%ebx, %ebx
	js	LBB0_3
## %bb.7:
	je	LBB0_8
LBB0_17:
	movq	_adm1025@GOTPCREL(%rip), %rax
	movq	_ne1619@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %ebx
	leaq	L_.str.4(%rip), %rcx
	leaq	L_.str(%rip), %rdx
	cmoveq	%rcx, %rdx
	cmpl	(%rax), %ebx
	leaq	L_.str.3(%rip), %rsi
	cmovneq	%rdx, %rsi
	movl	(%r14), %edi
	movq	_I2C_NAME_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_strlcpy
	xorl	%eax, %eax
	jmp	LBB0_18
LBB0_3:
	testb	$-128, %al
	jne	LBB0_6
## %bb.4:
	movq	_ADM1025_REG_STATUS1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_i2c_smbus_read_byte_data
	testb	$-64, %al
	jne	LBB0_6
## %bb.5:
	movq	_ADM1025_REG_STATUS2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_i2c_smbus_read_byte_data
	testb	$-68, %al
	je	LBB0_8
LBB0_6:
	movl	(%r13), %edx
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_dbg
	jmp	LBB0_1
LBB0_8:
	movq	_ADM1025_REG_MAN_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_i2c_smbus_read_byte_data
	movl	%eax, %r12d
	movq	_ADM1025_REG_CHIP_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_i2c_smbus_read_byte_data
	cmpl	$161, %r12d
	je	LBB0_12
## %bb.9:
	cmpl	$65, %r12d
	jne	LBB0_16
## %bb.10:
	movl	%eax, %ecx
	andl	$240, %ecx
	cmpl	$32, %ecx
	jne	LBB0_16
## %bb.11:
	movq	_adm1025@GOTPCREL(%rip), %rcx
	jmp	LBB0_15
LBB0_12:
	cmpl	$46, (%r13)
	je	LBB0_16
## %bb.13:
	movl	%eax, %ecx
	andl	$240, %ecx
	cmpl	$32, %ecx
	jne	LBB0_16
## %bb.14:
	movq	_ne1619@GOTPCREL(%rip), %rcx
LBB0_15:
	movl	(%rcx), %ebx
	testl	%ebx, %ebx
	jg	LBB0_17
LBB0_16:
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	movl	%r12d, %edx
	movl	%eax, %ecx
	callq	_dev_info
LBB0_1:
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.space	1

	.comm	_I2C_FUNC_SMBUS_BYTE_DATA,4,2   ## @I2C_FUNC_SMBUS_BYTE_DATA
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_ADM1025_REG_CONFIG,4,2         ## @ADM1025_REG_CONFIG
	.comm	_ADM1025_REG_STATUS1,4,2        ## @ADM1025_REG_STATUS1
	.comm	_ADM1025_REG_STATUS2,4,2        ## @ADM1025_REG_STATUS2
L_.str.1:                               ## @.str.1
	.asciz	"ADM1025 detection failed at 0x%02x.\n"

	.comm	_ADM1025_REG_MAN_ID,4,2         ## @ADM1025_REG_MAN_ID
	.comm	_ADM1025_REG_CHIP_ID,4,2        ## @ADM1025_REG_CHIP_ID
	.comm	_adm1025,4,2                    ## @adm1025
	.comm	_ne1619,4,2                     ## @ne1619
L_.str.2:                               ## @.str.2
	.asciz	"Unsupported chip (man_id=0x%02X, chip_id=0x%02X).\n"

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

L_.str.4:                               ## @.str.4
	.asciz	"ne1619"

	.comm	_I2C_NAME_SIZE,4,2              ## @I2C_NAME_SIZE
	.no_dead_strip	_adm1025_detect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function adm1025_detect
_adm1025_detect:                        ; @adm1025_detect
	.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	x19, x2
	mov	x23, x1
	mov	x21, x0
	ldr	x20, [x0, #8]
Lloh0:
	adrp	x8, _I2C_FUNC_SMBUS_BYTE_DATA@GOTPAGE
Lloh1:
	ldr	x8, [x8, _I2C_FUNC_SMBUS_BYTE_DATA@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_i2c_check_functionality
	cbz	w0, LBB0_17
; %bb.1:
Lloh3:
	adrp	x8, _ADM1025_REG_CONFIG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ADM1025_REG_CONFIG@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_i2c_smbus_read_byte_data
	tbnz	w23, #31, LBB0_4
; %bb.2:
	cbz	w23, LBB0_8
LBB0_3:
Lloh6:
	adrp	x8, _adm1025@GOTPAGE
Lloh7:
	ldr	x8, [x8, _adm1025@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _ne1619@GOTPAGE
Lloh10:
	ldr	x9, [x9, _ne1619@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
Lloh12:
	adrp	x10, l_.str@PAGE
Lloh13:
	add	x10, x10, l_.str@PAGEOFF
Lloh14:
	adrp	x11, l_.str.4@PAGE
Lloh15:
	add	x11, x11, l_.str.4@PAGEOFF
	cmp	w23, w9
	csel	x9, x11, x10, eq
Lloh16:
	adrp	x10, l_.str.3@PAGE
Lloh17:
	add	x10, x10, l_.str.3@PAGEOFF
	cmp	w23, w8
	csel	x1, x10, x9, eq
	ldr	w0, [x19]
Lloh18:
	adrp	x8, _I2C_NAME_SIZE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _I2C_NAME_SIZE@GOTPAGEOFF]
Lloh20:
	ldr	w2, [x8]
	bl	_strlcpy
	mov	w0, #0
	b	LBB0_18
LBB0_4:
	tbnz	w0, #7, LBB0_7
; %bb.5:
Lloh21:
	adrp	x8, _ADM1025_REG_STATUS1@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ADM1025_REG_STATUS1@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_i2c_smbus_read_byte_data
	tst	w0, #0xc0
	b.ne	LBB0_7
; %bb.6:
Lloh24:
	adrp	x8, _ADM1025_REG_STATUS2@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ADM1025_REG_STATUS2@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_i2c_smbus_read_byte_data
	mov	w8, #188
	tst	w0, w8
	b.eq	LBB0_8
LBB0_7:
	ldr	w2, [x21]
Lloh27:
	adrp	x1, l_.str.1@PAGE
Lloh28:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_dev_dbg
	b	LBB0_17
LBB0_8:
Lloh29:
	adrp	x8, _ADM1025_REG_MAN_ID@GOTPAGE
Lloh30:
	ldr	x8, [x8, _ADM1025_REG_MAN_ID@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_i2c_smbus_read_byte_data
	mov	x22, x0
Lloh32:
	adrp	x8, _ADM1025_REG_CHIP_ID@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ADM1025_REG_CHIP_ID@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_i2c_smbus_read_byte_data
	mov	x3, x0
	cmp	w22, #161
	b.eq	LBB0_12
; %bb.9:
	cmp	w22, #65
	b.ne	LBB0_16
; %bb.10:
	and	w8, w3, #0xf0
	cmp	w8, #32
	b.ne	LBB0_16
; %bb.11:
Lloh35:
	adrp	x8, _adm1025@GOTPAGE
Lloh36:
	ldr	x8, [x8, _adm1025@GOTPAGEOFF]
	b	LBB0_15
LBB0_12:
	ldr	w8, [x21]
	cmp	w8, #46
	b.eq	LBB0_16
; %bb.13:
	and	w8, w3, #0xf0
	cmp	w8, #32
	b.ne	LBB0_16
; %bb.14:
Lloh37:
	adrp	x8, _ne1619@GOTPAGE
Lloh38:
	ldr	x8, [x8, _ne1619@GOTPAGEOFF]
LBB0_15:
	ldr	w23, [x8]
	cmp	w23, #0
	b.gt	LBB0_3
LBB0_16:
Lloh39:
	adrp	x1, l_.str.2@PAGE
Lloh40:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	mov	x2, x22
	bl	_dev_info
LBB0_17:
Lloh41:
	adrp	x8, _ENODEV@GOTPAGE
Lloh42:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh43:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_18:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.space	1

	.comm	_I2C_FUNC_SMBUS_BYTE_DATA,4,2   ; @I2C_FUNC_SMBUS_BYTE_DATA
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_ADM1025_REG_CONFIG,4,2         ; @ADM1025_REG_CONFIG
	.comm	_ADM1025_REG_STATUS1,4,2        ; @ADM1025_REG_STATUS1
	.comm	_ADM1025_REG_STATUS2,4,2        ; @ADM1025_REG_STATUS2
l_.str.1:                               ; @.str.1
	.asciz	"ADM1025 detection failed at 0x%02x.\n"

	.comm	_ADM1025_REG_MAN_ID,4,2         ; @ADM1025_REG_MAN_ID
	.comm	_ADM1025_REG_CHIP_ID,4,2        ; @ADM1025_REG_CHIP_ID
	.comm	_adm1025,4,2                    ; @adm1025
	.comm	_ne1619,4,2                     ; @ne1619
l_.str.2:                               ; @.str.2
	.asciz	"Unsupported chip (man_id=0x%02X, chip_id=0x%02X).\n"

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

l_.str.4:                               ; @.str.4
	.asciz	"ne1619"

	.comm	_I2C_NAME_SIZE,4,2              ; @I2C_NAME_SIZE
	.no_dead_strip	_adm1025_detect
.subsections_via_symbols
