	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function msb_init_disk
_msb_init_disk:                         ## @msb_init_disk
	.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	%rdi, %r14
	callq	_memstick_get_drvdata
	movq	%rax, %rbx
	movq	_msb_disk_lock@GOTPCREL(%rip), %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_msb_disk_idr@GOTPCREL(%rip), %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	movl	$256, %ecx                      ## imm = 0x100
	callq	_idr_alloc
	movq	%rax, (%rbx)
	movq	%r15, %rdi
	callq	_mutex_unlock
	movq	(%rbx), %r15
	testq	%r15, %r15
	js	LBB0_9
## %bb.1:
	xorl	%r15d, %r15d
	xorl	%edi, %edi
	callq	_alloc_disk
	movq	%rax, 40(%rbx)
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	leaq	80(%rbx), %rdi
	movq	_BLK_MQ_F_SHOULD_MERGE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_msb_mq_ops@GOTPCREL(%rip), %rsi
	movl	$2, %edx
	callq	_blk_mq_init_sq_queue
	movq	%rax, 72(%rbx)
	movq	%rax, %rdi
	callq	_IS_ERR
	movq	72(%rbx), %rdi
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	callq	_PTR_ERR
	movl	%eax, %r15d
	movq	$0, 72(%rbx)
	movq	40(%rbx), %rdi
	callq	_put_disk
	jmp	LBB0_5
LBB0_2:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %r15d
LBB0_5:
	movq	_msb_disk_lock@GOTPCREL(%rip), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movl	(%rbx), %esi
	movq	_msb_disk_idr@GOTPCREL(%rip), %rdi
	callq	_idr_remove
	movq	%r14, %rdi
	callq	_mutex_unlock
	jmp	LBB0_9
LBB0_6:
	movq	%r14, (%rdi)
	movq	_MS_BLOCK_MAX_PAGES@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	callq	_blk_queue_max_hw_sectors
	movq	72(%rbx), %rdi
	movq	_MS_BLOCK_MAX_SEGS@GOTPCREL(%rip), %r13
	movq	(%r13), %rsi
	callq	_blk_queue_max_segments
	movq	72(%rbx), %rdi
	movl	8(%rbx), %esi
	imull	(%r15), %esi
	callq	_blk_queue_max_segment_size
	movq	72(%rbx), %rdi
	movl	8(%rbx), %esi
	callq	_blk_queue_logical_block_size
	movq	40(%rbx), %rax
	movl	32(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	callq	_sprintf
	movq	40(%rbx), %rdi
	movq	_msb_bdops@GOTPCREL(%rip), %rax
	movq	%rax, 24(%rdi)
	movq	%rbx, 16(%rdi)
	movq	72(%rbx), %rax
	movq	%rax, 8(%rdi)
	movq	_GENHD_FL_EXT_DEVT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%rdi)
	movq	24(%rbx), %rax
	imulq	16(%rbx), %rax
	movl	8(%rbx), %ecx
	leal	511(%rcx), %edx
	testl	%ecx, %ecx
	cmovnsl	%ecx, %edx
	sarl	$9, %edx
	movslq	%edx, %r12
	imulq	%rax, %r12
	movq	%r12, %rsi
	callq	_set_capacity
	leaq	L_.str.1(%rip), %rdi
	xorl	%r15d, %r15d
	movq	%r12, %rsi
	xorl	%eax, %eax
	callq	_dbg
	movl	$1, 32(%rbx)
	movq	_WQ_MEM_RECLAIM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdi
	callq	_alloc_ordered_workqueue
	movl	%eax, 64(%rbx)
	movq	%rbx, %rdi
	addq	$60, %rdi
	movq	_msb_io_work@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_WORK
	movl	56(%rbx), %edi
	movq	(%r13), %rsi
	incq	%rsi
	callq	_sg_init_table
	cmpq	$0, 48(%rbx)
	je	LBB0_8
## %bb.7:
	movq	40(%rbx), %rdi
	movl	$1, %esi
	callq	_set_disk_ro
LBB0_8:
	movq	%r14, %rdi
	callq	_msb_start
	movq	40(%rbx), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_device_add_disk
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_dbg
LBB0_9:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_msb_disk_lock,4,2              ## @msb_disk_lock
	.comm	_msb_disk_idr,4,2               ## @msb_disk_idr
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_msb_mq_ops,4,2                 ## @msb_mq_ops
	.comm	_BLK_MQ_F_SHOULD_MERGE,4,2      ## @BLK_MQ_F_SHOULD_MERGE
	.comm	_MS_BLOCK_MAX_PAGES,4,2         ## @MS_BLOCK_MAX_PAGES
	.comm	_MS_BLOCK_MAX_SEGS,8,3          ## @MS_BLOCK_MAX_SEGS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"msblk%d"

	.comm	_msb_bdops,4,2                  ## @msb_bdops
	.comm	_GENHD_FL_EXT_DEVT,4,2          ## @GENHD_FL_EXT_DEVT
L_.str.1:                               ## @.str.1
	.asciz	"Set total disk size to %lu sectors"

L_.str.2:                               ## @.str.2
	.asciz	"ms_block"

	.comm	_WQ_MEM_RECLAIM,4,2             ## @WQ_MEM_RECLAIM
	.comm	_msb_io_work,4,2                ## @msb_io_work
L_.str.3:                               ## @.str.3
	.asciz	"Disk added"

	.no_dead_strip	_msb_init_disk
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function msb_init_disk
_msb_init_disk:                         ; @msb_init_disk
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x0
	bl	_memstick_get_drvdata
	mov	x19, x0
Lloh0:
	adrp	x21, _msb_disk_lock@GOTPAGE
Lloh1:
	ldr	x21, [x21, _msb_disk_lock@GOTPAGEOFF]
	mov	x0, x21
	bl	_mutex_lock
Lloh2:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh4:
	ldr	w4, [x8]
Lloh5:
	adrp	x0, _msb_disk_idr@GOTPAGE
Lloh6:
	ldr	x0, [x0, _msb_disk_idr@GOTPAGEOFF]
	mov	x1, x20
	mov	w2, #0
	mov	w3, #256
	bl	_idr_alloc
	str	x0, [x19]
	mov	x0, x21
	bl	_mutex_unlock
	ldr	x21, [x19]
	tbnz	x21, #63, LBB0_9
; %bb.1:
	mov	w0, #0
	bl	_alloc_disk
	str	x0, [x19, #40]
	cbz	x0, LBB0_4
; %bb.2:
	add	x0, x19, #80
Lloh7:
	adrp	x8, _BLK_MQ_F_SHOULD_MERGE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _BLK_MQ_F_SHOULD_MERGE@GOTPAGEOFF]
Lloh9:
	ldr	w3, [x8]
Lloh10:
	adrp	x1, _msb_mq_ops@GOTPAGE
Lloh11:
	ldr	x1, [x1, _msb_mq_ops@GOTPAGEOFF]
	mov	w2, #2
	bl	_blk_mq_init_sq_queue
	str	x0, [x19, #72]
	bl	_IS_ERR
	mov	x8, x0
	ldr	x0, [x19, #72]
	cbz	x8, LBB0_6
; %bb.3:
	bl	_PTR_ERR
	mov	x21, x0
	str	xzr, [x19, #72]
	ldr	x0, [x19, #40]
	bl	_put_disk
	b	LBB0_5
LBB0_4:
Lloh12:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_5:
Lloh15:
	adrp	x20, _msb_disk_lock@GOTPAGE
Lloh16:
	ldr	x20, [x20, _msb_disk_lock@GOTPAGEOFF]
	mov	x0, x20
	bl	_mutex_lock
	ldr	w1, [x19]
Lloh17:
	adrp	x0, _msb_disk_idr@GOTPAGE
Lloh18:
	ldr	x0, [x0, _msb_disk_idr@GOTPAGEOFF]
	bl	_idr_remove
	mov	x0, x20
	bl	_mutex_unlock
	b	LBB0_9
LBB0_6:
	str	x20, [x0]
Lloh19:
	adrp	x21, _MS_BLOCK_MAX_PAGES@GOTPAGE
Lloh20:
	ldr	x21, [x21, _MS_BLOCK_MAX_PAGES@GOTPAGEOFF]
	ldr	w1, [x21]
	bl	_blk_queue_max_hw_sectors
	ldr	x0, [x19, #72]
Lloh21:
	adrp	x22, _MS_BLOCK_MAX_SEGS@GOTPAGE
Lloh22:
	ldr	x22, [x22, _MS_BLOCK_MAX_SEGS@GOTPAGEOFF]
	ldr	x1, [x22]
	bl	_blk_queue_max_segments
	ldr	x0, [x19, #72]
	ldr	w8, [x21]
	ldr	w9, [x19, #8]
	mul	w1, w9, w8
	bl	_blk_queue_max_segment_size
	ldr	x0, [x19, #72]
	ldr	w1, [x19, #8]
	bl	_blk_queue_logical_block_size
	ldr	x8, [x19, #40]
	ldr	w0, [x8, #32]
	ldr	w2, [x19]
Lloh23:
	adrp	x1, l_.str@PAGE
Lloh24:
	add	x1, x1, l_.str@PAGEOFF
	bl	_sprintf
	ldr	x0, [x19, #40]
Lloh25:
	adrp	x8, _msb_bdops@GOTPAGE
Lloh26:
	ldr	x8, [x8, _msb_bdops@GOTPAGEOFF]
	str	x8, [x0, #24]
	ldr	x8, [x19, #72]
	stp	x8, x19, [x0, #8]
Lloh27:
	adrp	x8, _GENHD_FL_EXT_DEVT@GOTPAGE
Lloh28:
	ldr	x8, [x8, _GENHD_FL_EXT_DEVT@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	ldr	w9, [x0]
	orr	w8, w9, w8
	str	w8, [x0]
	ldp	x8, x9, [x19, #16]
	mul	x8, x9, x8
	ldr	w9, [x19, #8]
	add	w10, w9, #511
	cmp	w9, #0
	csel	w9, w10, w9, lt
	sbfx	x9, x9, #9, #23
	mul	x21, x8, x9
	mov	x1, x21
	bl	_set_capacity
	str	x21, [sp]
Lloh30:
	adrp	x0, l_.str.1@PAGE
Lloh31:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_dbg
	mov	w8, #1
	str	w8, [x19, #32]
Lloh32:
	adrp	x8, _WQ_MEM_RECLAIM@GOTPAGE
Lloh33:
	ldr	x8, [x8, _WQ_MEM_RECLAIM@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
Lloh35:
	adrp	x0, l_.str.2@PAGE
Lloh36:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_alloc_ordered_workqueue
	str	w0, [x19, #64]
	add	x0, x19, #60
Lloh37:
	adrp	x8, _msb_io_work@GOTPAGE
Lloh38:
	ldr	x8, [x8, _msb_io_work@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
	bl	_INIT_WORK
	ldr	w0, [x19, #56]
	ldr	x8, [x22]
	add	x1, x8, #1
	bl	_sg_init_table
	ldr	x8, [x19, #48]
	cbz	x8, LBB0_8
; %bb.7:
	ldr	x0, [x19, #40]
	mov	w1, #1
	bl	_set_disk_ro
LBB0_8:
	mov	x0, x20
	bl	_msb_start
	ldr	x1, [x19, #40]
	mov	x0, x20
	mov	x2, #0
	bl	_device_add_disk
Lloh40:
	adrp	x0, l_.str.3@PAGE
Lloh41:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_dbg
	mov	w21, #0
LBB0_9:
	mov	x0, x21
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh40, Lloh41
	.cfi_endproc
                                        ; -- End function
	.comm	_msb_disk_lock,4,2              ; @msb_disk_lock
	.comm	_msb_disk_idr,4,2               ; @msb_disk_idr
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_msb_mq_ops,4,2                 ; @msb_mq_ops
	.comm	_BLK_MQ_F_SHOULD_MERGE,4,2      ; @BLK_MQ_F_SHOULD_MERGE
	.comm	_MS_BLOCK_MAX_PAGES,4,2         ; @MS_BLOCK_MAX_PAGES
	.comm	_MS_BLOCK_MAX_SEGS,8,3          ; @MS_BLOCK_MAX_SEGS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"msblk%d"

	.comm	_msb_bdops,4,2                  ; @msb_bdops
	.comm	_GENHD_FL_EXT_DEVT,4,2          ; @GENHD_FL_EXT_DEVT
l_.str.1:                               ; @.str.1
	.asciz	"Set total disk size to %lu sectors"

l_.str.2:                               ; @.str.2
	.asciz	"ms_block"

	.comm	_WQ_MEM_RECLAIM,4,2             ; @WQ_MEM_RECLAIM
	.comm	_msb_io_work,4,2                ; @msb_io_work
l_.str.3:                               ; @.str.3
	.asciz	"Disk added"

	.no_dead_strip	_msb_init_disk
.subsections_via_symbols
