	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hns_roce_v2_mw_write_mtpt
_hns_roce_v2_mw_write_mtpt:             ## @hns_roce_v2_mw_write_mtpt
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	xorl	%r15d, %r15d
	xorl	%esi, %esi
	movl	$20, %edx
	callq	_memset
	movl	16(%rbx), %edi
	movq	_V2_MPT_BYTE_4_MPT_ST_M@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_V2_MPT_BYTE_4_MPT_ST_S@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_V2_MPT_ST_FREE@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	callq	_roce_set_field
	movl	16(%rbx), %edi
	movq	_V2_MPT_BYTE_4_PD_M@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_V2_MPT_BYTE_4_PD_S@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	(%r14), %rcx
	callq	_roce_set_field
	movl	16(%rbx), %edi
	movq	_V2_MPT_BYTE_4_PBL_HOP_NUM_M@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_V2_MPT_BYTE_4_PBL_HOP_NUM_S@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	8(%r14), %rax
	movq	_HNS_ROCE_HOP_NUM_0@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	cmovneq	%rax, %r15
	movq	%r15, %rcx
	callq	_roce_set_field
	movl	16(%rbx), %edi
	movq	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_M@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_S@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_PG_SHIFT_OFFSET@GOTPCREL(%rip), %r15
	movq	(%r15), %rcx
	addq	16(%r14), %rcx
	callq	_roce_set_field
	movl	12(%rbx), %edi
	movq	_V2_MPT_BYTE_8_R_INV_EN_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_roce_set_bit
	movl	12(%rbx), %edi
	movq	_V2_MPT_BYTE_8_L_INV_EN_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_roce_set_bit
	movl	8(%rbx), %edi
	movq	_V2_MPT_BYTE_12_PA_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_roce_set_bit
	movl	8(%rbx), %edi
	movq	_V2_MPT_BYTE_12_MR_MW_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_roce_set_bit
	movl	8(%rbx), %edi
	movq	_V2_MPT_BYTE_12_BPD_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_roce_set_bit
	movl	8(%rbx), %edi
	movq	_V2_MPT_BYTE_12_BQP_S@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	40(%r14), %rax
	movq	_IB_MW_TYPE_1@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	cmpq	(%rcx), %rax
	setne	%dl
	callq	_roce_set_bit
	movl	4(%rbx), %edi
	movq	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	(%r15), %rcx
	addq	24(%r14), %rcx
	callq	_roce_set_field
	movl	32(%r14), %edi
	callq	_cpu_to_le32
	movl	%eax, (%rbx)
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V2_MPT_BYTE_4_MPT_ST_M,4,2     ## @V2_MPT_BYTE_4_MPT_ST_M
	.comm	_V2_MPT_BYTE_4_MPT_ST_S,4,2     ## @V2_MPT_BYTE_4_MPT_ST_S
	.comm	_V2_MPT_ST_FREE,8,3             ## @V2_MPT_ST_FREE
	.comm	_V2_MPT_BYTE_4_PD_M,4,2         ## @V2_MPT_BYTE_4_PD_M
	.comm	_V2_MPT_BYTE_4_PD_S,4,2         ## @V2_MPT_BYTE_4_PD_S
	.comm	_V2_MPT_BYTE_4_PBL_HOP_NUM_M,4,2 ## @V2_MPT_BYTE_4_PBL_HOP_NUM_M
	.comm	_V2_MPT_BYTE_4_PBL_HOP_NUM_S,4,2 ## @V2_MPT_BYTE_4_PBL_HOP_NUM_S
	.comm	_HNS_ROCE_HOP_NUM_0,8,3         ## @HNS_ROCE_HOP_NUM_0
	.comm	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_M,4,2 ## @V2_MPT_BYTE_4_PBL_BA_PG_SZ_M
	.comm	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_S,4,2 ## @V2_MPT_BYTE_4_PBL_BA_PG_SZ_S
	.comm	_PG_SHIFT_OFFSET,8,3            ## @PG_SHIFT_OFFSET
	.comm	_V2_MPT_BYTE_8_R_INV_EN_S,4,2   ## @V2_MPT_BYTE_8_R_INV_EN_S
	.comm	_V2_MPT_BYTE_8_L_INV_EN_S,4,2   ## @V2_MPT_BYTE_8_L_INV_EN_S
	.comm	_V2_MPT_BYTE_12_PA_S,4,2        ## @V2_MPT_BYTE_12_PA_S
	.comm	_V2_MPT_BYTE_12_MR_MW_S,4,2     ## @V2_MPT_BYTE_12_MR_MW_S
	.comm	_V2_MPT_BYTE_12_BPD_S,4,2       ## @V2_MPT_BYTE_12_BPD_S
	.comm	_V2_MPT_BYTE_12_BQP_S,4,2       ## @V2_MPT_BYTE_12_BQP_S
	.comm	_IB_MW_TYPE_1,8,3               ## @IB_MW_TYPE_1
	.comm	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M,4,2 ## @V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M
	.comm	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S,4,2 ## @V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S
	.no_dead_strip	_hns_roce_v2_mw_write_mtpt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hns_roce_v2_mw_write_mtpt
_hns_roce_v2_mw_write_mtpt:             ; @hns_roce_v2_mw_write_mtpt
	.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
	mov	x20, x1
	mov	x19, x0
	mov	w1, #0
	mov	w2, #20
	bl	_memset
	ldr	w0, [x19, #16]
Lloh0:
	adrp	x8, _V2_MPT_BYTE_4_MPT_ST_M@GOTPAGE
Lloh1:
	ldr	x8, [x8, _V2_MPT_BYTE_4_MPT_ST_M@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _V2_MPT_BYTE_4_MPT_ST_S@GOTPAGE
Lloh4:
	ldr	x8, [x8, _V2_MPT_BYTE_4_MPT_ST_S@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x8, _V2_MPT_ST_FREE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V2_MPT_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S@GOTPAGEOFF]
Lloh29:
	ldr	w2, [x8]
	ldr	x8, [x20, #16]
Lloh30:
	adrp	x21, _PG_SHIFT_OFFSET@GOTPAGE
Lloh31:
	ldr	x21, [x21, _PG_SHIFT_OFFSET@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x3, x9, x8
	bl	_roce_set_field
	ldr	w0, [x19, #12]
Lloh32:
	adrp	x8, _V2_MPT_BYTE_8_R_INV_EN_S@GOTPAGE
Lloh33:
	ldr	x8, [x8, _V2_MPT_BYTE_8_R_INV_EN_S@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_roce_set_bit
	ldr	w0, [x19, #12]
Lloh35:
	adrp	x8, _V2_MPT_BYTE_8_L_INV_EN_S@GOTPAGE
Lloh36:
	ldr	x8, [x8, _V2_MPT_BYTE_8_L_INV_EN_S@GOTPAGEOFF]
Lloh37:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_roce_set_bit
	ldr	w0, [x19, #8]
Lloh38:
	adrp	x8, _V2_MPT_BYTE_12_PA_S@GOTPAGE
Lloh39:
	ldr	x8, [x8, _V2_MPT_BYTE_12_PA_S@GOTPAGEOFF]
Lloh40:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_roce_set_bit
	ldr	w0, [x19, #8]
Lloh41:
	adrp	x8, _V2_MPT_BYTE_12_MR_MW_S@GOTPAGE
Lloh42:
	ldr	x8, [x8, _V2_MPT_BYTE_12_MR_MW_S@GOTPAGEOFF]
Lloh43:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_roce_set_bit
	ldr	w0, [x19, #8]
Lloh44:
	adrp	x8, _V2_MPT_BYTE_12_BPD_S@GOTPAGE
Lloh45:
	ldr	x8, [x8, _V2_MPT_BYTE_12_BPD_S@GOTPAGEOFF]
Lloh46:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_roce_set_bit
	ldr	w0, [x19, #8]
Lloh47:
	adrp	x8, _V2_MPT_BYTE_12_BQP_S@GOTPAGE
Lloh48:
	ldr	x8, [x8, _V2_MPT_BYTE_12_BQP_S@GOTPAGEOFF]
Lloh49:
	ldr	w1, [x8]
	ldr	x8, [x20, #40]
Lloh50:
	adrp	x9, _IB_MW_TYPE_1@GOTPAGE
Lloh51:
	ldr	x9, [x9, _IB_MW_TYPE_1@GOTPAGEOFF]
Lloh52:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w2, ne
	bl	_roce_set_bit
	ldr	w0, [x19, #4]
Lloh53:
	adrp	x8, _V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M@GOTPAGE
Lloh54:
	ldr	x8, [x8, _V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M@GOTPAGEOFF]
Lloh55:
	ldr	w1, [x8]
Lloh56:
	adrp	x8, _V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S@GOTPAGE
Lloh57:
	ldr	x8, [x8, _V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S@GOTPAGEOFF]
Lloh58:
	ldr	w2, [x8]
	ldr	x8, [x20, #24]
	ldr	x9, [x21]
	add	x3, x9, x8
	bl	_roce_set_field
	ldr	w0, [x20, #32]
	bl	_cpu_to_le32
	str	w0, [x19]
	mov	w0, #0
	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	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_V2_MPT_BYTE_4_MPT_ST_M,4,2     ; @V2_MPT_BYTE_4_MPT_ST_M
	.comm	_V2_MPT_BYTE_4_MPT_ST_S,4,2     ; @V2_MPT_BYTE_4_MPT_ST_S
	.comm	_V2_MPT_ST_FREE,8,3             ; @V2_MPT_ST_FREE
	.comm	_V2_MPT_BYTE_4_PD_M,4,2         ; @V2_MPT_BYTE_4_PD_M
	.comm	_V2_MPT_BYTE_4_PD_S,4,2         ; @V2_MPT_BYTE_4_PD_S
	.comm	_V2_MPT_BYTE_4_PBL_HOP_NUM_M,4,2 ; @V2_MPT_BYTE_4_PBL_HOP_NUM_M
	.comm	_V2_MPT_BYTE_4_PBL_HOP_NUM_S,4,2 ; @V2_MPT_BYTE_4_PBL_HOP_NUM_S
	.comm	_HNS_ROCE_HOP_NUM_0,8,3         ; @HNS_ROCE_HOP_NUM_0
	.comm	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_M,4,2 ; @V2_MPT_BYTE_4_PBL_BA_PG_SZ_M
	.comm	_V2_MPT_BYTE_4_PBL_BA_PG_SZ_S,4,2 ; @V2_MPT_BYTE_4_PBL_BA_PG_SZ_S
	.comm	_PG_SHIFT_OFFSET,8,3            ; @PG_SHIFT_OFFSET
	.comm	_V2_MPT_BYTE_8_R_INV_EN_S,4,2   ; @V2_MPT_BYTE_8_R_INV_EN_S
	.comm	_V2_MPT_BYTE_8_L_INV_EN_S,4,2   ; @V2_MPT_BYTE_8_L_INV_EN_S
	.comm	_V2_MPT_BYTE_12_PA_S,4,2        ; @V2_MPT_BYTE_12_PA_S
	.comm	_V2_MPT_BYTE_12_MR_MW_S,4,2     ; @V2_MPT_BYTE_12_MR_MW_S
	.comm	_V2_MPT_BYTE_12_BPD_S,4,2       ; @V2_MPT_BYTE_12_BPD_S
	.comm	_V2_MPT_BYTE_12_BQP_S,4,2       ; @V2_MPT_BYTE_12_BQP_S
	.comm	_IB_MW_TYPE_1,8,3               ; @IB_MW_TYPE_1
	.comm	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M,4,2 ; @V2_MPT_BYTE_64_PBL_BUF_PG_SZ_M
	.comm	_V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S,4,2 ; @V2_MPT_BYTE_64_PBL_BUF_PG_SZ_S
	.no_dead_strip	_hns_roce_v2_mw_write_mtpt
.subsections_via_symbols
