	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipxitf_demux_socket
_ipxitf_demux_socket:                   ## @ipxitf_demux_socket
	.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	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	%rsi, %rdi
	callq	_ipx_hdr
	movq	%rax, %rbx
	movq	_ipx_primary_net@GOTPCREL(%rip), %r13
	cmpq	%r12, (%r13)
	jne	LBB0_3
## %bb.1:
	movl	(%rbx), %edi
	callq	_ntohs
	cmpl	$1105, %eax                     ## imm = 0x451
	jne	LBB0_3
## %bb.2:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_ncp_connection_hack
	movq	%rax, %r14
	testq	%rax, %rax
	jne	LBB0_4
LBB0_3:
	movl	(%rbx), %esi
	movq	%r12, %rdi
	callq	_ipxitf_find_socket
	movq	%rax, %r14
LBB0_4:
	movq	(%r13), %rax
	xorl	%r13d, %r13d
	testq	%rax, %rax
	je	LBB0_9
## %bb.5:
	cmpq	%r12, %rax
	je	LBB0_9
## %bb.6:
	movl	(%rbx), %edi
	callq	_ntohs
	xorl	%r13d, %r13d
	addl	$-1106, %eax                    ## imm = 0xFBAE
	cmpl	$4, %eax
	ja	LBB0_9
## %bb.7:
	movl	$19, %ecx
	btl	%eax, %ecx
	jae	LBB0_9
## %bb.8:
	movq	_ipx_primary_net@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movl	(%rbx), %esi
	callq	_ipxitf_find_socket
	movq	%rax, %r13
LBB0_9:
	movq	%r14, %rax
	orq	%r13, %rax
	je	LBB0_10
## %bb.12:
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_14
## %bb.13:
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_skb_clone
	movq	%rax, %r15
LBB0_14:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	testq	%r15, %r15
	je	LBB0_15
## %bb.16:
	movq	%r15, %rax
	testq	%r14, %r14
	je	LBB0_19
## %bb.17:
	movq	%r15, %rax
	testq	%r13, %r13
	je	LBB0_19
## %bb.18:
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_skb_clone
LBB0_19:
	testq	%r14, %r14
	je	LBB0_21
## %bb.20:
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rax, %rbx
	callq	_ipxitf_def_skb_handler
	movq	%rbx, %rax
LBB0_21:
	xorl	%ebx, %ebx
	testq	%rax, %rax
	cmovel	%r12d, %ebx
	je	LBB0_24
## %bb.22:
	testq	%r13, %r13
	je	LBB0_24
## %bb.23:
	movq	%r13, %rdi
	movq	%rax, %rsi
	callq	_ipxitf_def_skb_handler
	xorl	%ebx, %ebx
LBB0_24:
	testq	%r14, %r14
	je	LBB0_26
LBB0_25:
	movq	%r14, %rdi
	callq	_sock_put
LBB0_26:
	testq	%r13, %r13
	je	LBB0_28
## %bb.27:
	movq	%r13, %rdi
	callq	_sock_put
	jmp	LBB0_28
LBB0_10:
	xorl	%ebx, %ebx
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_28
## %bb.11:
	movq	%r15, %rdi
	callq	_kfree_skb
LBB0_28:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	movl	%r12d, %ebx
	testq	%r14, %r14
	jne	LBB0_25
	jmp	LBB0_26
	.cfi_endproc
                                        ## -- End function
	.comm	_ipx_primary_net,8,3            ## @ipx_primary_net
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_ipxitf_demux_socket
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipxitf_demux_socket
_ipxitf_demux_socket:                   ; @ipxitf_demux_socket
	.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	x22, x2
	mov	x19, x1
	mov	x23, x0
	mov	x0, x1
	bl	_ipx_hdr
	mov	x21, x0
Lloh0:
	adrp	x24, _ipx_primary_net@GOTPAGE
Lloh1:
	ldr	x24, [x24, _ipx_primary_net@GOTPAGEOFF]
	ldr	x8, [x24]
	cmp	x8, x23
	b.ne	LBB0_3
; %bb.1:
	ldr	w0, [x21]
	bl	_ntohs
	cmp	w0, #1105
	b.ne	LBB0_3
; %bb.2:
	mov	x0, x23
	mov	x1, x21
	bl	_ncp_connection_hack
	mov	x20, x0
	cbnz	x0, LBB0_4
LBB0_3:
	ldr	w1, [x21]
	mov	x0, x23
	bl	_ipxitf_find_socket
	mov	x20, x0
LBB0_4:
	ldr	x8, [x24]
	cmp	x8, #0
	ccmp	x8, x23, #4, ne
	b.ne	LBB0_21
LBB0_5:
	mov	x21, #0
	orr	x8, x20, x21
	cbz	x8, LBB0_23
LBB0_6:
	cbz	w22, LBB0_8
; %bb.7:
Lloh2:
	adrp	x8, _GFP_ATOMIC@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_ATOMIC@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_skb_clone
	mov	x19, x0
LBB0_8:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w22, w8
	cbz	x19, LBB0_17
; %bb.9:
	mov	x23, x19
	cbz	x20, LBB0_12
; %bb.10:
	mov	x23, x19
	cbz	x21, LBB0_12
; %bb.11:
Lloh8:
	adrp	x8, _GFP_ATOMIC@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GFP_ATOMIC@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_skb_clone
	mov	x23, x0
LBB0_12:
	cbz	x20, LBB0_14
; %bb.13:
	mov	x0, x20
	mov	x1, x19
	bl	_ipxitf_def_skb_handler
LBB0_14:
	cmp	x23, #0
	csel	w22, w22, wzr, eq
	cbz	x23, LBB0_17
; %bb.15:
	cbz	x21, LBB0_17
; %bb.16:
	mov	x0, x21
	mov	x1, x23
	bl	_ipxitf_def_skb_handler
	mov	w22, #0
LBB0_17:
	cbz	x20, LBB0_19
; %bb.18:
	mov	x0, x20
	bl	_sock_put
LBB0_19:
	cbz	x21, LBB0_26
; %bb.20:
	mov	x0, x21
	bl	_sock_put
	b	LBB0_26
LBB0_21:
	ldr	w0, [x21]
	bl	_ntohs
	sub	w8, w0, #1106
	cmp	w8, #4
	mov	w9, #1
	lsl	w8, w9, w8
	mov	w9, #19
	and	w8, w8, w9
	ccmp	w8, #0, #4, ls
	b.eq	LBB0_5
; %bb.22:
	ldr	x0, [x24]
	ldr	w1, [x21]
	bl	_ipxitf_find_socket
	mov	x21, x0
	orr	x8, x20, x21
	cbnz	x8, LBB0_6
LBB0_23:
	cbz	w22, LBB0_25
; %bb.24:
	mov	w22, #0
	b	LBB0_26
LBB0_25:
	mov	x0, x19
	bl	_kfree_skb
LBB0_26:
	mov	x0, x22
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_ipx_primary_net,8,3            ; @ipx_primary_net
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_ipxitf_demux_socket
.subsections_via_symbols
