	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_sysfs_fw_map_entry
_add_sysfs_fw_map_entry:                ## @add_sysfs_fw_map_entry
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	cmpq	$0, 8(%rdi)
	je	LBB0_2
## %bb.1:
	movq	_EEXIST@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
LBB0_7:
	subl	(%rax), %ebx
	jmp	LBB0_8
LBB0_2:
	movq	%rdi, %r14
	movq	_add_sysfs_fw_map_entry.mmap_kset(%rip), %rax
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	movq	_firmware_kobj@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str(%rip), %rdi
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	callq	_kset_create_and_add
	movq	%rax, _add_sysfs_fw_map_entry.mmap_kset(%rip)
	testq	%rax, %rax
	je	LBB0_6
LBB0_4:
	movq	%rax, (%r14)
	movl	_add_sysfs_fw_map_entry.map_entries_nr(%rip), %ecx
	leal	1(%rcx), %eax
	movl	%eax, _add_sysfs_fw_map_entry.map_entries_nr(%rip)
	leaq	L_.str.1(%rip), %rdx
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%esi, %esi
                                        ## kill: def $ecx killed $ecx killed $rcx
	callq	_kobject_add
	testq	%rax, %rax
	je	LBB0_8
## %bb.5:
	movq	%r14, %rdi
	callq	_kobject_put
LBB0_8:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_add_sysfs_fw_map_entry.map_entries_nr,4,2 ## @add_sysfs_fw_map_entry.map_entries_nr
.zerofill __DATA,__bss,_add_sysfs_fw_map_entry.mmap_kset,8,3 ## @add_sysfs_fw_map_entry.mmap_kset
	.comm	_EEXIST,4,2                     ## @EEXIST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"memmap"

	.comm	_firmware_kobj,4,2              ## @firmware_kobj
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"%d"

	.no_dead_strip	_add_sysfs_fw_map_entry
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_sysfs_fw_map_entry
_add_sysfs_fw_map_entry:                ; @add_sysfs_fw_map_entry
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _EEXIST@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EEXIST@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_7
LBB0_3:
	mov	x19, x0
	adrp	x20, _add_sysfs_fw_map_entry.mmap_kset@PAGE
	ldr	x0, [x20, _add_sysfs_fw_map_entry.mmap_kset@PAGEOFF]
	cbnz	x0, LBB0_5
; %bb.4:
Lloh2:
	adrp	x8, _firmware_kobj@GOTPAGE
Lloh3:
	ldr	x8, [x8, _firmware_kobj@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
Lloh5:
	adrp	x0, l_.str@PAGE
Lloh6:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, #0
	bl	_kset_create_and_add
	str	x0, [x20, _add_sysfs_fw_map_entry.mmap_kset@PAGEOFF]
	cbz	x0, LBB0_8
LBB0_5:
	str	x0, [x19]
	adrp	x8, _add_sysfs_fw_map_entry.map_entries_nr@PAGE
	ldr	w3, [x8, _add_sysfs_fw_map_entry.map_entries_nr@PAGEOFF]
	add	w9, w3, #1
	str	w9, [x8, _add_sysfs_fw_map_entry.map_entries_nr@PAGEOFF]
Lloh7:
	adrp	x2, l_.str.1@PAGE
Lloh8:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x1, #0
	bl	_kobject_add
	cbz	x0, LBB0_7
; %bb.6:
	mov	x0, x19
	bl	_kobject_put
	mov	w0, #0
LBB0_7:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_8:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_add_sysfs_fw_map_entry.map_entries_nr,4,2 ; @add_sysfs_fw_map_entry.map_entries_nr
.zerofill __DATA,__bss,_add_sysfs_fw_map_entry.mmap_kset,8,3 ; @add_sysfs_fw_map_entry.mmap_kset
	.comm	_EEXIST,4,2                     ; @EEXIST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"memmap"

	.comm	_firmware_kobj,4,2              ; @firmware_kobj
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"%d"

	.no_dead_strip	_add_sysfs_fw_map_entry
.subsections_via_symbols
