ksm.c (d26fad5b38e1c4667d4f2604936e59c837caa54d) | ksm.c (743162013d40ca612b4cb53d3a200dff2d9ab26e) |
---|---|
1/* 2 * Memory merging support. 3 * 4 * This code enables dynamic sharing of identical pages found in different 5 * memory areas, even if they are not shared by fork() 6 * 7 * Copyright (C) 2008-2009 Red Hat, Inc. 8 * Authors: --- 1964 unchanged lines hidden (view full) --- 1973 */ 1974 smp_wmb(); 1975 set_page_stable_node(oldpage, NULL); 1976 } 1977} 1978#endif /* CONFIG_MIGRATION */ 1979 1980#ifdef CONFIG_MEMORY_HOTREMOVE | 1/* 2 * Memory merging support. 3 * 4 * This code enables dynamic sharing of identical pages found in different 5 * memory areas, even if they are not shared by fork() 6 * 7 * Copyright (C) 2008-2009 Red Hat, Inc. 8 * Authors: --- 1964 unchanged lines hidden (view full) --- 1973 */ 1974 smp_wmb(); 1975 set_page_stable_node(oldpage, NULL); 1976 } 1977} 1978#endif /* CONFIG_MIGRATION */ 1979 1980#ifdef CONFIG_MEMORY_HOTREMOVE |
1981static int just_wait(void *word) 1982{ 1983 schedule(); 1984 return 0; 1985} 1986 | |
1987static void wait_while_offlining(void) 1988{ 1989 while (ksm_run & KSM_RUN_OFFLINE) { 1990 mutex_unlock(&ksm_thread_mutex); 1991 wait_on_bit(&ksm_run, ilog2(KSM_RUN_OFFLINE), | 1981static void wait_while_offlining(void) 1982{ 1983 while (ksm_run & KSM_RUN_OFFLINE) { 1984 mutex_unlock(&ksm_thread_mutex); 1985 wait_on_bit(&ksm_run, ilog2(KSM_RUN_OFFLINE), |
1992 just_wait, TASK_UNINTERRUPTIBLE); | 1986 TASK_UNINTERRUPTIBLE); |
1993 mutex_lock(&ksm_thread_mutex); 1994 } 1995} 1996 1997static void ksm_check_stable_tree(unsigned long start_pfn, 1998 unsigned long end_pfn) 1999{ 2000 struct stable_node *stable_node; --- 347 unchanged lines hidden --- | 1987 mutex_lock(&ksm_thread_mutex); 1988 } 1989} 1990 1991static void ksm_check_stable_tree(unsigned long start_pfn, 1992 unsigned long end_pfn) 1993{ 1994 struct stable_node *stable_node; --- 347 unchanged lines hidden --- |