Commit 15c7f684 authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-16264: Minor cleanup

Add missing static qualifiers.
parent a69cff29
...@@ -1360,8 +1360,7 @@ os_aio_init( ...@@ -1360,8 +1360,7 @@ os_aio_init(
/** /**
Frees the asynchronous io system. */ Frees the asynchronous io system. */
void void os_aio_free();
os_aio_free();
struct os_aio_userdata_t struct os_aio_userdata_t
{ {
......
...@@ -123,12 +123,12 @@ class io_slots ...@@ -123,12 +123,12 @@ class io_slots
} }
}; };
io_slots* read_slots; static io_slots *read_slots;
io_slots* write_slots; static io_slots *write_slots;
io_slots* ibuf_slots; static io_slots *ibuf_slots;
/** Number of retries for partial I/O's */ /** Number of retries for partial I/O's */
static const ulint NUM_RETRIES_ON_PARTIAL_IO = 10; constexpr ulint NUM_RETRIES_ON_PARTIAL_IO = 10;
/* This specifies the file permissions InnoDB uses when it creates files in /* This specifies the file permissions InnoDB uses when it creates files in
Unix; the value of os_innodb_umask is initialized in ha_innodb.cc to Unix; the value of os_innodb_umask is initialized in ha_innodb.cc to
...@@ -4047,24 +4047,25 @@ bool os_aio_init(ulint n_reader_threads, ulint n_writer_threads, ulint) ...@@ -4047,24 +4047,25 @@ bool os_aio_init(ulint n_reader_threads, ulint n_writer_threads, ulint)
return true; return true;
} }
void os_aio_free(void) void os_aio_free()
{ {
srv_thread_pool->disable_aio(); srv_thread_pool->disable_aio();
delete read_slots; delete read_slots;
delete write_slots; delete write_slots;
delete ibuf_slots; delete ibuf_slots;
read_slots= nullptr;
write_slots= nullptr;
ibuf_slots= nullptr;
} }
/** Waits until there are no pending writes. There can /** Waits until there are no pending writes. There can
be other, synchronous, pending writes. */ be other, synchronous, pending writes. */
void void os_aio_wait_until_no_pending_writes()
os_aio_wait_until_no_pending_writes()
{ {
write_slots->wait(); write_slots->wait();
} }
/** /**
NOTE! Use the corresponding macro os_aio(), not directly this function! NOTE! Use the corresponding macro os_aio(), not directly this function!
Requests an asynchronous i/o operation. Requests an asynchronous i/o operation.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment