	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cypress_load_firmware          ## -- Begin function cypress_load_firmware
	.p2align	4, 0x90
_cypress_load_firmware:                 ## @cypress_load_firmware
	.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	%edx, %ebx
	movq	%rsi, %r12
	movq	%rdi, %r14
	movl	$0, -44(%rbp)
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	(%rax), %rdx
	movl	$1, (%rdx)
	movq	_cypress@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%ebx, %rbx
	movl	(%rax,%rbx,4), %esi
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_usb_cypress_writemem
	cmpl	$1, %eax
	jne	LBB0_15
## %bb.3:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	leaq	-44(%rbp), %r13
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rdi
	movq	%r15, %rsi
	movq	%r13, %rdx
	callq	_cypress_get_hexline
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	je	LBB0_10
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	12(%r15), %esi
	movq	(%r15), %rdx
	movl	8(%r15), %ecx
	movq	%r14, %rdi
	callq	_usb_cypress_writemem
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_13
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	8(%r15), %r8d
	cmpl	%r8d, %ebx
	je	LBB0_4
## %bb.9:
	movq	_KBUILD_MODNAME@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.1(%rip), %rsi
	xorl	%r12d, %r12d
	movq	%r14, %rdi
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	movl	%r12d, %ebx
	jmp	LBB0_13
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_14
LBB0_15:
	movq	_KBUILD_MODNAME@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	leaq	L_.str(%rip), %rsi
LBB0_12:
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_13:
	movq	%r15, %rdi
	callq	_kfree
LBB0_14:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movl	%eax, %ebx
	jmp	LBB0_13
LBB0_10:
	movq	(%r15), %rdx
	movl	$0, (%rdx)
	movq	_cypress@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rax,%rcx,4), %esi
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_usb_cypress_writemem
	xorl	%ebx, %ebx
	cmpl	$1, %eax
	je	LBB0_13
## %bb.11:
	movq	_KBUILD_MODNAME@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_cypress,8,3                    ## @cypress
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: CPU stop failed=%d\n"

	.comm	_KBUILD_MODNAME,4,2             ## @KBUILD_MODNAME
	.comm	_EIO,4,2                        ## @EIO
L_.str.1:                               ## @.str.1
	.asciz	"%s: error while transferring firmware (transferred size=%d, block size=%d)\n"

L_.str.2:                               ## @.str.2
	.asciz	"%s: CPU start failed=%d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cypress_load_firmware          ; -- Begin function cypress_load_firmware
	.p2align	2
_cypress_load_firmware:                 ; @cypress_load_firmware
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x22, x2
	mov	x21, x1
	mov	x20, x0
	str	wzr, [sp, #12]
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kmalloc
	cbz	x0, LBB0_8
; %bb.1:
	mov	x19, x0
	ldr	x2, [x0]
	mov	w8, #1
	str	w8, [x2]
Lloh3:
	adrp	x23, _cypress@GOTPAGE
Lloh4:
	ldr	x23, [x23, _cypress@GOTPAGEOFF]
	ldr	x8, [x23]
	ldr	w1, [x8, w22, sxtw #2]
	mov	x0, x20
	mov	w3, #1
	bl	_usb_cypress_writemem
	cmp	w0, #1
	b.ne	LBB0_9
; %bb.2:
	sxtw	x24, w22
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	x2, sp, #12
	mov	x0, x21
	mov	x1, x19
	bl	_cypress_get_hexline
	mov	x22, x0
	tbnz	w0, #31, LBB0_12
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	cbz	w22, LBB0_14
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x2, [x19]
	ldp	w3, w1, [x19, #8]
	mov	x0, x20
	bl	_usb_cypress_writemem
	mov	x22, x0
	tbnz	w0, #31, LBB0_12
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x19, #8]
	cmp	w22, w8
	b.eq	LBB0_3
; %bb.7:
Lloh5:
	adrp	x9, _KBUILD_MODNAME@GOTPAGE
Lloh6:
	ldr	x9, [x9, _KBUILD_MODNAME@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x9]
	str	x8, [sp]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x3, x22
	b	LBB0_11
LBB0_8:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_13
LBB0_9:
	mov	x3, x0
Lloh13:
	adrp	x8, _KBUILD_MODNAME@GOTPAGE
Lloh14:
	ldr	x8, [x8, _KBUILD_MODNAME@GOTPAGEOFF]
Lloh15:
	ldr	w2, [x8]
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
LBB0_10:
	mov	x0, x20
LBB0_11:
	bl	_dev_err
Lloh18:
	adrp	x8, _EIO@GOTPAGE
Lloh19:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_12:
	mov	x0, x19
	bl	_kfree
LBB0_13:
	mov	x0, x22
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_14:
	ldr	x2, [x19]
	str	wzr, [x2]
	ldr	x8, [x23]
	ldr	w1, [x8, x24, lsl #2]
	mov	x0, x20
	mov	w3, #1
	bl	_usb_cypress_writemem
	cmp	w0, #1
	b.eq	LBB0_12
; %bb.15:
	mov	x3, x0
Lloh21:
	adrp	x8, _KBUILD_MODNAME@GOTPAGE
Lloh22:
	ldr	x8, [x8, _KBUILD_MODNAME@GOTPAGEOFF]
Lloh23:
	ldr	w2, [x8]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_cypress,8,3                    ; @cypress
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: CPU stop failed=%d\n"

	.comm	_KBUILD_MODNAME,4,2             ; @KBUILD_MODNAME
	.comm	_EIO,4,2                        ; @EIO
l_.str.1:                               ; @.str.1
	.asciz	"%s: error while transferring firmware (transferred size=%d, block size=%d)\n"

l_.str.2:                               ; @.str.2
	.asciz	"%s: CPU start failed=%d\n"

.subsections_via_symbols
