	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_initdevice                     ## -- Begin function initdevice
	.p2align	4, 0x90
_initdevice:                            ## @initdevice
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_PF_RAW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SOCK_RAW@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_RAWPROTO_DRAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_socket
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	%eax, %ebx
	leaq	-40(%rbp), %r15
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$12, %edx
	callq	_memset
	movq	_AF_RAW@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -32(%rbp)
	movq	_ETHERTYPE_IP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -36(%rbp)
	movl	-40(%rbp), %edi
	movq	%r14, %rsi
	movl	$4, %edx
	callq	_strncpy
	movl	%ebx, %edi
	movq	%r15, %rsi
	movl	$12, %edx
	callq	_bind
	testq	%rax, %rax
	js	LBB0_3
LBB0_5:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_perror
	jmp	LBB0_4
LBB0_3:
	leaq	L_.str.1(%rip), %rdi
	callq	_perror
	movl	%ebx, %edi
	callq	_close
LBB0_4:
	movl	$-1, %ebx
	jmp	LBB0_5
	.cfi_endproc
                                        ## -- End function
	.comm	_PF_RAW,4,2                     ## @PF_RAW
	.comm	_SOCK_RAW,4,2                   ## @SOCK_RAW
	.comm	_RAWPROTO_DRAIN,4,2             ## @RAWPROTO_DRAIN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"socket(PF_RAW, SOCK_RAW, RAWPROTO_DRAIN)"

	.comm	_AF_RAW,4,2                     ## @AF_RAW
	.comm	_ETHERTYPE_IP,4,2               ## @ETHERTYPE_IP
L_.str.1:                               ## @.str.1
	.asciz	"bind AF_RAW"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_initdevice                     ; -- Begin function initdevice
	.p2align	2
_initdevice:                            ; @initdevice
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x20, x0
Lloh0:
	adrp	x8, _PF_RAW@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PF_RAW@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SOCK_RAW@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SOCK_RAW@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _RAWPROTO_DRAIN@GOTPAGE
Lloh7:
	ldr	x8, [x8, _RAWPROTO_DRAIN@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	bl	_socket
	tbnz	w0, #31, LBB0_3
; %bb.1:
	mov	x19, x0
	mov	x0, sp
	mov	w1, #0
	mov	w2, #12
	bl	_memset
Lloh9:
	adrp	x8, _AF_RAW@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AF_RAW@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _ETHERTYPE_IP@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ETHERTYPE_IP@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	stp	w9, w8, [sp, #4]
	ldr	w0, [sp]
	mov	x1, x20
	mov	w2, #4
	bl	_strncpy
	mov	x1, sp
	mov	x0, x19
	mov	w2, #12
	bl	_bind
	tbnz	x0, #63, LBB0_4
LBB0_2:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_3:
Lloh15:
	adrp	x0, l_.str@PAGE
Lloh16:
	add	x0, x0, l_.str@PAGEOFF
	bl	_perror
	b	LBB0_5
LBB0_4:
Lloh17:
	adrp	x0, l_.str.1@PAGE
Lloh18:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_perror
	mov	x0, x19
	bl	_close
LBB0_5:
	mov	w19, #-1
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_PF_RAW,4,2                     ; @PF_RAW
	.comm	_SOCK_RAW,4,2                   ; @SOCK_RAW
	.comm	_RAWPROTO_DRAIN,4,2             ; @RAWPROTO_DRAIN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"socket(PF_RAW, SOCK_RAW, RAWPROTO_DRAIN)"

	.comm	_AF_RAW,4,2                     ; @AF_RAW
	.comm	_ETHERTYPE_IP,4,2               ; @ETHERTYPE_IP
l_.str.1:                               ; @.str.1
	.asciz	"bind AF_RAW"

.subsections_via_symbols
