	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tqmx86_gpio_irq_set_type
_tqmx86_gpio_irq_set_type:              ## @tqmx86_gpio_irq_set_type
	.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
	movl	%esi, %ebx
	movq	%rdi, %r15
	callq	_irq_data_get_irq_chip_data
	movl	%eax, %edi
	callq	_gpiochip_get_data
	movq	%rax, %r14
	movl	(%r15), %r15d
	movq	_TQMX86_NGPO@GOTPCREL(%rip), %rax
	subl	(%rax), %r15d
	movq	_IRQF_TRIGGER_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	cmpl	$130, %ebx
	je	LBB0_4
## %bb.1:
	cmpl	$129, %ebx
	je	LBB0_6
## %bb.2:
	cmpl	$128, %ebx
	jne	LBB0_5
## %bb.3:
	movq	_TQMX86_GPII_RISING@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_4:
	movq	_TQMX86_GPII_FALLING@GOTPCREL(%rip), %rax
	movq	_TQMX86_GPII_RISING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	jmp	LBB0_8
LBB0_6:
	movq	_TQMX86_GPII_FALLING@GOTPCREL(%rip), %rax
LBB0_7:
	movl	(%rax), %ebx
LBB0_8:
	movq	(%r14), %rax
	movl	%r15d, %ecx
	movl	%ebx, (%rax,%rcx,4)
	movq	%r14, %r12
	addq	$8, %r12
	movq	%r12, %rdi
	callq	_raw_spin_lock_irqsave
	movq	_TQMX86_GPIIC@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	%r14, %rdi
	callq	_tqmx86_gpio_read
	movq	_TQMX86_GPII_MASK@GOTPCREL(%rip), %rcx
	movq	_TQMX86_GPII_BITS@GOTPCREL(%rip), %rdx
	imull	(%rdx), %r15d
	movl	(%rcx), %edx
	movl	%r15d, %ecx
	shll	%cl, %edx
	shll	%cl, %ebx
	notl	%edx
	andl	%eax, %edx
	orl	%edx, %ebx
	movl	(%r13), %edx
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_tqmx86_gpio_write
	movq	%r12, %rdi
	callq	_raw_spin_unlock_irqrestore
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_5:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TQMX86_NGPO,4,2                ## @TQMX86_NGPO
	.comm	_IRQF_TRIGGER_MASK,4,2          ## @IRQF_TRIGGER_MASK
	.comm	_TQMX86_GPII_RISING,4,2         ## @TQMX86_GPII_RISING
	.comm	_TQMX86_GPII_FALLING,4,2        ## @TQMX86_GPII_FALLING
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_TQMX86_GPIIC,4,2               ## @TQMX86_GPIIC
	.comm	_TQMX86_GPII_MASK,4,2           ## @TQMX86_GPII_MASK
	.comm	_TQMX86_GPII_BITS,4,2           ## @TQMX86_GPII_BITS
	.no_dead_strip	_tqmx86_gpio_irq_set_type
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tqmx86_gpio_irq_set_type
_tqmx86_gpio_irq_set_type:              ; @tqmx86_gpio_irq_set_type
	.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	x21, x0
	bl	_irq_data_get_irq_chip_data
	bl	_gpiochip_get_data
	mov	x19, x0
	ldr	w8, [x21]
Lloh0:
	adrp	x9, _TQMX86_NGPO@GOTPAGE
Lloh1:
	ldr	x9, [x9, _TQMX86_NGPO@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _IRQF_TRIGGER_MASK@GOTPAGE
Lloh4:
	ldr	x10, [x10, _IRQF_TRIGGER_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	and	w10, w10, w20
	cmp	w10, #130
	b.eq	LBB0_4
; %bb.1:
	cmp	w10, #129
	b.eq	LBB0_5
; %bb.2:
	cmp	w10, #128
	b.ne	LBB0_8
; %bb.3:
Lloh6:
	adrp	x10, _TQMX86_GPII_RISING@GOTPAGE
Lloh7:
	ldr	x10, [x10, _TQMX86_GPII_RISING@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:
Lloh8:
	adrp	x10, _TQMX86_GPII_FALLING@GOTPAGE
Lloh9:
	ldr	x10, [x10, _TQMX86_GPII_FALLING@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
Lloh11:
	adrp	x11, _TQMX86_GPII_RISING@GOTPAGE
Lloh12:
	ldr	x11, [x11, _TQMX86_GPII_RISING@GOTPAGEOFF]
Lloh13:
	ldr	w11, [x11]
	orr	w21, w11, w10
	b	LBB0_7
LBB0_5:
Lloh14:
	adrp	x10, _TQMX86_GPII_FALLING@GOTPAGE
Lloh15:
	ldr	x10, [x10, _TQMX86_GPII_FALLING@GOTPAGEOFF]
LBB0_6:
	ldr	w21, [x10]
LBB0_7:
	sub	w22, w8, w9
	mov	x20, x19
	ldr	x8, [x20], #8
	str	w21, [x8, w22, uxtw #2]
	mov	x0, x20
	bl	_raw_spin_lock_irqsave
Lloh16:
	adrp	x23, _TQMX86_GPIIC@GOTPAGE
Lloh17:
	ldr	x23, [x23, _TQMX86_GPIIC@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	x0, x19
	bl	_tqmx86_gpio_read
Lloh18:
	adrp	x8, _TQMX86_GPII_MASK@GOTPAGE
Lloh19:
	ldr	x8, [x8, _TQMX86_GPII_MASK@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
Lloh21:
	adrp	x9, _TQMX86_GPII_BITS@GOTPAGE
Lloh22:
	ldr	x9, [x9, _TQMX86_GPII_BITS@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	mul	w9, w9, w22
	lsl	w8, w8, w9
	bic	w8, w0, w8
	lsl	w9, w21, w9
	orr	w1, w8, w9
	ldr	w2, [x23]
	mov	x0, x19
	bl	_tqmx86_gpio_write
	mov	x0, x20
	bl	_raw_spin_unlock_irqrestore
	mov	w0, #0
	b	LBB0_9
LBB0_8:
Lloh24:
	adrp	x8, _EINVAL@GOTPAGE
Lloh25:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_TQMX86_NGPO,4,2                ; @TQMX86_NGPO
	.comm	_IRQF_TRIGGER_MASK,4,2          ; @IRQF_TRIGGER_MASK
	.comm	_TQMX86_GPII_RISING,4,2         ; @TQMX86_GPII_RISING
	.comm	_TQMX86_GPII_FALLING,4,2        ; @TQMX86_GPII_FALLING
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_TQMX86_GPIIC,4,2               ; @TQMX86_GPIIC
	.comm	_TQMX86_GPII_MASK,4,2           ; @TQMX86_GPII_MASK
	.comm	_TQMX86_GPII_BITS,4,2           ; @TQMX86_GPII_BITS
	.no_dead_strip	_tqmx86_gpio_irq_set_type
.subsections_via_symbols
