	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gemtek_pci_setfrequency
_gemtek_pci_setfrequency:               ## @gemtek_pci_setfrequency
	.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, %r12
	movq	%rsi, %rax
	shrq	$3, %rax
	movabsq	$2951479051793528259, %rcx      ## imm = 0x28F5C28F5C28F5C3
	mulq	%rcx
	movq	%rdx, %r15
	movq	%rdi, %rbx
	shrq	$2, %r15
	movl	(%rdi), %r13d
	leaq	16(%rdi), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	%r12, 8(%rbx)
	movl	$6, %edi
	movl	%r13d, %esi
	callq	_gemtek_pci_out
	movl	%eax, -44(%rbp)
	leaq	-44(%rbp), %r12
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	movl	%r13d, %edi
	movq	%r12, %rsi
	callq	_gemtek_pci_nil
	leal	856(%r15), %ebx
	movl	%ebx, %edi
	andl	$32768, %edi                    ## imm = 0x8000
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$16384, %edi                    ## imm = 0x4000
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$8192, %edi                     ## imm = 0x2000
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$4096, %edi                     ## imm = 0x1000
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$2048, %edi                     ## imm = 0x800
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$1024, %edi                     ## imm = 0x400
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$512, %edi                      ## imm = 0x200
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$256, %edi                      ## imm = 0x100
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$128, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$64, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$32, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%ebx, %edi
	andl	$16, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	andl	$8, %ebx
	movl	%ebx, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%r15d, %edi
	andl	$4, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	%r15d, %edi
	andl	$2, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	andl	$1, %r15d
	movl	%r15d, %edi
	movl	%r13d, %esi
	movq	%r12, %rdx
	callq	_gemtek_pci_cmd
	movl	$16, %edi
	movl	%r13d, %esi
	callq	_outw
	movq	%r14, %rdi
	callq	_mutex_unlock
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_gemtek_pci_setfrequency
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gemtek_pci_setfrequency
_gemtek_pci_setfrequency:               ; @gemtek_pci_setfrequency
	.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	x21, x1
	mov	x22, x0
	lsr	x8, x1, #3
	mov	x9, #62915
	movk	x9, #23592, lsl #16
	movk	x9, #49807, lsl #32
	movk	x9, #10485, lsl #48
	umulh	x23, x8, x9
	lsr	x24, x23, #2
	ldr	w20, [x0]
	add	x19, x0, #16
	mov	x0, x19
	bl	_mutex_lock
	str	x21, [x22, #8]
	mov	w0, #6
	mov	x1, x20
	bl	_gemtek_pci_out
	str	w0, [sp, #12]
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	x1, sp, #12
	mov	x0, x20
	bl	_gemtek_pci_nil
	add	w21, w24, #856
	and	w0, w21, #0x8000
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x4000
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x2000
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x1000
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x800
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x400
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x200
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x100
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x80
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x40
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x20
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x10
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w21, #0x8
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w24, #0x4
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	and	w0, w24, #0x2
	add	x2, sp, #12
	mov	x1, x20
	bl	_gemtek_pci_cmd
	ubfx	x0, x23, #2, #1
	add	x2, sp, #12
                                        ; kill: def $w0 killed $w0 killed $x0
	mov	x1, x20
	bl	_gemtek_pci_cmd
	mov	w0, #16
	mov	x1, x20
	bl	_outw
	mov	x0, x19
	bl	_mutex_unlock
	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
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_gemtek_pci_setfrequency
.subsections_via_symbols
