	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ali1535_transaction
_ali1535_transaction:                   ## @ali1535_transaction
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movq	_SMBHSTSTS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_SMBHSTTYP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_SMBHSTCMD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r13d
	movq	_SMBHSTADD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r15d
	movq	_SMBHSTDAT0@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r14d
	movq	_SMBHSTDAT1@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rsi
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	%r13d, %r8d
	movl	%r15d, %r9d
	xorl	%eax, %eax
	pushq	%rbx
	movq	_SMBHSTSTS@GOTPCREL(%rip), %r15
	pushq	%r14
	callq	_dev_dbg
	addq	$16, %rsp
	movl	(%r15), %edi
	callq	_inb_p
	movq	_ALI1535_STS_BUSY@GOTPCREL(%rip), %r14
	movl	(%r14), %ecx
	testl	%eax, %ecx
	je	LBB0_2
## %bb.1:
	leaq	L_.str.1(%rip), %rsi
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_dev_info
	movq	_ALI1535_T_OUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SMBHSTTYP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_outb_p
	movl	(%r15), %edi
	callq	_inb_p
	movl	(%r14), %ecx
	jmp	LBB0_3
LBB0_2:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_3:
	movq	_ALI1535_STS_ERR@GOTPCREL(%rip), %r12
	orl	(%r12), %ecx
	testl	%eax, %ecx
	je	LBB0_6
## %bb.4:
	movl	(%r15), %esi
	movl	$255, %edi
	callq	_outb_p
	movl	(%r15), %edi
	callq	_inb_p
	movl	(%r14), %ecx
	orl	(%r12), %ecx
	testl	%eax, %ecx
	je	LBB0_8
## %bb.5:
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%rbx, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EBUSY@GOTPCREL(%rip), %rax
	subl	(%rax), %r15d
	jmp	LBB0_29
LBB0_6:
	movq	_ALI1535_STS_DONE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_8
## %bb.7:
	movl	(%r15), %esi
	movl	%eax, %edi
	callq	_outb_p
LBB0_8:
	movq	_SMBHSTPORT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$255, %edi
	callq	_outb_p
	xorl	%ebx, %ebx
	movq	_ALI1535_STS_IDLE@GOTPCREL(%rip), %r15
	movq	_MAX_TIMEOUT@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	$1, %edi
	callq	_msleep
	movq	_SMBHSTSTS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r13d
	testl	%eax, (%r14)
	je	LBB0_13
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	testl	%r13d, (%r15)
	jne	LBB0_13
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=1
	leal	1(%rbx), %eax
	cmpl	(%r12), %ebx
	movl	%eax, %ebx
	jl	LBB0_9
	jmp	LBB0_14
LBB0_13:
	movl	%ebx, %eax
LBB0_14:
	xorl	%r15d, %r15d
	cmpl	(%r12), %eax
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	jle	LBB0_16
## %bb.15:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	leaq	L_.str.3(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_dev_err
LBB0_16:
	movq	_ALI1535_STS_FAIL@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	movq	_SMBHSTADD@GOTPCREL(%rip), %r14
	je	LBB0_18
## %bb.17:
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	leaq	L_.str.4(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_18:
	movq	_ALI1535_STS_BUSERR@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_20
## %bb.19:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	movl	(%r14), %edi
	callq	_inb_p
	leaq	L_.str.5(%rip), %rsi
	movq	%r12, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_20:
	movq	_ALI1535_STS_DEV@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_22
## %bb.21:
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	leaq	L_.str.6(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_dev_err
LBB0_22:
	movq	_ALI1535_STS_DONE@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	jne	LBB0_24
## %bb.23:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	leaq	L_.str.7(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_dev_err
LBB0_24:
	movq	_SMBHSTSTS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_SMBHSTTYP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_SMBHSTCMD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	_SMBHSTADD@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r14d
	movq	_SMBHSTDAT0@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %ebx
	movq	_SMBHSTDAT1@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_inb_p
	movl	%eax, %r10d
	leaq	L_.str.8(%rip), %rsi
	movq	%r12, %rdi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	-60(%rbp), %r8d                 ## 4-byte Reload
	movl	%r14d, %r9d
	xorl	%eax, %eax
	pushq	%r10
	pushq	%rbx
	callq	_dev_dbg
	addq	$16, %rsp
	movq	_ALI1535_STS_DONE@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_27
## %bb.25:
	movq	_SMBHSTTYP@GOTPCREL(%rip), %rcx
	movq	_ALI1535_STS_ERR@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_29
## %bb.26:
	movq	_ALI1535_T_OUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rcx), %esi
	jmp	LBB0_28
LBB0_27:
	movq	_ALI1535_KILL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SMBHSTTYP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
LBB0_28:
	callq	_outb_p
	movq	_SMBHSTSTS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$255, %edi
	callq	_outb_p
LBB0_29:
	movl	%r15d, %eax
	addq	$24, %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
	.asciz	"Transaction (pre): STS=%02x, TYP=%02x, CMD=%02x, ADD=%02x, DAT0=%02x, DAT1=%02x\n"

	.comm	_SMBHSTSTS,4,2                  ## @SMBHSTSTS
	.comm	_SMBHSTTYP,4,2                  ## @SMBHSTTYP
	.comm	_SMBHSTCMD,4,2                  ## @SMBHSTCMD
	.comm	_SMBHSTADD,4,2                  ## @SMBHSTADD
	.comm	_SMBHSTDAT0,4,2                 ## @SMBHSTDAT0
	.comm	_SMBHSTDAT1,4,2                 ## @SMBHSTDAT1
	.comm	_ALI1535_STS_BUSY,4,2           ## @ALI1535_STS_BUSY
L_.str.1:                               ## @.str.1
	.asciz	"Resetting entire SMB Bus to clear busy condition (%02x)\n"

	.comm	_ALI1535_T_OUT,4,2              ## @ALI1535_T_OUT
	.comm	_ALI1535_STS_ERR,4,2            ## @ALI1535_STS_ERR
L_.str.2:                               ## @.str.2
	.asciz	"SMBus reset failed! (0x%02x) - controller or device on bus is probably hung\n"

	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_ALI1535_STS_DONE,4,2           ## @ALI1535_STS_DONE
	.comm	_SMBHSTPORT,4,2                 ## @SMBHSTPORT
	.comm	_ALI1535_STS_IDLE,4,2           ## @ALI1535_STS_IDLE
	.comm	_MAX_TIMEOUT,4,2                ## @MAX_TIMEOUT
	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
L_.str.3:                               ## @.str.3
	.asciz	"SMBus Timeout!\n"

	.comm	_ALI1535_STS_FAIL,4,2           ## @ALI1535_STS_FAIL
	.comm	_EIO,4,2                        ## @EIO
L_.str.4:                               ## @.str.4
	.asciz	"Error: Failed bus transaction\n"

	.comm	_ALI1535_STS_BUSERR,4,2         ## @ALI1535_STS_BUSERR
	.comm	_ENXIO,4,2                      ## @ENXIO
L_.str.5:                               ## @.str.5
	.asciz	"Error: no response or bus collision ADD=%02x\n"

	.comm	_ALI1535_STS_DEV,4,2            ## @ALI1535_STS_DEV
L_.str.6:                               ## @.str.6
	.asciz	"Error: device error\n"

L_.str.7:                               ## @.str.7
	.asciz	"Error: command never completed\n"

L_.str.8:                               ## @.str.8
	.asciz	"Transaction (post): STS=%02x, TYP=%02x, CMD=%02x, ADD=%02x, DAT0=%02x, DAT1=%02x\n"

	.comm	_ALI1535_KILL,4,2               ## @ALI1535_KILL
	.no_dead_strip	_ali1535_transaction
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ali1535_transaction
_ali1535_transaction:                   ; @ali1535_transaction
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x27, _SMBHSTSTS@GOTPAGE
Lloh1:
	ldr	x27, [x27, _SMBHSTSTS@GOTPAGEOFF]
	ldr	w0, [x27]
	bl	_inb_p
	mov	x20, x0
Lloh2:
	adrp	x28, _SMBHSTTYP@GOTPAGE
Lloh3:
	ldr	x28, [x28, _SMBHSTTYP@GOTPAGEOFF]
	ldr	w0, [x28]
	bl	_inb_p
	mov	x21, x0
Lloh4:
	adrp	x25, _SMBHSTCMD@GOTPAGE
Lloh5:
	ldr	x25, [x25, _SMBHSTCMD@GOTPAGEOFF]
	ldr	w0, [x25]
	bl	_inb_p
	mov	x22, x0
Lloh6:
	adrp	x26, _SMBHSTADD@GOTPAGE
Lloh7:
	ldr	x26, [x26, _SMBHSTADD@GOTPAGEOFF]
	ldr	w0, [x26]
	bl	_inb_p
	mov	x23, x0
Lloh8:
	adrp	x8, _SMBHSTDAT0@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SMBHSTDAT0@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_inb_p
	mov	x24, x0
Lloh11:
	adrp	x8, _SMBHSTDAT1@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SMBHSTDAT1@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_inb_p
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x24, x0, [sp, #32]
	stp	x22, x23, [sp, #16]
	stp	x20, x21, [sp]
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	ldr	w0, [x27]
	bl	_inb_p
	mov	x2, x0
Lloh16:
	adrp	x21, _ALI1535_STS_BUSY@GOTPAGE
Lloh17:
	ldr	x21, [x21, _ALI1535_STS_BUSY@GOTPAGEOFF]
	ldr	w8, [x21]
	tst	w8, w0
	b.eq	LBB0_2
; %bb.1:
Lloh18:
	adrp	x1, l_.str.1@PAGE
Lloh19:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_info
Lloh20:
	adrp	x8, _ALI1535_T_OUT@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ALI1535_T_OUT@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	ldr	w1, [x28]
	bl	_outb_p
	ldr	w0, [x27]
	bl	_inb_p
	mov	x2, x0
	ldr	w8, [x21]
LBB0_2:
Lloh23:
	adrp	x20, _ALI1535_STS_ERR@GOTPAGE
Lloh24:
	ldr	x20, [x20, _ALI1535_STS_ERR@GOTPAGEOFF]
	ldr	w9, [x20]
	orr	w8, w8, w9
	tst	w8, w2
	b.eq	LBB0_5
; %bb.3:
	ldr	w1, [x27]
	mov	w0, #255
	bl	_outb_p
	ldr	w0, [x27]
	bl	_inb_p
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x20]
	ldr	w9, [x21]
	orr	w8, w9, w8
	tst	w8, w0
	b.eq	LBB0_7
; %bb.4:
	str	x0, [sp]
Lloh25:
	adrp	x1, l_.str.2@PAGE
Lloh26:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_dev_err
Lloh27:
	adrp	x8, _EBUSY@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_28
LBB0_5:
Lloh30:
	adrp	x8, _ALI1535_STS_DONE@GOTPAGE
Lloh31:
	ldr	x8, [x8, _ALI1535_STS_DONE@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	tst	w8, w2
	b.eq	LBB0_7
; %bb.6:
	ldr	w1, [x27]
	mov	x0, x2
	bl	_outb_p
LBB0_7:
Lloh33:
	adrp	x8, _SMBHSTPORT@GOTPAGE
Lloh34:
	ldr	x8, [x8, _SMBHSTPORT@GOTPAGEOFF]
Lloh35:
	ldr	w1, [x8]
	mov	w0, #255
	bl	_outb_p
	mov	w23, #0
Lloh36:
	adrp	x24, _ALI1535_STS_IDLE@GOTPAGE
Lloh37:
	ldr	x24, [x24, _ALI1535_STS_IDLE@GOTPAGEOFF]
Lloh38:
	adrp	x22, _MAX_TIMEOUT@GOTPAGE
Lloh39:
	ldr	x22, [x22, _MAX_TIMEOUT@GOTPAGEOFF]
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #1
	bl	_msleep
	ldr	w0, [x27]
	bl	_inb_p
	mov	x20, x0
	ldr	w8, [x21]
	tst	w8, w0
	b.eq	LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	w8, [x24]
	tst	w8, w20
	b.ne	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	add	w8, w23, #1
	ldr	w9, [x22]
	cmp	w23, w9
	mov	x23, x8
	b.lt	LBB0_8
	b	LBB0_12
LBB0_11:
	mov	x8, x23
LBB0_12:
	ldr	w9, [x22]
	cmp	w8, w9
	b.le	LBB0_14
; %bb.13:
Lloh40:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh41:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh42:
	ldr	w8, [x8]
	neg	w21, w8
Lloh43:
	adrp	x1, l_.str.3@PAGE
Lloh44:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	b	LBB0_15
LBB0_14:
	mov	w21, #0
LBB0_15:
Lloh45:
	adrp	x8, _ALI1535_STS_FAIL@GOTPAGE
Lloh46:
	ldr	x8, [x8, _ALI1535_STS_FAIL@GOTPAGEOFF]
Lloh47:
	ldr	w8, [x8]
Lloh48:
	adrp	x22, _EIO@GOTPAGE
Lloh49:
	ldr	x22, [x22, _EIO@GOTPAGEOFF]
	tst	w8, w20
	b.eq	LBB0_17
; %bb.16:
	ldr	w8, [x22]
	neg	w21, w8
Lloh50:
	adrp	x1, l_.str.4@PAGE
Lloh51:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
LBB0_17:
Lloh52:
	adrp	x8, _ALI1535_STS_BUSERR@GOTPAGE
Lloh53:
	ldr	x8, [x8, _ALI1535_STS_BUSERR@GOTPAGEOFF]
Lloh54:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_19
; %bb.18:
Lloh55:
	adrp	x8, _ENXIO@GOTPAGE
Lloh56:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh57:
	ldr	w8, [x8]
	neg	w21, w8
	ldr	w0, [x26]
	bl	_inb_p
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh58:
	adrp	x1, l_.str.5@PAGE
Lloh59:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
LBB0_19:
Lloh60:
	adrp	x8, _ALI1535_STS_DEV@GOTPAGE
Lloh61:
	ldr	x8, [x8, _ALI1535_STS_DEV@GOTPAGEOFF]
Lloh62:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_21
; %bb.20:
	ldr	w8, [x22]
	neg	w21, w8
Lloh63:
	adrp	x1, l_.str.6@PAGE
Lloh64:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x19
	bl	_dev_err
LBB0_21:
Lloh65:
	adrp	x28, _ALI1535_STS_DONE@GOTPAGE
Lloh66:
	ldr	x28, [x28, _ALI1535_STS_DONE@GOTPAGEOFF]
	ldr	w8, [x28]
	tst	w8, w20
	b.ne	LBB0_23
; %bb.22:
Lloh67:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh68:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh69:
	ldr	w8, [x8]
	neg	w21, w8
Lloh70:
	adrp	x1, l_.str.7@PAGE
Lloh71:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x19
	bl	_dev_err
LBB0_23:
	ldr	w0, [x27]
	bl	_inb_p
	mov	x22, x0
Lloh72:
	adrp	x8, _SMBHSTTYP@GOTPAGE
Lloh73:
	ldr	x8, [x8, _SMBHSTTYP@GOTPAGEOFF]
Lloh74:
	ldr	w0, [x8]
	bl	_inb_p
	mov	x23, x0
	ldr	w0, [x25]
	bl	_inb_p
	mov	x24, x0
	ldr	w0, [x26]
	bl	_inb_p
	mov	x25, x0
Lloh75:
	adrp	x8, _SMBHSTDAT0@GOTPAGE
Lloh76:
	ldr	x8, [x8, _SMBHSTDAT0@GOTPAGEOFF]
Lloh77:
	ldr	w0, [x8]
	bl	_inb_p
	mov	x26, x0
Lloh78:
	adrp	x8, _SMBHSTDAT1@GOTPAGE
Lloh79:
	ldr	x8, [x8, _SMBHSTDAT1@GOTPAGEOFF]
Lloh80:
	ldr	w0, [x8]
	bl	_inb_p
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x26, x0, [sp, #32]
	stp	x24, x25, [sp, #16]
	stp	x22, x23, [sp]
Lloh81:
	adrp	x1, l_.str.8@PAGE
Lloh82:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	ldr	w8, [x28]
	tst	w8, w20
	b.eq	LBB0_26
; %bb.24:
Lloh83:
	adrp	x8, _ALI1535_STS_ERR@GOTPAGE
Lloh84:
	ldr	x8, [x8, _ALI1535_STS_ERR@GOTPAGEOFF]
Lloh85:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_28
; %bb.25:
Lloh86:
	adrp	x8, _ALI1535_T_OUT@GOTPAGE
Lloh87:
	ldr	x8, [x8, _ALI1535_T_OUT@GOTPAGEOFF]
	b	LBB0_27
LBB0_26:
Lloh88:
	adrp	x8, _ALI1535_KILL@GOTPAGE
Lloh89:
	ldr	x8, [x8, _ALI1535_KILL@GOTPAGEOFF]
LBB0_27:
	ldr	w0, [x8]
Lloh90:
	adrp	x8, _SMBHSTTYP@GOTPAGE
Lloh91:
	ldr	x8, [x8, _SMBHSTTYP@GOTPAGEOFF]
Lloh92:
	ldr	w1, [x8]
	bl	_outb_p
	ldr	w1, [x27]
	mov	w0, #255
	bl	_outb_p
LBB0_28:
	mov	x0, x21
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpAdd	Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpAdd	Lloh63, Lloh64
	.loh AdrpLdrGot	Lloh65, Lloh66
	.loh AdrpAdd	Lloh70, Lloh71
	.loh AdrpLdrGotLdr	Lloh67, Lloh68, Lloh69
	.loh AdrpAdd	Lloh81, Lloh82
	.loh AdrpLdrGotLdr	Lloh78, Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpLdrGotLdr	Lloh72, Lloh73, Lloh74
	.loh AdrpLdrGotLdr	Lloh83, Lloh84, Lloh85
	.loh AdrpLdrGot	Lloh86, Lloh87
	.loh AdrpLdrGot	Lloh88, Lloh89
	.loh AdrpLdrGotLdr	Lloh90, Lloh91, Lloh92
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Transaction (pre): STS=%02x, TYP=%02x, CMD=%02x, ADD=%02x, DAT0=%02x, DAT1=%02x\n"

	.comm	_SMBHSTSTS,4,2                  ; @SMBHSTSTS
	.comm	_SMBHSTTYP,4,2                  ; @SMBHSTTYP
	.comm	_SMBHSTCMD,4,2                  ; @SMBHSTCMD
	.comm	_SMBHSTADD,4,2                  ; @SMBHSTADD
	.comm	_SMBHSTDAT0,4,2                 ; @SMBHSTDAT0
	.comm	_SMBHSTDAT1,4,2                 ; @SMBHSTDAT1
	.comm	_ALI1535_STS_BUSY,4,2           ; @ALI1535_STS_BUSY
l_.str.1:                               ; @.str.1
	.asciz	"Resetting entire SMB Bus to clear busy condition (%02x)\n"

	.comm	_ALI1535_T_OUT,4,2              ; @ALI1535_T_OUT
	.comm	_ALI1535_STS_ERR,4,2            ; @ALI1535_STS_ERR
l_.str.2:                               ; @.str.2
	.asciz	"SMBus reset failed! (0x%02x) - controller or device on bus is probably hung\n"

	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_ALI1535_STS_DONE,4,2           ; @ALI1535_STS_DONE
	.comm	_SMBHSTPORT,4,2                 ; @SMBHSTPORT
	.comm	_ALI1535_STS_IDLE,4,2           ; @ALI1535_STS_IDLE
	.comm	_MAX_TIMEOUT,4,2                ; @MAX_TIMEOUT
	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
l_.str.3:                               ; @.str.3
	.asciz	"SMBus Timeout!\n"

	.comm	_ALI1535_STS_FAIL,4,2           ; @ALI1535_STS_FAIL
	.comm	_EIO,4,2                        ; @EIO
l_.str.4:                               ; @.str.4
	.asciz	"Error: Failed bus transaction\n"

	.comm	_ALI1535_STS_BUSERR,4,2         ; @ALI1535_STS_BUSERR
	.comm	_ENXIO,4,2                      ; @ENXIO
l_.str.5:                               ; @.str.5
	.asciz	"Error: no response or bus collision ADD=%02x\n"

	.comm	_ALI1535_STS_DEV,4,2            ; @ALI1535_STS_DEV
l_.str.6:                               ; @.str.6
	.asciz	"Error: device error\n"

l_.str.7:                               ; @.str.7
	.asciz	"Error: command never completed\n"

l_.str.8:                               ; @.str.8
	.asciz	"Transaction (post): STS=%02x, TYP=%02x, CMD=%02x, ADD=%02x, DAT0=%02x, DAT1=%02x\n"

	.comm	_ALI1535_KILL,4,2               ; @ALI1535_KILL
	.no_dead_strip	_ali1535_transaction
.subsections_via_symbols
