* @brief Move a page to active list * * This function moves a page to the active list * within its associated address space. * * @param[in] page The page to be moved to active list * @return int Always returns 0 on success */
| 1298 | * @return int Always returns 0 on success |
| 1299 | */ |
| 1300 | static int dfs_page_active(struct dfs_page *page) |
| 1301 | { |
| 1302 | struct dfs_aspace *aspace = page->aspace; |
| 1303 | |
| 1304 | dfs_aspace_lock(aspace); |
| 1305 | if (page->space_node.next != RT_NULL) |
| 1306 | { |
| 1307 | rt_list_remove(&page->space_node); |
| 1308 | rt_list_insert_before(&aspace->list_inactive, &page->space_node); |
| 1309 | } |
| 1310 | dfs_aspace_unlock(aspace); |
| 1311 | |
| 1312 | return 0; |
| 1313 | } |
| 1314 | |
| 1315 | /** |
| 1316 | * @brief Move a page to inactive list |
no test coverage detected