Lines Matching refs:CONFIGFS_DIR
6 CONFIGFS_DIR="/sys/kernel/config/gpio-sim"
24 for FILE in $CONFIGFS_DIR/$CHIP/*; do
30 LINES=`ls $CONFIGFS_DIR/$CHIP/$BANK/ | grep -E ^line`
33 if [ -e $CONFIGFS_DIR/$CHIP/$BANK/$LINE/hog ]; then
34 rmdir $CONFIGFS_DIR/$CHIP/$BANK/$LINE/hog || \
38 rmdir $CONFIGFS_DIR/$CHIP/$BANK/$LINE || \
43 rmdir $CONFIGFS_DIR/$CHIP/$BANK
46 rmdir $CONFIGFS_DIR/$CHIP || fail "Unable to remove the chip"
50 for CHIP in `ls $CONFIGFS_DIR/`; do
58 mkdir $CONFIGFS_DIR/$CHIP
65 mkdir $CONFIGFS_DIR/$CHIP/$BANK
73 echo $LABEL > $CONFIGFS_DIR/$CHIP/$BANK/label || fail "Unable to set the chip label"
81 echo $NUM_LINES > $CONFIGFS_DIR/$CHIP/$BANK/num_lines || \
90 local LINE_DIR=$CONFIGFS_DIR/$CHIP/$BANK/line$OFFSET
99 echo 1 > $CONFIGFS_DIR/$CHIP/live || fail "Unable to enable the chip"
105 echo 0 > $CONFIGFS_DIR/$CHIP/live || fail "Unable to disable the chip"
112 cat $CONFIGFS_DIR/$CHIP/$BANK/chip_name 2> /dev/null || \
119 cat $CONFIGFS_DIR/$CHIP/dev_name 2> /dev/null || \
183 test -n `cat $CONFIGFS_DIR/chip/bank/chip_name` || fail "chip_name doesn't work"
189 test "`cat $CONFIGFS_DIR/chip/bank/chip_name`" = "none" || \
197 test -n `cat $CONFIGFS_DIR/chip/dev_name` || fail "dev_name doesn't work"
229 test -z "`cat $CONFIGFS_DIR/chip/bank/label`" || fail "label is not empty"
256 mkdir $CONFIGFS_DIR/chip/bank/line12foobar 2> /dev/null && \
258 mkdir $CONFIGFS_DIR/chip/bank/line_no_offset 2> /dev/null && \
277 echo foobar > $CONFIGFS_DIR/chip/bank/label 2> /dev/null && \
279 echo 8 > $CONFIGFS_DIR/chip/bank/num_lines 2> /dev/null && \
287 mkdir $CONFIGFS_DIR/chip/bank/line0 2> /dev/null && fail "Creating line item should fail"
294 echo 1 > $CONFIGFS_DIR/chip/live 2> /dev/null && fail "Probe error was not propagated"
299 echo 1 > $CONFIGFS_DIR/chip/live 2> /dev/null && fail "Chip enabled without any GPIO banks"
308 echo 1 > $CONFIGFS_DIR/chip/live 2> /dev/null && fail "Duplicate chip labels were not rejected"
315 mkdir -p $CONFIGFS_DIR/chip/bank/line4/hog