Lines Matching refs:dev
7 local dev
10 dev=$1
13 dev=/dev/$1
16 echo -n $dev
61 local dev="$2"
70 sed -n -e "s@^\([^:]\+\)\(:[[:blank:]]\[0*${dev}\]:${inode}[[:blank:]](.*)\)@\1@p" )
71 for dev in $shared_list
73 if [ -n "$dev" ]
75 devmm="${devmm}$(device_major_minor $dev),"
85 devmm=${devmm}$(device_major_minor "$dev")","
115 for dev in $(xenstore-list "$base_path/$dom")
117 d=$(xenstore_read_default "$base_path/$dom/$dev/physical-device" "")
130 local m=$(xenstore_read_default "$base_path/$dom/$dev/mode" "")
157 local dev="$1"
167 result=$(check_sharing "$type" "$dev" "$mode")
171 do_ebusy "Device $dev is mounted " "$mode" "${result%% *}"
187 local dev="$2"
193 result=$(check_sharing "$type" "$dev" "$mode" "$inode")
266 dev=$(expand_dev $p)
268 if [ -L "$dev" ]
270 dev=$(readlink -f "$dev") || fatal "$dev link does not exist."
272 test -e "$dev" || fatal "$dev does not exist."
273 test -b "$dev" || fatal "$dev is not a block device."
276 check_device_sharing "$dev" "$mode"
277 write_dev "$dev"
311 dev=$(stat -c '%D' "$file")
312 if [ -z "$inode" ] || [ -z "$dev" ]
314 fatal "Unable to lookup $file: dev: $dev inode: $inode"
317 check_file_sharing "$file" "$dev" "$mode" "$inode"
320 loopdev=$(losetup -f 2>/dev/null || find_free_loopback_dev)
327 if LANG=C losetup -h 2>&1 | grep read-only >/dev/null