	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i801_check_pre
_i801_check_pre:                        ## @i801_check_pre
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	callq	_SMBHSTSTS
	movl	%eax, %edi
	callq	_inb_p
	movl	%eax, %ebx
	movq	_SMBHSTSTS_HOST_BUSY@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_2
## %bb.1:
	movq	(%r15), %rdi
	leaq	L_.str(%rip), %rsi
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_5
LBB0_2:
	movq	_STATUS_FLAGS@GOTPCREL(%rip), %r12
	xorl	%r14d, %r14d
	andl	(%r12), %ebx
	je	LBB0_6
## %bb.3:
	movq	(%r15), %rdi
	leaq	L_.str.1(%rip), %rsi
	movl	%ebx, %edx
	callq	_dev_dbg
	movq	%r15, %rdi
	callq	_SMBHSTSTS
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_outb_p
	movq	%r15, %rdi
	callq	_SMBHSTSTS
	movl	%eax, %edi
	callq	_inb_p
	andl	(%r12), %eax
	je	LBB0_6
## %bb.4:
	movq	(%r15), %rdi
	leaq	L_.str.2(%rip), %rsi
	xorl	%r14d, %r14d
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_5:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
LBB0_6:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SMBHSTSTS_HOST_BUSY,4,2        ## @SMBHSTSTS_HOST_BUSY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SMBus is busy, can't use it!\n"

	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_STATUS_FLAGS,4,2               ## @STATUS_FLAGS
L_.str.1:                               ## @.str.1
	.asciz	"Clearing status flags (%02x)\n"

L_.str.2:                               ## @.str.2
	.asciz	"Failed clearing status flags (%02x)\n"

	.no_dead_strip	_i801_check_pre
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i801_check_pre
_i801_check_pre:                        ; @i801_check_pre
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	bl	_SMBHSTSTS
	bl	_inb_p
Lloh0:
	adrp	x8, _SMBHSTSTS_HOST_BUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SMBHSTSTS_HOST_BUSY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.1:
	ldr	x0, [x19]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
LBB0_2:
	bl	_dev_err
Lloh5:
	adrp	x8, _EBUSY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_7
LBB0_3:
Lloh8:
	adrp	x21, _STATUS_FLAGS@GOTPAGE
Lloh9:
	ldr	x21, [x21, _STATUS_FLAGS@GOTPAGEOFF]
	ldr	w8, [x21]
	ands	w20, w8, w0
	b.eq	LBB0_6
; %bb.4:
	ldr	x0, [x19]
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x20
	bl	_dev_dbg
	mov	x0, x19
	bl	_SMBHSTSTS
	mov	x1, x0
	mov	x0, x20
	bl	_outb_p
	mov	x0, x19
	bl	_SMBHSTSTS
	bl	_inb_p
	ldr	w8, [x21]
	ands	w8, w8, w0
	b.eq	LBB0_6
; %bb.5:
	ldr	x0, [x19]
	str	x8, [sp]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_2
LBB0_6:
	mov	w0, #0
LBB0_7:
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_SMBHSTSTS_HOST_BUSY,4,2        ; @SMBHSTSTS_HOST_BUSY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SMBus is busy, can't use it!\n"

	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_STATUS_FLAGS,4,2               ; @STATUS_FLAGS
l_.str.1:                               ; @.str.1
	.asciz	"Clearing status flags (%02x)\n"

l_.str.2:                               ; @.str.2
	.asciz	"Failed clearing status flags (%02x)\n"

	.no_dead_strip	_i801_check_pre
.subsections_via_symbols
