	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function piix4_add_adapter
_piix4_add_adapter:                     ## @piix4_add_adapter
	.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
	movl	%r9d, -48(%rbp)                 ## 4-byte Spill
	movl	%r8d, -52(%rbp)                 ## 4-byte Spill
	movl	%ecx, %r15d
	movl	%edx, %r14d
	movl	%esi, %ebx
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movl	$48, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %r12
	movq	_THIS_MODULE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%r12)
	movq	_I2C_CLASS_HWMON@GOTPCREL(%rip), %rax
	movq	_I2C_CLASS_SPD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, (%r12)
	testl	%r14d, %r14d
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	jne	LBB0_4
## %bb.5:
	movq	_smbus_algorithm@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_1:
	movq	_SMBIOSIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzwl	%bx, %edi
	jmp	LBB0_2
LBB0_4:
	movq	_piix4_smbus_algorithm_sb800@GOTPCREL(%rip), %rax
LBB0_6:
	movq	%rax, 32(%r12)
	movl	(%r13), %esi
	movl	$48, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %r13
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movw	%ax, 4(%r13)
	movl	%r14d, 8(%r13)
	movq	_piix4_port_shift_sb800@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %r15d
	movl	%r15d, 12(%r13)
	movl	-52(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 16(%r13)
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, 24(%r12)
	movq	%rbx, %rdi
	callq	_has_acpi_companion
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movq	%r12, %r14
	addq	$24, %r14
	movq	%rbx, %rdi
	callq	_ACPI_COMPANION
	movq	%r14, %rdi
	movl	%eax, %esi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	callq	_acpi_preset_companion
LBB0_10:
	movl	20(%r12), %edi
	movzwl	-44(%rbp), %r14d                ## 2-byte Folded Reload
	leaq	L_.str(%rip), %rdx
	movl	$4, %esi
	movq	16(%rbp), %rcx
	movl	%r14d, %r8d
	callq	_snprintf
	movq	%r12, %rdi
	movq	%r13, %rsi
	callq	_i2c_set_adapdata
	movq	%r12, %rdi
	callq	_i2c_add_adapter
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_kfree
	movq	%r12, %rdi
	callq	_kfree
	movq	_SMBIOSIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edi
	callq	_release_region
	jmp	LBB0_13
LBB0_7:
	movq	%r12, %rdi
	callq	_kfree
	movq	_SMBIOSIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movzwl	-44(%rbp), %edi                 ## 2-byte Folded Reload
LBB0_2:
	callq	_release_region
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_13
LBB0_12:
	movq	24(%rbp), %rax
	movq	%r12, (%rax)
	xorl	%ebx, %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_SMBIOSIZE,4,2                  ## @SMBIOSIZE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_THIS_MODULE,4,2                ## @THIS_MODULE
	.comm	_I2C_CLASS_HWMON,4,2            ## @I2C_CLASS_HWMON
	.comm	_I2C_CLASS_SPD,4,2              ## @I2C_CLASS_SPD
	.comm	_piix4_smbus_algorithm_sb800,4,2 ## @piix4_smbus_algorithm_sb800
	.comm	_smbus_algorithm,4,2            ## @smbus_algorithm
	.comm	_piix4_port_shift_sb800,4,2     ## @piix4_port_shift_sb800
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SMBus PIIX4 adapter%s at %04x"

	.no_dead_strip	_piix4_add_adapter
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function piix4_add_adapter
_piix4_add_adapter:                     ; @piix4_add_adapter
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x20, x7
	mov	x22, x6
	mov	x23, x5
	mov	x26, x4
	mov	x27, x3
	mov	x28, x2
	mov	x19, x1
	mov	x25, x0
Lloh0:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	w0, #48
	bl	_kzalloc
	cbz	x0, LBB0_7
; %bb.1:
	mov	x21, x0
Lloh2:
	adrp	x8, _THIS_MODULE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _THIS_MODULE@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x0, #40]
Lloh5:
	adrp	x8, _I2C_CLASS_HWMON@GOTPAGE
Lloh6:
	ldr	x8, [x8, _I2C_CLASS_HWMON@GOTPAGEOFF]
Lloh7:
	adrp	x9, _I2C_CLASS_SPD@GOTPAGE
Lloh8:
	ldr	x9, [x9, _I2C_CLASS_SPD@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
Lloh10:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x0]
Lloh11:
	adrp	x8, _piix4_smbus_algorithm_sb800@GOTPAGE
Lloh12:
	ldr	x8, [x8, _piix4_smbus_algorithm_sb800@GOTPAGEOFF]
Lloh13:
	adrp	x9, _smbus_algorithm@GOTPAGE
Lloh14:
	ldr	x9, [x9, _smbus_algorithm@GOTPAGEOFF]
	cmp	w28, #0
	csel	x8, x9, x8, eq
	str	x8, [x0, #32]
	ldr	w1, [x24]
	mov	w0, #48
	bl	_kzalloc
	cbz	x0, LBB0_6
; %bb.2:
	mov	x24, x0
	strh	w19, [x0, #4]
Lloh15:
	adrp	x8, _piix4_port_shift_sb800@GOTPAGE
Lloh16:
	ldr	x8, [x8, _piix4_port_shift_sb800@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	lsl	w8, w27, w8
	stp	w28, w8, [x0, #8]
	str	w26, [x0, #16]
	mov	x26, x21
	str	x25, [x26, #24]!
	mov	x0, x25
	bl	_has_acpi_companion
	cbz	x0, LBB0_4
; %bb.3:
	mov	x0, x25
	bl	_ACPI_COMPANION
	mov	x1, x0
	mov	x0, x26
	mov	x2, x23
	bl	_acpi_preset_companion
LBB0_4:
	ldr	w0, [x21, #20]
Lloh18:
	adrp	x2, l_.str@PAGE
Lloh19:
	add	x2, x2, l_.str@PAGEOFF
	mov	w1, #4
	mov	x3, x22
	mov	x4, x19
	bl	_snprintf
	mov	x0, x21
	mov	x1, x24
	bl	_i2c_set_adapdata
	mov	x0, x21
	bl	_i2c_add_adapter
	mov	x22, x0
	cbz	w0, LBB0_8
; %bb.5:
	mov	x0, x24
	bl	_kfree
	mov	x0, x21
	bl	_kfree
Lloh20:
	adrp	x8, _SMBIOSIZE@GOTPAGE
Lloh21:
	ldr	x8, [x8, _SMBIOSIZE@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_release_region
	b	LBB0_9
LBB0_6:
	mov	x0, x21
	bl	_kfree
LBB0_7:
Lloh23:
	adrp	x8, _SMBIOSIZE@GOTPAGE
Lloh24:
	ldr	x8, [x8, _SMBIOSIZE@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_release_region
Lloh26:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_9
LBB0_8:
	str	x21, [x20]
LBB0_9:
	mov	x0, x22
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh9
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_SMBIOSIZE,4,2                  ; @SMBIOSIZE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_THIS_MODULE,4,2                ; @THIS_MODULE
	.comm	_I2C_CLASS_HWMON,4,2            ; @I2C_CLASS_HWMON
	.comm	_I2C_CLASS_SPD,4,2              ; @I2C_CLASS_SPD
	.comm	_piix4_smbus_algorithm_sb800,4,2 ; @piix4_smbus_algorithm_sb800
	.comm	_smbus_algorithm,4,2            ; @smbus_algorithm
	.comm	_piix4_port_shift_sb800,4,2     ; @piix4_port_shift_sb800
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SMBus PIIX4 adapter%s at %04x"

	.no_dead_strip	_piix4_add_adapter
.subsections_via_symbols
