2 # SPDX-License-Identifier: GPL-2.0
4 source _debugfs_common.sh
6 # Test empty targets case
7 # =======================
9 orig_target_ids
=$
(cat "$DBGFS/target_ids")
10 echo "" > "$DBGFS/target_ids"
12 if [ -f "$DBGFS/monitor_on_DEPRECATED" ]
14 monitor_on_file
="$DBGFS/monitor_on_DEPRECATED"
16 monitor_on_file
="$DBGFS/monitor_on"
19 orig_monitor_on
=$
(cat "$monitor_on_file")
20 test_write_fail
"$monitor_on_file" "on" "orig_monitor_on" "empty target ids"
21 echo "$orig_target_ids" > "$DBGFS/target_ids"