summaryrefslogtreecommitdiff
path: root/storage/innobase/include/fsp0fsp.h
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-11-20 12:30:55 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-11-24 15:43:12 +0200
commitedbde4a11fd0b6437202f8019a79911441b6fb32 (patch)
tree2b420db82ee16dd7eaefbefeb9a0e377770a56f2 /storage/innobase/include/fsp0fsp.h
parentbdd88cfa348b1a5257b1ae8f6231e6a2fcb6d30f (diff)
downloadmariadb-git-edbde4a11fd0b6437202f8019a79911441b6fb32.tar.gz
MDEV-24167: Replace fil_space::latch
We must avoid acquiring a latch while we are already holding one. The tablespace latch was being acquired recursively in some operations that allocate or free pages.
Diffstat (limited to 'storage/innobase/include/fsp0fsp.h')
-rw-r--r--storage/innobase/include/fsp0fsp.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/storage/innobase/include/fsp0fsp.h b/storage/innobase/include/fsp0fsp.h
index 7245db39273..43c45dcee0c 100644
--- a/storage/innobase/include/fsp0fsp.h
+++ b/storage/innobase/include/fsp0fsp.h
@@ -477,13 +477,15 @@ fsp_reserve_free_extents(
@param[in,out] seg_header file segment header
@param[in,out] space tablespace
@param[in] offset page number
-@param[in,out] mtr mini-transaction */
+@param[in,out] mtr mini-transaction
+@param[in] have_latch whether space->x_lock() was already called */
void
fseg_free_page(
fseg_header_t* seg_header,
fil_space_t* space,
uint32_t offset,
- mtr_t* mtr);
+ mtr_t* mtr,
+ bool have_latch = false);
/** Determine whether a page is free.
@param[in,out] space tablespace
@param[in] page page number