	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lecd_attach
_lecd_attach:                           ## @lecd_attach
	.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
	xorl	%ecx, %ecx
	testl	%esi, %esi
	movl	$0, %ebx
	cmovgl	%esi, %ebx
	movq	_MAX_LEC_ITF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_NUM_TR_DEVS@GOTPCREL(%rip), %rdx
	subl	(%rdx), %eax
	cmpl	%esi, %eax
	jle	LBB0_1
## %bb.2:
	movq	%rdi, %r14
	movq	_dev_lec@GOTPCREL(%rip), %r12
	movq	(%r12), %rcx
	movl	%ebx, %r13d
	movq	(%rcx,%r13,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_3
## %bb.8:
	callq	_netdev_priv
	cmpq	$0, 56(%rax)
	je	LBB0_9
## %bb.10:
	movq	_EADDRINUSE@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ecx
	movl	%ecx, %ebx
	jmp	LBB0_15
LBB0_3:
	cmpl	%eax, %ebx
	setge	%r15b
	movl	$64, %edi
	callq	_alloc_etherdev
	movq	(%r12), %rcx
	movq	%rax, (%rcx,%r13,8)
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rax
	testq	%rax, %rax
	je	LBB0_4
## %bb.6:
	movl	4(%rax), %edi
	movq	_IFNAMSIZ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movl	%ebx, %ecx
	callq	_snprintf
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rdi
	callq	_register_netdev
	movq	(%r12), %rcx
	movq	(%rcx,%r13,8), %rdi
	testq	%rax, %rax
	je	LBB0_11
## %bb.7:
	callq	_free_netdev
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_9:
	movq	%rax, %r15
	jmp	LBB0_12
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_5:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_15
LBB0_11:
	xorl	%eax, %eax
	movb	%r15b, %al
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	callq	_netdev_priv
	movq	%rax, %r15
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%r15)
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rdi
	callq	_lec_init
LBB0_12:
	movq	%r15, %rdi
	callq	_lec_arp_init
	movl	%ebx, 4(%r15)
	movq	%r14, 56(%r15)
	movq	_lecatm_dev@GOTPCREL(%rip), %rax
	movq	%rax, 16(%r14)
	movq	%r14, %rdi
	callq	_sk_atm
	movl	%eax, %edi
	callq	_vcc_insert_socket
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rax
	movq	%rax, 8(%r14)
	movq	_ATM_VF_META@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_set_bit
	movq	_ATM_VF_READY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_set_bit
	movl	$1, 8(%r15)
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r15)
	imull	$1200, %eax, %ecx               ## imm = 0x4B0
	movl	%ecx, 16(%r15)
	movl	$1, 20(%r15)
	imull	$300, %eax, %ecx                ## imm = 0x12C
	movl	%ecx, 24(%r15)
	leal	(%rax,%rax,4), %ecx
	leal	(%rcx,%rcx,2), %ecx
	movl	%ecx, 28(%r15)
	movq	$0, 48(%r15)
	movl	%eax, 32(%r15)
	leal	(,%rax,4), %ecx
	movl	%ecx, 36(%r15)
	addl	%eax, %eax
	leal	(%rax,%rax,2), %eax
	movl	%eax, 40(%r15)
	movq	(%r12), %rax
	movq	(%rax,%r13,8), %rdi
	movq	_IFF_UP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_14
## %bb.13:
	callq	_netif_start_queue
LBB0_14:
	movq	_THIS_MODULE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	___module_get
LBB0_15:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_LEC_ITF,4,2                ## @MAX_LEC_ITF
	.comm	_NUM_TR_DEVS,4,2                ## @NUM_TR_DEVS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_dev_lec,8,3                    ## @dev_lec
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_IFNAMSIZ,4,2                   ## @IFNAMSIZ
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"lec%d"

	.comm	_EADDRINUSE,4,2                 ## @EADDRINUSE
	.comm	_lecatm_dev,4,2                 ## @lecatm_dev
	.comm	_ATM_VF_META,4,2                ## @ATM_VF_META
	.comm	_ATM_VF_READY,4,2               ## @ATM_VF_READY
	.comm	_HZ,4,2                         ## @HZ
	.comm	_IFF_UP,4,2                     ## @IFF_UP
	.comm	_THIS_MODULE,4,2                ## @THIS_MODULE
	.no_dead_strip	_lecd_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function lecd_attach
lCPI0_0:
	.long	300                             ; 0x12c
	.long	15                              ; 0xf
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_lecd_attach:                           ; @lecd_attach
	.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
	cmp	w1, #0
	csel	w19, w1, wzr, gt
Lloh0:
	adrp	x8, _MAX_LEC_ITF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX_LEC_ITF@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _NUM_TR_DEVS@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NUM_TR_DEVS@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	sub	w8, w8, w9
	cmp	w8, w1
	b.le	LBB0_7
; %bb.1:
	mov	x20, x0
Lloh6:
	adrp	x22, _dev_lec@GOTPAGE
Lloh7:
	ldr	x22, [x22, _dev_lec@GOTPAGEOFF]
	ldr	x9, [x22]
	ldr	x0, [x9, w19, uxtw #3]
	cbz	x0, LBB0_4
; %bb.2:
	bl	_netdev_priv
	ldr	x8, [x0, #56]
	cbz	x8, LBB0_10
; %bb.3:
Lloh8:
	adrp	x8, _EADDRINUSE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EADDRINUSE@GOTPAGEOFF]
	b	LBB0_8
LBB0_4:
	cmp	w19, w8
	cset	w23, ge
	mov	w0, #64
	bl	_alloc_etherdev
	ldr	x8, [x22]
	lsl	x21, x19, #3
	str	x0, [x8, x21]
	ldr	x8, [x22]
	ldr	x8, [x8, x21]
	cbz	x8, LBB0_11
; %bb.5:
	ldr	w0, [x8, #4]
Lloh10:
	adrp	x8, _IFNAMSIZ@GOTPAGE
Lloh11:
	ldr	x8, [x8, _IFNAMSIZ@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
Lloh13:
	adrp	x2, l_.str@PAGE
Lloh14:
	add	x2, x2, l_.str@PAGEOFF
	mov	x3, x19
	bl	_snprintf
	ldr	x8, [x22]
	ldr	x0, [x8, x21]
	bl	_register_netdev
	mov	x8, x0
	ldr	x9, [x22]
	ldr	x0, [x9, x21]
	cbz	x8, LBB0_12
; %bb.6:
	bl	_free_netdev
LBB0_7:
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	neg	w19, w8
LBB0_9:
	mov	x0, x19
	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
LBB0_10:
	mov	x21, x0
	b	LBB0_13
LBB0_11:
Lloh17:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_8
LBB0_12:
	bl	_netdev_priv
	mov	x21, x0
	str	w23, [x0]
	ldr	x8, [x22]
	ldr	x0, [x8, x19, lsl #3]
	bl	_lec_init
LBB0_13:
	mov	x0, x21
	bl	_lec_arp_init
	str	w19, [x21, #4]
	str	x20, [x21, #56]
Lloh19:
	adrp	x8, _lecatm_dev@GOTPAGE
Lloh20:
	ldr	x8, [x8, _lecatm_dev@GOTPAGEOFF]
	str	x8, [x20, #16]
	mov	x0, x20
	bl	_sk_atm
	bl	_vcc_insert_socket
	ldr	x8, [x22]
	lsl	x23, x19, #3
	ldr	x8, [x8, x23]
	str	x8, [x20, #8]
Lloh21:
	adrp	x8, _ATM_VF_META@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ATM_VF_META@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_set_bit
Lloh24:
	adrp	x8, _ATM_VF_READY@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ATM_VF_READY@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_set_bit
	mov	w8, #1
Lloh27:
	adrp	x9, _HZ@GOTPAGE
Lloh28:
	ldr	x9, [x9, _HZ@GOTPAGEOFF]
Lloh29:
	ldr	w9, [x9]
	stp	w8, w9, [x21, #8]
	mov	w10, #1200
	mul	w10, w9, w10
	stp	w10, w8, [x21, #16]
	dup.2s	v0, w9
Lloh30:
	adrp	x8, lCPI0_0@PAGE
Lloh31:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	mul.2s	v0, v0, v1
	str	d0, [x21, #24]
	str	xzr, [x21, #48]
	lsl	w8, w9, #2
	stp	w9, w8, [x21, #32]
	add	w8, w9, w9, lsl #1
	lsl	w8, w8, #1
	ldr	x9, [x22]
	ldr	x0, [x9, x23]
	str	w8, [x21, #40]
	ldr	w8, [x0]
Lloh32:
	adrp	x9, _IFF_UP@GOTPAGE
Lloh33:
	ldr	x9, [x9, _IFF_UP@GOTPAGEOFF]
Lloh34:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_15
; %bb.14:
	bl	_netif_start_queue
LBB0_15:
Lloh35:
	adrp	x8, _THIS_MODULE@GOTPAGE
Lloh36:
	ldr	x8, [x8, _THIS_MODULE@GOTPAGEOFF]
Lloh37:
	ldr	w0, [x8]
	bl	___module_get
	b	LBB0_9
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdr	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_LEC_ITF,4,2                ; @MAX_LEC_ITF
	.comm	_NUM_TR_DEVS,4,2                ; @NUM_TR_DEVS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_dev_lec,8,3                    ; @dev_lec
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_IFNAMSIZ,4,2                   ; @IFNAMSIZ
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"lec%d"

	.comm	_EADDRINUSE,4,2                 ; @EADDRINUSE
	.comm	_lecatm_dev,4,2                 ; @lecatm_dev
	.comm	_ATM_VF_META,4,2                ; @ATM_VF_META
	.comm	_ATM_VF_READY,4,2               ; @ATM_VF_READY
	.comm	_HZ,4,2                         ; @HZ
	.comm	_IFF_UP,4,2                     ; @IFF_UP
	.comm	_THIS_MODULE,4,2                ; @THIS_MODULE
	.no_dead_strip	_lecd_attach
.subsections_via_symbols
