	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mlxsw_sp_fid_family_register
_mlxsw_sp_fid_family_register:          ## @mlxsw_sp_fid_family_register
	.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
	movq	%rsi, %r14
	movq	%rdi, %r13
	movq	40(%rsi), %r15
	movq	48(%rsi), %rbx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rsi, %rdi
	movl	$56, %esi
	callq	_kmemdup
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r12
	subq	%r15, %rbx
	incq	%rbx
	movq	%r13, 32(%rax)
	movq	%rax, %rdi
	addq	$24, %rdi
	callq	_INIT_LIST_HEAD
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bitmap_zalloc
	movl	%eax, 8(%r12)
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	cmpq	$0, 16(%r12)
	je	LBB0_6
## %bb.5:
	movq	%r12, %rdi
	callq	_mlxsw_sp_fid_flood_tables_init
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movl	%eax, %ebx
	movl	8(%r12), %edi
	callq	_bitmap_free
	jmp	LBB0_8
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_9
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_8:
	movq	%r12, %rdi
	callq	_kfree
	jmp	LBB0_9
LBB0_6:
	movq	(%r13), %rax
	movq	(%rax), %rax
	movq	(%r14), %rcx
	movq	%r12, (%rax,%rcx,8)
	xorl	%ebx, %ebx
LBB0_9:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_mlxsw_sp_fid_family_register
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mlxsw_sp_fid_family_register
_mlxsw_sp_fid_family_register:          ; @mlxsw_sp_fid_family_register
	.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
	ldp	x24, x22, [x1, #40]
Lloh0:
	adrp	x23, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x23, [x23, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w2, [x23]
	mov	x0, x1
	mov	w1, #56
	bl	_kmemdup
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
	sub	x8, x22, x24
	add	x22, x8, #1
	str	x21, [x0, #32]
	add	x0, x0, #24
	bl	_INIT_LIST_HEAD
	ldr	w1, [x23]
	mov	x0, x22
	bl	_bitmap_zalloc
	str	w0, [x19, #8]
	cbz	w0, LBB0_6
; %bb.2:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_8
; %bb.3:
	mov	x0, x19
	bl	_mlxsw_sp_fid_flood_tables_init
	cbz	w0, LBB0_8
; %bb.4:
	mov	x22, x0
	ldr	w0, [x19, #8]
	bl	_bitmap_free
	b	LBB0_7
LBB0_5:
Lloh2:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_9
LBB0_6:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_7:
	mov	x0, x19
	bl	_kfree
	b	LBB0_9
LBB0_8:
	mov	w22, #0
	ldr	x8, [x21]
	ldr	x8, [x8]
	ldr	x9, [x20]
	str	x19, [x8, x9, lsl #3]
LBB0_9:
	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
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_mlxsw_sp_fid_family_register
.subsections_via_symbols
