Commit 54dc9964 authored by unknown's avatar unknown

Postreview changes.


include/my_sys.h:
  The comments added.
include/pagecache.h:
  Functions names changed.
storage/maria/unittest/mf_pagecache_consist.c:
  Functions names changed.
storage/maria/unittest/mf_pagecache_single.c:
  Functions names changed.
parent 6ad2316f
......@@ -280,7 +280,12 @@ enum cache_type
enum flush_type
{
FLUSH_KEEP, FLUSH_RELEASE, FLUSH_IGNORE_CHANGED, FLUSH_FORCE_WRITE
FLUSH_KEEP, /* flush block and keep it in the cache */
FLUSH_RELEASE, /* flush block and remove it from the cache */
FLUSH_IGNORE_CHANGED, /* remove block from the cache */
/* as my_disable_flush_pagecache_blocks is always 0, it is
strictly equivalent to FLUSH_KEEP */
FLUSH_FORCE_WRITE
};
typedef struct st_record_cache /* Used when cacheing records */
......
......@@ -194,26 +194,26 @@ extern my_bool pagecache_write(PAGECACHE *pagecache,
enum pagecache_page_pin pin,
enum pagecache_write_mode write_mode,
PAGECACHE_PAGE_LINK *link);
extern void pagecache_unlock_page(PAGECACHE *pagecache,
extern void pagecache_unlock(PAGECACHE *pagecache,
PAGECACHE_FILE *file,
pgcache_page_no_t pageno,
enum pagecache_page_lock lock,
enum pagecache_page_pin pin,
LSN first_REDO_LSN_for_page);
extern void pagecache_unlock(PAGECACHE *pagecache,
extern void pagecache_unlock_by_link(PAGECACHE *pagecache,
PAGECACHE_PAGE_LINK *link,
enum pagecache_page_lock lock,
enum pagecache_page_pin pin,
LSN first_REDO_LSN_for_page);
extern void pagecache_unpin_page(PAGECACHE *pagecache,
extern void pagecache_unpin(PAGECACHE *pagecache,
PAGECACHE_FILE *file,
pgcache_page_no_t pageno);
extern void pagecache_unpin(PAGECACHE *pagecache,
extern void pagecache_unpin_by_link(PAGECACHE *pagecache,
PAGECACHE_PAGE_LINK *link);
extern int flush_pagecache_blocks(PAGECACHE *keycache,
PAGECACHE_FILE *file,
enum flush_type type);
extern my_bool pagecache_delete_page(PAGECACHE *pagecache,
extern my_bool pagecache_delete(PAGECACHE *pagecache,
PAGECACHE_FILE *file,
pgcache_page_no_t pageno,
enum pagecache_page_lock lock,
......
This diff is collapsed.
......@@ -135,7 +135,7 @@ uint check_page(uchar *buff, ulong offset, int page_locked, int page_no,
DBUG_PRINT("err", ("try to flush"));
if (page_locked)
{
pagecache_delete_page(&pagecache, &file1, page_no,
pagecache_delete(&pagecache, &file1, page_no,
PAGECACHE_LOCK_LEFT_WRITELOCKED, 1);
}
else
......
......@@ -231,7 +231,7 @@ int simple_pin_test()
ok((res= test(test_file(file1, file1_name, PAGE_SIZE*2, PAGE_SIZE*2,
simple_pin_test_file1))),
"Simple pin page file with pin");
pagecache_unlock_page(&pagecache,
pagecache_unlock(&pagecache,
&file1,
0,
PAGECACHE_LOCK_READ_UNLOCK,
......@@ -282,7 +282,7 @@ int simple_delete_forget_test()
PAGECACHE_PIN_LEFT_UNPINNED,
PAGECACHE_WRITE_DELAY,
0);
pagecache_delete_page(&pagecache, &file1, 0,
pagecache_delete(&pagecache, &file1, 0,
PAGECACHE_LOCK_WRITE, 0);
flush_pagecache_blocks(&pagecache, &file1, FLUSH_FORCE_WRITE);
ok((res= test(test_file(file1, file1_name, PAGE_SIZE, PAGE_SIZE,
......@@ -324,7 +324,7 @@ int simple_delete_flush_test()
PAGECACHE_PIN_LEFT_PINNED,
PAGECACHE_WRITE_DELAY,
0);
pagecache_delete_page(&pagecache, &file1, 0,
pagecache_delete(&pagecache, &file1, 0,
PAGECACHE_LOCK_LEFT_WRITELOCKED, 1);
flush_pagecache_blocks(&pagecache, &file1, FLUSH_FORCE_WRITE);
ok((res= test(test_file(file1, file1_name, PAGE_SIZE, PAGE_SIZE,
......
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