Skip to content

Commit

Permalink
let buf_page_hash_lock_get() be function, not macro
Browse files Browse the repository at this point in the history
  • Loading branch information
kevgs committed Feb 16, 2018
1 parent 365f478 commit e14790b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions storage/innobase/include/buf0buf.h
Original file line number Diff line number Diff line change
Expand Up @@ -2351,8 +2351,11 @@ Use these instead of accessing buf_pool->mutex directly. */


/** Get appropriate page_hash_lock. */
# define buf_page_hash_lock_get(buf_pool, page_id) \
hash_get_lock((buf_pool)->page_hash, (page_id).fold())
inline rw_lock_t*
buf_page_hash_lock_get(const buf_pool_t* buf_pool, page_id_t page_id)
{
return hash_get_lock(buf_pool->page_hash, page_id.fold());
}

/** If not appropriate page_hash_lock, relock until appropriate. */
# define buf_page_hash_lock_s_confirm(hash_lock, buf_pool, page_id)\
Expand Down

0 comments on commit e14790b

Please sign in to comment.