	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wifi_display_subelem_set       ## -- Begin function wifi_display_subelem_set
	.p2align	4, 0x90
_wifi_display_subelem_set:              ## @wifi_display_subelem_set
	.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, %r13
	movq	%rdi, %r14
	movq	%rsi, %rdi
	movl	$32, %esi
	callq	_os_strchr
	movl	$-1, %r15d
	testq	%rax, %rax
	je	LBB0_8
## %bb.1:
	movq	%rax, %rbx
	incq	%rbx
	movb	$0, (%rax)
	movq	%rbx, %rdi
	callq	_os_strlen
	movq	%rax, %r12
	testb	$1, %r12b
	jne	LBB0_8
## %bb.2:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r12, %r14
	shrq	%r14
	leaq	L_.str(%rip), %rsi
	movq	%r13, %rdi
	callq	_os_strcmp
	testq	%rax, %rax
	je	LBB0_11
## %bb.3:
	movq	%r13, %rdi
	callq	_atoi
	testl	%eax, %eax
	js	LBB0_8
## %bb.4:
	movl	%eax, %r13d
	movq	_MAX_WFD_SUBELEMS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r13d
	jge	LBB0_8
## %bb.5:
	xorl	%r15d, %r15d
	cmpq	$2, %r12
	jae	LBB0_16
## %bb.6:
	leaq	L_.str.1(%rip), %rsi
	xorl	%r12d, %r12d
	jmp	LBB0_19
LBB0_11:
	movl	%r14d, %edi
	callq	_wpabuf_alloc
	testq	%rax, %rax
	je	LBB0_9
## %bb.12:
	movq	%rax, %r12
	movq	%rax, %rdi
	movq	%r14, %rsi
	callq	_wpabuf_put
	movq	%rbx, %rdi
	movl	%eax, %esi
	movq	%r14, %rdx
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_20
## %bb.13:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r12, %rsi
	callq	_wifi_display_subelem_set_from_ies
	movl	%eax, %ebx
	movq	%r12, %rdi
	callq	_wpabuf_free
	movl	%ebx, %eax
	jmp	LBB0_10
LBB0_16:
	leal	1(%r14), %edi
	callq	_wpabuf_alloc
	testq	%rax, %rax
	je	LBB0_8
## %bb.17:
	movq	%rax, %r12
	movq	%rax, %rdi
	movl	%r13d, %esi
	callq	_wpabuf_put_u8
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_wpabuf_put
	movq	%rbx, %rdi
	movl	%eax, %esi
	movq	%r14, %rdx
	callq	_hexstr2bin
	testq	%rax, %rax
	js	LBB0_20
## %bb.18:
	leaq	L_.str.2(%rip), %rsi
LBB0_19:
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%r13d, %edx
	callq	_wpa_printf
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	(%rbx), %rax
	movl	%r13d, %r14d
	movq	(%rax,%r14,8), %rdi
	callq	_wpabuf_free
	movq	(%rbx), %rax
	movq	%r12, (%rax,%r14,8)
	movq	%rbx, %rdi
	callq	_wifi_display_update_wfd_ie
	jmp	LBB0_9
LBB0_20:
	movq	%r12, %rdi
	callq	_wpabuf_free
LBB0_8:
	movl	$-1, %r15d
LBB0_9:
	movl	%r15d, %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"all"

	.comm	_MAX_WFD_SUBELEMS,4,2           ## @MAX_WFD_SUBELEMS
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
L_.str.1:                               ## @.str.1
	.asciz	"WFD: Clear subelement %d"

L_.str.2:                               ## @.str.2
	.asciz	"WFD: Set subelement %d"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wifi_display_subelem_set       ; -- Begin function wifi_display_subelem_set
	.p2align	2
_wifi_display_subelem_set:              ; @wifi_display_subelem_set
	.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	x22, x1
	mov	x19, x0
	mov	x0, x1
	mov	w1, #32
	bl	_os_strchr
	cbz	x0, LBB0_17
; %bb.1:
	mov	x20, x0
	strb	wzr, [x20], #1
	mov	x0, x20
	bl	_os_strlen
	mov	x23, x0
	tbnz	w23, #0, LBB0_17
; %bb.2:
	lsr	x21, x23, #1
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	bl	_os_strcmp
	cbz	x0, LBB0_7
; %bb.3:
	mov	x0, x22
	bl	_atoi
	mov	x22, x0
	mov	w0, #-1
	tbnz	w22, #31, LBB0_18
; %bb.4:
Lloh2:
	adrp	x8, _MAX_WFD_SUBELEMS@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MAX_WFD_SUBELEMS@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	cmp	w22, w8
	b.ge	LBB0_18
; %bb.5:
	cmp	x23, #2
	b.hs	LBB0_10
; %bb.6:
	mov	x23, #0
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_13
LBB0_7:
	mov	x0, x21
	bl	_wpabuf_alloc
	cbz	x0, LBB0_17
; %bb.8:
	mov	x22, x0
	mov	x1, x21
	bl	_wpabuf_put
	mov	x1, x0
	mov	x0, x20
	mov	x2, x21
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_14
; %bb.9:
	mov	x0, x19
	mov	x1, x22
	bl	_wifi_display_subelem_set_from_ies
	mov	x19, x0
	mov	x0, x22
	bl	_wpabuf_free
	mov	x0, x19
	b	LBB0_18
LBB0_10:
	add	w0, w21, #1
	bl	_wpabuf_alloc
	cbz	x0, LBB0_17
; %bb.11:
	mov	x23, x0
	mov	x1, x22
	bl	_wpabuf_put_u8
	mov	x0, x23
	mov	x1, x21
	bl	_wpabuf_put
	mov	x1, x0
	mov	x0, x20
	mov	x2, x21
	bl	_hexstr2bin
	tbnz	x0, #63, LBB0_15
; %bb.12:
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_13:
Lloh9:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	mov	x2, x22
	bl	_wpa_printf
	ldr	x8, [x19]
	mov	w9, w22
	lsl	x20, x9, #3
	ldr	x0, [x8, x20]
	bl	_wpabuf_free
	ldr	x8, [x19]
	str	x23, [x8, x20]
	mov	x0, x19
	bl	_wifi_display_update_wfd_ie
	mov	w0, #0
	b	LBB0_18
LBB0_14:
	mov	x0, x22
	b	LBB0_16
LBB0_15:
	mov	x0, x23
LBB0_16:
	bl	_wpabuf_free
LBB0_17:
	mov	w0, #-1
LBB0_18:
	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 AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"all"

	.comm	_MAX_WFD_SUBELEMS,4,2           ; @MAX_WFD_SUBELEMS
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
l_.str.1:                               ; @.str.1
	.asciz	"WFD: Clear subelement %d"

l_.str.2:                               ; @.str.2
	.asciz	"WFD: Set subelement %d"

.subsections_via_symbols
