Power Off Notification (PON) SHORT & LONG ---the difference

Power Off Notification (PON)

1) Short Power Off Notification: Host shall expect a shorter timeout when this command is executed. The max value is defined by EXT_CSD[248] (GENERIC_CMD6_TIME, default is 0x19 = 250ms)
2) Long Power Off Notification: Host shall expect a longer timeout when this command is executed. The max value is defined by EXT_CSD[247] (POWER_OFF_LONG_TIME, default is 0xFF = 2550ms)
For the Short Power Off Notification, the device can only back up important information due to short power off time. Depending on the host’s judgment, if there is sufficient time, hosts will send a Long Power Off Notification. This provides sufficient time for the device to back up all the cached data. Figure 8 shows the process.

 

it will send PON(POWER_OFF_SHORT) to emmc while kernel str;

it will send PON(POWER_OFF_LONG) to emmc while kernel reboot:

kernel str:
[ 96.267836] value is power: 2.   // 2 is EXT_CSD_POWER_OFF_SHORT
[ 96.540099] Call trace:
[ 96.540107] dump_backtrace+0x0/0x4
[ 96.540114] dump_stack+0xf4/0x134
[ 96.540124] __mmc_switch+0x3c4/0x5c0
[ 96.583152] _mmc_suspend+0x378/0x4d0
[ 96.586817] mmc_suspend+0x20/0x58
[ 96.590224] mmc_bus_suspend+0xa0/0x160
[ 96.594065] dpm_run_callback+0x1f8/0x3ec
[ 96.598079] __device_suspend_late+0x3e8/0x508
[ 96.602526] async_suspend_late+0x34/0x188
[ 96.606629] async_run_entry_fn+0x60/0x1b0
[ 96.610731] process_one_work+0x3c0/0x670
[ 96.614745] worker_thread+0x32c/0x6d0
[ 96.618498] kthread+0x130/0x140
[ 96.621729] ret_from_fork+0x10/0x18

kernel reboot
[ 82.891781] value is power: 3.     // 3 is EXT_CSD_POWER_OFF_LONG
[ 82.891781] , dump the calltrace:
[ 82.898180] CPU: 1 PID: 1 Comm: init Tainted: P O 4.19.116+ #34
[ 82.909069] Call trace:
[ 82.911521] dump_backtrace+0x0/0x4
[ 82.915016] dump_stack+0xf4/0x134
[ 82.918422] __mmc_switch+0x3c4/0x5c0
[ 82.922085] _mmc_suspend+0x378/0x4d0
[ 82.925748] mmc_shutdown+0xa8/0xbc
[ 82.929240] mmc_bus_shutdown+0x78/0xfc
[ 82.933083] device_shutdown+0x238/0x438
[ 82.937009] kernel_restart+0x50/0x1c4
[ 82.940761] ctrl_alt_del+0x0/0x9c
[ 82.944166] el0_svc_common+0xb8/0x1b8
[ 82.947918] el0_svc_handler+0x74/0x90
[ 82.951669] el0_svc+0x8/0x340

 

posted @ 2021-05-15 22:37  aspirs  阅读(493)  评论(0编辑  收藏  举报