函数逻辑报告 | 
Source Code:kernel\power\user.c | 
Create Date:2022-07-27 11:03:44 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| 首页 | 函数Tree | 
| 注解内核,赢得工具 | 下载SCCT | English | 
函数名称:snapshot_open
函数原型:static int snapshot_open(struct inode *inode, struct file *filp)
返回类型:int
参数:
| 类型 | 参数 | 名称 | 
|---|---|---|
| struct inode * | inode | |
| struct file * | filp | 
| 47 | nr_calls等于0 | 
| 49 | 如果非hibernation_available()则返回:负EPERM | 
| 52 | lock_system_sleep() | 
| 64 | nonseekable_open(inode, filp) | 
| 65 | data等于snapshot_state | 
| 67 | memset( & handle, 0, sizeof(structsnapshot_handle)) | 
| 70 | swap等于如果swsusp_resume_device则swap_type_of(swsusp_resume_device, 0, NULL)否则负1 | 
| 73 | free_bitmaps = false | 
| 74 | error等于__pm_notifier_call_chain(Going to hibernate , - 1, & nr_calls) | 
| 75 | 如果error则__pm_notifier_call_chain(Hibernation finished , --nr_calls, NULL) | 
| 77 | 否则 | 
| 84 | swap等于负1 | 
| 86 | error等于__pm_notifier_call_chain(Going to restore a saved image , - 1, & nr_calls) | 
| 87 | 如果非error则 | 
| 89 | free_bitmaps等于非error | 
| 90 | 否则nr_calls自减 | 
| 93 | 如果error则__pm_notifier_call_chain(Restore failed , nr_calls, NULL) | 
| 96 | 如果error则atomic_inc( & snapshot_device_available) | 
| 99 | frozen = false | 
| 100 | ready = false | 
| 101 | platform_support = false | 
| 103 | Unlock : | 
| 104 | unlock_system_sleep() | 
| 106 | 返回:error | 
| 源代码转换工具 开放的插件接口  | X | 
|---|---|
| 支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码  |