	.file	"extr_fw.c_mlx4_QUERY_PORT.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	mlx4_QUERY_PORT
	.type	mlx4_QUERY_PORT, @function
mlx4_QUERY_PORT:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14d, esi
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rdx
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	call	mlx4_alloc_cmd_mailbox@PLT
	mov	rdi, rax
	mov	rbp, rax
	call	IS_ERR@PLT
	test	rax, rax
	jne	.L7
	mov	r13, QWORD PTR 0[rbp]
	mov	ecx, DWORD PTR MLX4_CMD_NATIVE[rip]
	mov	edx, DWORD PTR 8[rbp]
	mov	eax, DWORD PTR [r12]
	test	DWORD PTR MLX4_FLAG_OLD_PORT_CMDS[rip], eax
	jne	.L8
	mov	eax, DWORD PTR MLX4_CMD_TIME_CLASS_B[rip]
	push	rcx
	.cfi_def_cfa_offset 88
	xor	r8d, r8d
	mov	ecx, r14d
	mov	r9d, DWORD PTR MLX4_CMD_QUERY_PORT[rip]
	xor	esi, esi
	mov	rdi, r12
	push	rax
	.cfi_def_cfa_offset 96
	call	mlx4_cmd_box@PLT
	mov	r15d, eax
	pop	rax
	.cfi_def_cfa_offset 88
	pop	rdx
	.cfi_def_cfa_offset 80
	test	r15d, r15d
	jne	.L4
	xor	r14d, r14d
	xor	edx, edx
	mov	rsi, r13
	mov	edi, r14d
	call	MLX4_GET@PLT
	mov	eax, r14d
	mov	edi, r14d
	mov	DWORD PTR 20[rbx], 0
	and	eax, 3
	mov	edx, 1
	mov	rsi, r13
	mov	DWORD PTR 28[rbx], 0
	mov	DWORD PTR 24[rbx], eax
	mov	eax, r14d
	mov	DWORD PTR 32[rbx], 0
	sar	eax, 4
	mov	DWORD PTR 36[rbx], 0
	mov	DWORD PTR 12[rsp], eax
	call	MLX4_GET@PLT
	mov	eax, r14d
	mov	edi, r14d
	mov	edx, 6
	and	eax, 15
	mov	rsi, r13
	mov	DWORD PTR 4[rbx], eax
	mov	DWORD PTR 8[rsp], eax
	call	MLX4_GET@PLT
	mov	eax, DWORD PTR 8[rsp]
	mov	edi, r14d
	mov	rsi, r13
	mov	edx, 7
	mov	DWORD PTR 8[rbx], eax
	call	MLX4_GET@PLT
	mov	edi, r14d
	mov	edx, 11
	mov	rsi, r13
	mov	DWORD PTR 12[rbx], 1
	mov	DWORD PTR 16[rbx], 1
	call	MLX4_GET@PLT
	mov	ecx, DWORD PTR 12[rsp]
	mov	eax, DWORD PTR 8[rsp]
	mov	edi, r14d
	mov	edx, 10
	mov	rsi, r13
	mov	DWORD PTR 40[rbx], ecx
	mov	DWORD PTR [rbx], eax
	call	MLX4_GET@PLT
	mov	ecx, DWORD PTR 12[rsp]
	mov	eax, DWORD PTR 8[rsp]
	mov	rsi, r13
	mov	edi, DWORD PTR 52[rbx]
	mov	edx, 2
	mov	DWORD PTR 48[rbx], ecx
	mov	DWORD PTR 44[rbx], eax
	call	MLX4_GET@PLT
	mov	edi, DWORD PTR 56[rbx]
	mov	edx, 16
	mov	rsi, r13
	call	MLX4_GET@PLT
	mov	edi, r14d
	mov	edx, 24
	mov	rsi, r13
	call	MLX4_GET@PLT
	mov	eax, r14d
	mov	edi, DWORD PTR 68[rbx]
	mov	edx, 28
	sar	eax, 24
	and	r14d, 16777215
	mov	rsi, r13
	mov	DWORD PTR 60[rbx], eax
	mov	DWORD PTR 64[rbx], r14d
	call	MLX4_GET@PLT
	mov	edi, DWORD PTR 72[rbx]
	mov	edx, 32
	mov	rsi, r13
	call	MLX4_GET@PLT
.L4:
	mov	rsi, rbp
	mov	rdi, r12
	call	mlx4_free_cmd_mailbox@PLT
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r15d
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	mov	eax, DWORD PTR MLX4_CMD_TIME_CLASS_A[rip]
	push	rcx
	.cfi_def_cfa_offset 88
	xor	esi, esi
	xor	ecx, ecx
	mov	r9d, DWORD PTR MLX4_CMD_QUERY_DEV_CAP[rip]
	xor	r8d, r8d
	mov	rdi, r12
	push	rax
	.cfi_def_cfa_offset 96
	call	mlx4_cmd_box@PLT
	pop	rcx
	.cfi_def_cfa_offset 88
	pop	rsi
	.cfi_def_cfa_offset 80
	mov	r15d, eax
	test	eax, eax
	jne	.L4
	xor	r14d, r14d
	mov	edx, DWORD PTR QUERY_DEV_CAP_VL_PORT_OFFSET[rip]
	mov	rsi, r13
	mov	edi, r14d
	call	MLX4_GET@PLT
	mov	ecx, r14d
	mov	rsi, r13
	mov	edi, r14d
	sar	ecx, 4
	mov	edx, DWORD PTR QUERY_DEV_CAP_MTU_WIDTH_OFFSET[rip]
	mov	DWORD PTR [rbx], ecx
	mov	DWORD PTR 8[rsp], ecx
	call	MLX4_GET@PLT
	mov	ecx, DWORD PTR 8[rsp]
	mov	eax, r14d
	mov	rsi, r13
	and	eax, 15
	mov	edx, DWORD PTR QUERY_DEV_CAP_MAX_GID_OFFSET[rip]
	mov	edi, r14d
	mov	DWORD PTR 4[rbx], ecx
	mov	DWORD PTR 8[rbx], eax
	call	MLX4_GET@PLT
	mov	ecx, 1
	mov	rsi, r13
	mov	edi, r14d
	mov	DWORD PTR 12[rbx], ecx
	mov	edx, DWORD PTR QUERY_DEV_CAP_MAX_PKEY_OFFSET[rip]
	call	MLX4_GET@PLT
	mov	ecx, 1
	mov	DWORD PTR 16[rbx], ecx
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L7:
	add	rsp, 24
	.cfi_def_cfa_offset 56
	mov	rdi, rbp
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	jmp	PTR_ERR@PLT
	.cfi_endproc
.LFE0:
	.size	mlx4_QUERY_PORT, .-mlx4_QUERY_PORT
	.comm	QUERY_PORT_WIDTH_OFFSET,4,4
	.comm	QUERY_PORT_WAVELENGTH_OFFSET,4,4
	.comm	QUERY_PORT_TRANS_VENDOR_OFFSET,4,4
	.comm	QUERY_PORT_TRANS_CODE_OFFSET,4,4
	.comm	QUERY_PORT_SUPPORTED_TYPE_OFFSET,4,4
	.comm	QUERY_PORT_MTU_OFFSET,4,4
	.comm	QUERY_PORT_MAX_VL_OFFSET,4,4
	.comm	QUERY_PORT_MAX_MACVLAN_OFFSET,4,4
	.comm	QUERY_PORT_MAX_GID_PKEY_OFFSET,4,4
	.comm	QUERY_PORT_MAC_OFFSET,4,4
	.comm	QUERY_PORT_ETH_MTU_OFFSET,4,4
	.comm	QUERY_DEV_CAP_VL_PORT_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MTU_WIDTH_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MAX_PKEY_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MAX_GID_OFFSET,4,4
	.comm	MLX4_FLAG_OLD_PORT_CMDS,4,4
	.comm	MLX4_CMD_TIME_CLASS_B,4,4
	.comm	MLX4_CMD_TIME_CLASS_A,4,4
	.comm	MLX4_CMD_QUERY_PORT,4,4
	.comm	MLX4_CMD_QUERY_DEV_CAP,4,4
	.comm	MLX4_CMD_NATIVE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_fw.c_mlx4_QUERY_PORT.c"
	.text
	.align	2
	.global	mlx4_QUERY_PORT
	.syntax unified
	.arm
	.fpu softvfp
	.type	mlx4_QUERY_PORT, %function
mlx4_QUERY_PORT:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	sub	sp, sp, #28
	mov	r7, r1
	mov	r4, r2
	mov	r6, r0
	bl	mlx4_alloc_cmd_mailbox
	mov	r5, r0
	bl	IS_ERR
	subs	r3, r0, #0
	bne	.L7
	ldr	r2, .L9
	ldr	r0, [r6]
	ldr	r2, [r2]
	ldr	ip, .L9+4
	ands	r1, r0, r2
	ldr	r8, [r5]
	ldr	r0, [ip]
	ldr	r2, [r5, #4]
	bne	.L8
	ldr	ip, .L9+8
	ldr	r3, .L9+12
	ldr	lr, [ip]
	ldr	ip, [r3]
	mov	r3, r7
	str	r0, [sp, #12]
	stmib	sp, {ip, lr}
	mov	r0, r6
	str	r1, [sp]
	bl	mlx4_cmd_box
	subs	r7, r0, #0
	bne	.L4
	mov	r9, #0
	mov	r2, r7
	mov	r1, r8
	mov	r0, r9
	bl	MLX4_GET
	and	r0, r9, #3
	and	fp, r9, #15
	mov	r2, #1
	mov	r1, r8
	str	r0, [r4, #24]
	str	r9, [r4, #20]
	mov	r0, r9
	str	r9, [r4, #28]
	str	r9, [r4, #32]
	str	r9, [r4, #36]
	bl	MLX4_GET
	mov	r2, #6
	mov	r1, r8
	mov	r0, r9
	str	fp, [r4, #4]
	bl	MLX4_GET
	mov	r2, #7
	mov	r1, r8
	mov	r0, r9
	str	fp, [r4, #8]
	bl	MLX4_GET
	mov	r2, #1
	asr	r3, r9, #4
	lsl	r1, r2, fp
	lsl	r2, r2, r3
	str	r1, [r4, #16]
	str	r2, [r4, #12]
	mov	r1, r8
	mov	r2, #11
	mov	r0, r9
	str	r3, [sp, #20]
	bl	MLX4_GET
	ldr	r3, [sp, #20]
	mov	r2, #10
	mov	r1, r8
	str	r3, [r4, #40]
	mov	r0, r9
	str	fp, [r4]
	bl	MLX4_GET
	ldr	r3, [sp, #20]
	mov	r2, #2
	str	r3, [r4, #48]
	mov	r1, r8
	ldr	r0, [r4, #52]
	str	fp, [r4, #44]
	bl	MLX4_GET
	mov	r2, #16
	mov	r1, r8
	ldr	r0, [r4, #56]
	bl	MLX4_GET
	mov	r2, #24
	mov	r1, r8
	mov	r0, r9
	bl	MLX4_GET
	bic	r10, r9, #-16777216
	asr	r3, r9, #24
	mov	r2, #28
	mov	r1, r8
	ldr	r0, [r4, #68]
	str	r3, [r4, #60]
	str	r10, [r4, #64]
	bl	MLX4_GET
	mov	r1, r8
	mov	r2, #32
	ldr	r0, [r4, #72]
	bl	MLX4_GET
.L4:
	mov	r1, r5
	mov	r0, r6
	bl	mlx4_free_cmd_mailbox
	mov	r0, r7
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L8:
	ldr	ip, .L9+16
	ldr	r1, .L9+20
	ldr	ip, [ip]
	ldr	r1, [r1]
	str	r0, [sp, #12]
	stmib	sp, {r1, ip}
	mov	r0, r6
	mov	r1, r3
	str	r3, [sp]
	bl	mlx4_cmd_box
	subs	r7, r0, #0
	bne	.L4
	mov	r9, #0
	ldr	r3, .L9+24
	mov	r1, r8
	ldr	r2, [r3]
	mov	r0, r9
	bl	MLX4_GET
	ldr	r3, .L9+28
	asr	r10, r9, #4
	ldr	r2, [r3]
	mov	r1, r8
	str	r10, [r4]
	and	fp, r9, #15
	mov	r0, r9
	bl	MLX4_GET
	stmib	r4, {r10, fp}
	mov	r10, #1
	ldr	r3, .L9+32
	mov	r1, r8
	ldr	r2, [r3]
	mov	r0, r9
	bl	MLX4_GET
	ldr	r3, .L9+36
	lsl	r10, r10, fp
	mov	r0, r9
	mov	r1, r8
	ldr	r2, [r3]
	str	r10, [r4, #12]
	bl	MLX4_GET
	str	r10, [r4, #16]
	b	.L4
.L7:
	mov	r0, r5
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	b	PTR_ERR
.L10:
	.align	2
.L9:
	.word	MLX4_FLAG_OLD_PORT_CMDS
	.word	MLX4_CMD_NATIVE
	.word	MLX4_CMD_TIME_CLASS_B
	.word	MLX4_CMD_QUERY_PORT
	.word	MLX4_CMD_TIME_CLASS_A
	.word	MLX4_CMD_QUERY_DEV_CAP
	.word	QUERY_DEV_CAP_VL_PORT_OFFSET
	.word	QUERY_DEV_CAP_MTU_WIDTH_OFFSET
	.word	QUERY_DEV_CAP_MAX_GID_OFFSET
	.word	QUERY_DEV_CAP_MAX_PKEY_OFFSET
	.size	mlx4_QUERY_PORT, .-mlx4_QUERY_PORT
	.comm	QUERY_PORT_WIDTH_OFFSET,4,4
	.comm	QUERY_PORT_WAVELENGTH_OFFSET,4,4
	.comm	QUERY_PORT_TRANS_VENDOR_OFFSET,4,4
	.comm	QUERY_PORT_TRANS_CODE_OFFSET,4,4
	.comm	QUERY_PORT_SUPPORTED_TYPE_OFFSET,4,4
	.comm	QUERY_PORT_MTU_OFFSET,4,4
	.comm	QUERY_PORT_MAX_VL_OFFSET,4,4
	.comm	QUERY_PORT_MAX_MACVLAN_OFFSET,4,4
	.comm	QUERY_PORT_MAX_GID_PKEY_OFFSET,4,4
	.comm	QUERY_PORT_MAC_OFFSET,4,4
	.comm	QUERY_PORT_ETH_MTU_OFFSET,4,4
	.comm	QUERY_DEV_CAP_VL_PORT_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MTU_WIDTH_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MAX_PKEY_OFFSET,4,4
	.comm	QUERY_DEV_CAP_MAX_GID_OFFSET,4,4
	.comm	MLX4_FLAG_OLD_PORT_CMDS,4,4
	.comm	MLX4_CMD_TIME_CLASS_B,4,4
	.comm	MLX4_CMD_TIME_CLASS_A,4,4
	.comm	MLX4_CMD_QUERY_PORT,4,4
	.comm	MLX4_CMD_QUERY_DEV_CAP,4,4
	.comm	MLX4_CMD_NATIVE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
