	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function c4iw_mmap
_c4iw_mmap:                             ## @c4iw_mmap
	.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	%rsi, %r13
	movq	%rdi, %r15
	movl	(%rsi), %r14d
	movl	8(%rsi), %esi
	subl	4(%r13), %r14d
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	%esi, %ebx
	shll	%cl, %ebx
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %edx
	movl	%r14d, %ecx
	callq	_pr_debug
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	decl	%eax
	testl	%eax, 4(%r13)
	je	LBB0_2
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movl	(%r15), %edi
	callq	_to_c4iw_dev
	movq	%rax, %r12
	movq	%r15, %rdi
	callq	_to_c4iw_ucontext
	movq	%rax, %rdi
	movl	%ebx, %esi
	movl	%r14d, %edx
	callq	_remove_mmap
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movl	(%rax), %r15d
	movq	%rax, %rdi
	callq	_kfree
	movl	8(%r12), %edi
	xorl	%esi, %esi
	callq	_pci_resource_start
	cmpl	%eax, %r15d
	jl	LBB0_6
## %bb.4:
	movl	8(%r12), %edi
	xorl	%esi, %esi
	callq	_pci_resource_start
	movl	%eax, %ebx
	movl	8(%r12), %edi
	xorl	%esi, %esi
	callq	_pci_resource_len
	addl	%ebx, %eax
	cmpl	%eax, %r15d
	jge	LBB0_6
## %bb.5:
	movq	16(%r13), %rdi
	callq	_pgprot_noncached
	movq	%rax, 16(%r13)
	movl	4(%r13), %esi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	jmp	LBB0_15
LBB0_6:
	movl	8(%r12), %edi
	movl	$2, %esi
	callq	_pci_resource_start
	cmpl	%eax, %r15d
	jl	LBB0_11
## %bb.7:
	movl	8(%r12), %edi
	movl	$2, %esi
	callq	_pci_resource_start
	movl	%eax, %ebx
	movl	8(%r12), %edi
	movl	$2, %esi
	callq	_pci_resource_len
	addl	%ebx, %eax
	cmpl	%eax, %r15d
	jge	LBB0_11
## %bb.8:
	cmpl	(%r12), %r15d
	jge	LBB0_12
## %bb.9:
	movl	4(%r12), %edi
	callq	_is_t4
	movq	16(%r13), %rdi
	testl	%eax, %eax
	je	LBB0_13
## %bb.10:
	callq	_pgprot_noncached
	jmp	LBB0_14
LBB0_11:
	movl	4(%r13), %esi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %r15d
	movq	16(%r13), %r8
	movq	%r13, %rdi
	movl	%r15d, %edx
	movl	%r14d, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_remap_pfn_range                ## TAILCALL
LBB0_12:
	movq	16(%r13), %rdi
LBB0_13:
	callq	_t4_pgprot_wc
LBB0_14:
	movq	%rax, 16(%r13)
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movl	4(%r13), %esi
LBB0_15:
	movb	(%rcx), %cl
	sarl	%cl, %r15d
	movq	%r13, %rdi
	movl	%r15d, %edx
	movl	%r14d, %ecx
	movq	%rax, %r8
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_io_remap_pfn_range             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pgoff 0x%lx key 0x%x len %d\n"

	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_c4iw_mmap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function c4iw_mmap
_c4iw_mmap:                             ; @c4iw_mmap
	.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	x20, x1
	mov	x22, x0
	ldp	w8, w9, [x1]
	sub	w19, w8, w9
	ldr	w1, [x1, #8]
Lloh0:
	adrp	x24, _PAGE_SHIFT@GOTPAGE
Lloh1:
	ldr	x24, [x24, _PAGE_SHIFT@GOTPAGEOFF]
	ldr	w8, [x24]
	lsl	w23, w1, w8
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x23
	mov	x3, x19
	bl	_pr_debug
	ldr	w8, [x20, #4]
Lloh4:
	adrp	x9, _PAGE_SIZE@GOTPAGE
Lloh5:
	ldr	x9, [x9, _PAGE_SIZE@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	sub	w9, w9, #1
	tst	w9, w8
	b.eq	LBB0_2
LBB0_1:
Lloh7:
	adrp	x8, _EINVAL@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w0, w8
	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
LBB0_2:
	ldr	w0, [x22]
	bl	_to_c4iw_dev
	mov	x21, x0
	mov	x0, x22
	bl	_to_c4iw_ucontext
	mov	x1, x23
	mov	x2, x19
	bl	_remove_mmap
	cbz	x0, LBB0_1
; %bb.3:
	ldr	w23, [x0]
	bl	_kfree
	ldr	w0, [x21, #8]
	mov	w1, #0
	bl	_pci_resource_start
	cmp	w23, w0
	b.lt	LBB0_7
; %bb.4:
	ldr	w0, [x21, #8]
	mov	w1, #0
	bl	_pci_resource_start
	mov	x22, x0
	ldr	w0, [x21, #8]
	mov	w1, #0
	bl	_pci_resource_len
	add	w8, w0, w22
	cmp	w23, w8
	b.ge	LBB0_7
; %bb.5:
	ldr	x0, [x20, #16]
LBB0_6:
	bl	_pgprot_noncached
	b	LBB0_14
LBB0_7:
	ldr	w0, [x21, #8]
	mov	w1, #2
	bl	_pci_resource_start
	cmp	w23, w0
	b.lt	LBB0_11
; %bb.8:
	ldr	w0, [x21, #8]
	mov	w1, #2
	bl	_pci_resource_start
	mov	x22, x0
	ldr	w0, [x21, #8]
	mov	w1, #2
	bl	_pci_resource_len
	add	w8, w0, w22
	cmp	w23, w8
	b.ge	LBB0_11
; %bb.9:
	ldr	w8, [x21]
	cmp	w23, w8
	b.ge	LBB0_12
; %bb.10:
	ldr	w0, [x21, #4]
	bl	_is_t4
	mov	x8, x0
	ldr	x0, [x20, #16]
	cbnz	w8, LBB0_6
	b	LBB0_13
LBB0_11:
	ldr	w1, [x20, #4]
	ldr	w8, [x24]
	asr	w2, w23, w8
	ldr	x4, [x20, #16]
	mov	x0, x20
	mov	x3, x19
	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
	b	_remap_pfn_range
LBB0_12:
	ldr	x0, [x20, #16]
LBB0_13:
	bl	_t4_pgprot_wc
LBB0_14:
	mov	x4, x0
	str	x0, [x20, #16]
	ldr	w1, [x20, #4]
	ldr	w8, [x24]
	asr	w2, w23, w8
	mov	x0, x20
	mov	x3, x19
	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
	b	_io_remap_pfn_range
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pgoff 0x%lx key 0x%x len %d\n"

	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_c4iw_mmap
.subsections_via_symbols
