[LTP] [PATCH 1/2] shell: Add checkpoints api for new lib
Joerg Vehlow
lkml@jv-coder.de
Wed Aug 11 17:19:44 CEST 2021
Hi Cyril,
On 8/11/2021 2:44 PM, Cyril Hrubis wrote:
>
>> +_tst_init_checkpoints()
>> +{
>> + local pagesize
>> +
>> + LTP_IPC_PATH="/dev/shm/ltp_${TCID}_$$"
>> + pagesize=$(tst_getconf PAGESIZE)
>> + if [ $? -ne 0 ]; then
>> + tst_brk TBROK "tst_getconf PAGESIZE failed"
>> + fi
>> + ROD_SILENT dd if=/dev/zero of="$LTP_IPC_PATH" bs="$pagesize" count=1
>> + ROD_SILENT chmod 600 "$LTP_IPC_PATH"
>> + export LTP_IPC_PATH
>> +}
> Shouldn't we also delete the /dev/shm/ltp_${TCID}_$$ in the
> _tst_do_exit() if LTP_IPC_PATH was set?
You are right of course... I was in a tst_tmpdir mindset when
implementing it, sorry.
I'll send a v2
>
> Other than that it looks fine.
Joerg
More information about the ltp
mailing list