	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hdlc_ioctl                     ## -- Begin function hdlc_ioctl
	.p2align	4, 0x90
_hdlc_ioctl:                            ## @hdlc_ioctl
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_SIOCWANDEV@GOTPCREL(%rip), %rax
	cmpl	%edx, (%rax)
	jne	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	_first_proto@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	callq	_dev_to_hdlc
	cmpq	$0, (%rax)
	je	LBB0_4
## %bb.3:
	movq	%r15, %rdi
	callq	_dev_to_hdlc
	movq	(%rax), %rax
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	*(%rax)
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	movl	%eax, %edx
	addl	(%rcx), %edx
	jne	LBB0_9
LBB0_4:
	testq	%rbx, %rbx
	je	LBB0_1
## %bb.5:
	movq	_EINVAL@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	*(%rbx)
	movl	%eax, %ecx
	xorl	%eax, %eax
	subl	(%r12), %eax
	cmpl	%eax, %ecx
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	8(%rbx), %rbx
	testq	%rbx, %rbx
	jne	LBB0_6
	jmp	LBB0_9
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movl	%ecx, %eax
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_first_proto,8,3                ## @first_proto
	.comm	_SIOCWANDEV,4,2                 ## @SIOCWANDEV
	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hdlc_ioctl                     ; -- Begin function hdlc_ioctl
	.p2align	2
_hdlc_ioctl:                            ; @hdlc_ioctl
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x8, _SIOCWANDEV@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SIOCWANDEV@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w2
	b.ne	LBB0_7
; %bb.1:
	mov	x19, x1
	mov	x20, x0
Lloh3:
	adrp	x8, _first_proto@GOTPAGE
Lloh4:
	ldr	x8, [x8, _first_proto@GOTPAGEOFF]
Lloh5:
	ldr	x21, [x8]
	bl	_dev_to_hdlc
	ldr	x8, [x0]
	cbz	x8, LBB0_3
; %bb.2:
	mov	x0, x20
	bl	_dev_to_hdlc
	ldr	x8, [x0]
	ldr	x8, [x8]
	mov	x0, x20
	mov	x1, x19
	blr	x8
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmn	w0, w8
	b.ne	LBB0_9
LBB0_3:
	cbz	x21, LBB0_7
; %bb.4:
Lloh9:
	adrp	x22, _EINVAL@GOTPAGE
Lloh10:
	ldr	x22, [x22, _EINVAL@GOTPAGEOFF]
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	mov	x0, x20
	mov	x1, x19
	blr	x8
	ldr	w8, [x22]
	cmn	w0, w8
	b.ne	LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x21, [x21, #8]
	cbnz	x21, LBB0_5
	b	LBB0_8
LBB0_7:
Lloh11:
	adrp	x8, _EINVAL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
LBB0_8:
	neg	w0, w8
LBB0_9:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_first_proto,8,3                ; @first_proto
	.comm	_SIOCWANDEV,4,2                 ; @SIOCWANDEV
	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
