	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nl80211_set_regulatory_flags
_nl80211_set_regulatory_flags:          ## @nl80211_set_regulatory_flags
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_nlmsg_alloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r12
	movq	_NL80211_CMD_GET_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	callq	_nl80211_cmd
	movq	_WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 4(%r15)
	je	LBB0_6
## %bb.3:
	movq	_NL80211_ATTR_WIPHY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	movq	%r12, %rdi
	callq	_nla_put_u32
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	%r12, %rdi
	callq	_nlmsg_free
	movl	$-1, %ebx
	jmp	LBB0_5
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
LBB0_5:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_nl80211_get_reg@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movq	%r12, %rsi
	movq	%r14, %rcx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_send_and_recv_msgs             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_NL80211_CMD_GET_REG,4,2        ## @NL80211_CMD_GET_REG
	.comm	_WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY,4,2 ## @WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY
	.comm	_NL80211_ATTR_WIPHY,4,2         ## @NL80211_ATTR_WIPHY
	.comm	_nl80211_get_reg,4,2            ## @nl80211_get_reg
	.no_dead_strip	_nl80211_set_regulatory_flags
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nl80211_set_regulatory_flags
_nl80211_set_regulatory_flags:          ; @nl80211_set_regulatory_flags
	.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	x19, x1
	mov	x20, x0
	bl	_nlmsg_alloc
	cbz	x0, LBB0_4
; %bb.1:
	mov	x21, x0
Lloh0:
	adrp	x8, _NL80211_CMD_GET_REG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NL80211_CMD_GET_REG@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x21
	mov	w2, #0
	bl	_nl80211_cmd
	ldr	w8, [x20, #4]
Lloh3:
	adrp	x9, _WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY@GOTPAGE
Lloh4:
	ldr	x9, [x9, _WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.2:
Lloh6:
	adrp	x8, _NL80211_ATTR_WIPHY@GOTPAGE
Lloh7:
	ldr	x8, [x8, _NL80211_ATTR_WIPHY@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	w2, [x20]
	mov	x0, x21
	bl	_nla_put_u32
	cbz	x0, LBB0_6
; %bb.3:
	mov	x0, x21
	bl	_nlmsg_free
	mov	w0, #-1
	b	LBB0_5
LBB0_4:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	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
LBB0_6:
Lloh12:
	adrp	x8, _nl80211_get_reg@GOTPAGE
Lloh13:
	ldr	x8, [x8, _nl80211_get_reg@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, x21
	mov	x3, x19
	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
	b	_send_and_recv_msgs
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_NL80211_CMD_GET_REG,4,2        ; @NL80211_CMD_GET_REG
	.comm	_WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY,4,2 ; @WPA_DRIVER_FLAGS_SELF_MANAGED_REGULATORY
	.comm	_NL80211_ATTR_WIPHY,4,2         ; @NL80211_ATTR_WIPHY
	.comm	_nl80211_get_reg,4,2            ; @nl80211_get_reg
	.no_dead_strip	_nl80211_set_regulatory_flags
.subsections_via_symbols
