linux-4.4.1/start_isolate_page_range()
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
*参照元 [#ed0f0f92]
#backlinks
*説明 [#jdb94100]
-パス: [[linux-4.4.1/mm/page_isolation.c]]
-FIXME: これは何?
--説明
**引数 [#l2468554]
-unsigned long start_pfn
--
-unsigned long end_pfn
--
-unsigned migratetype
--
-bool skip_hwpoisoned_pages
--
**返り値 [#v64aa352]
-int
--
**参考 [#h3d941d4]
*実装 [#x009d738]
/*
* start_isolate_page_range() -- make page-allocation-ty...
* to be MIGRATE_ISOLATE.
* @start_pfn: The lower PFN of the range to be isolated.
* @end_pfn: The upper PFN of the range to be isolated.
* @migratetype: migrate type to set in error recovery.
*
* Making page-allocation-type to be MIGRATE_ISOLATE mea...
* the range will never be allocated. Any free pages and...
* future will not be allocated again.
*
* start_pfn/end_pfn must be aligned to pageblock_order.
* Returns 0 on success and -EBUSY if any part of range ...
*/
int start_isolate_page_range(unsigned long start_pfn, un...
unsigned migratetype, bool ...
{
unsigned long pfn;
unsigned long undo_pfn;
struct page *page;
-
--[[linux-4.4.1/page]]
BUG_ON((start_pfn) & (pageblock_nr_pages - 1));
BUG_ON((end_pfn) & (pageblock_nr_pages - 1));
-
--[[linux-4.4.1/BUG_ON()]]
--[[linux-4.4.1/pageblock_nr_pages(global)]]
for (pfn = start_pfn;
pfn < end_pfn;
pfn += pageblock_nr_pages) {
page = __first_valid_page(pfn, pageblock...
if (page &&
set_migratetype_isolate(page, skip_h...
undo_pfn = pfn;
goto undo;
}
}
-
--[[linux-4.4.1/__first_valid_page()]]
--[[linux-4.4.1/set_migratetype_isolate()]]
return 0;
undo:
for (pfn = start_pfn;
pfn < undo_pfn;
pfn += pageblock_nr_pages)
unset_migratetype_isolate(pfn_to_page(pf...
-
--[[linux-4.4.1/unset_migratetype_isolate()]]
--[[linux-4.4.1/pfn_to_page()]]
return -EBUSY;
}
*コメント [#e9ec0242]
終了行:
*参照元 [#ed0f0f92]
#backlinks
*説明 [#jdb94100]
-パス: [[linux-4.4.1/mm/page_isolation.c]]
-FIXME: これは何?
--説明
**引数 [#l2468554]
-unsigned long start_pfn
--
-unsigned long end_pfn
--
-unsigned migratetype
--
-bool skip_hwpoisoned_pages
--
**返り値 [#v64aa352]
-int
--
**参考 [#h3d941d4]
*実装 [#x009d738]
/*
* start_isolate_page_range() -- make page-allocation-ty...
* to be MIGRATE_ISOLATE.
* @start_pfn: The lower PFN of the range to be isolated.
* @end_pfn: The upper PFN of the range to be isolated.
* @migratetype: migrate type to set in error recovery.
*
* Making page-allocation-type to be MIGRATE_ISOLATE mea...
* the range will never be allocated. Any free pages and...
* future will not be allocated again.
*
* start_pfn/end_pfn must be aligned to pageblock_order.
* Returns 0 on success and -EBUSY if any part of range ...
*/
int start_isolate_page_range(unsigned long start_pfn, un...
unsigned migratetype, bool ...
{
unsigned long pfn;
unsigned long undo_pfn;
struct page *page;
-
--[[linux-4.4.1/page]]
BUG_ON((start_pfn) & (pageblock_nr_pages - 1));
BUG_ON((end_pfn) & (pageblock_nr_pages - 1));
-
--[[linux-4.4.1/BUG_ON()]]
--[[linux-4.4.1/pageblock_nr_pages(global)]]
for (pfn = start_pfn;
pfn < end_pfn;
pfn += pageblock_nr_pages) {
page = __first_valid_page(pfn, pageblock...
if (page &&
set_migratetype_isolate(page, skip_h...
undo_pfn = pfn;
goto undo;
}
}
-
--[[linux-4.4.1/__first_valid_page()]]
--[[linux-4.4.1/set_migratetype_isolate()]]
return 0;
undo:
for (pfn = start_pfn;
pfn < undo_pfn;
pfn += pageblock_nr_pages)
unset_migratetype_isolate(pfn_to_page(pf...
-
--[[linux-4.4.1/unset_migratetype_isolate()]]
--[[linux-4.4.1/pfn_to_page()]]
return -EBUSY;
}
*コメント [#e9ec0242]
ページ名: