Skip to content

Commit cfaa5be

Browse files
committed
Comment out more unused page lock functions
1 parent 75d26b7 commit cfaa5be

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

qemu/accel/tcg/translate-all.c

+2-8
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,7 @@ static inline void page_unlock_tb(struct uc_struct *uc, const TranslationBlock *
522522
}
523523
}
524524

525+
#if 0
525526
static inline struct page_entry *
526527
page_entry_new(PageDesc *pd, tb_page_addr_t index)
527528
{
@@ -542,7 +543,6 @@ static void page_entry_destroy(gpointer p)
542543
g_free(pe);
543544
}
544545

545-
#if 0
546546
/* returns false on success */
547547
static bool page_entry_trylock(struct page_entry *pe)
548548
{
@@ -582,7 +582,6 @@ static gboolean page_entry_unlock(gpointer key, gpointer value, gpointer data)
582582
}
583583
return FALSE;
584584
}
585-
#endif
586585

587586
/*
588587
* Trylock a page, and if successful, add the page to a collection.
@@ -613,20 +612,14 @@ static bool page_trylock_add(struct uc_struct *uc, struct page_collection *set,
613612
*/
614613
if (set->max == NULL || pe->index > set->max->index) {
615614
set->max = pe;
616-
#if 0
617615
do_page_entry_lock(pe);
618-
#endif
619616
return false;
620617
}
621618
/*
622619
* Try to acquire out-of-order lock; if busy, return busy so that we acquire
623620
* locks in order.
624621
*/
625-
#if 0
626622
return page_entry_trylock(pe);
627-
#else
628-
return 0;
629-
#endif
630623
}
631624

632625
static gint tb_page_addr_cmp(gconstpointer ap, gconstpointer bp, gpointer udata)
@@ -641,6 +634,7 @@ static gint tb_page_addr_cmp(gconstpointer ap, gconstpointer bp, gpointer udata)
641634
}
642635
return 1;
643636
}
637+
#endif
644638

645639
/*
646640
* Lock a range of pages ([@start,@end[) as well as the pages of all

0 commit comments

Comments
 (0)