7 local _rule
=/etc
/udev
/rules.d
/51-zfcp-${ccw}.rules
9 local _cu_type _dev_type
10 local _rule
=/etc
/udev
/rules.d
/51-zfcp-${ccw}.rules
12 if [ -e /sys
/bus
/ccw
/devices
/${ccw} ] ; then
13 read _cu_type
< /sys
/bus
/ccw
/devices
/${ccw}/cutype
14 read _dev_type
< /sys
/bus
/ccw
/devices
/${ccw}/devtype
16 if [ "$_cu_type" != "1731/03" ] ; then
19 if [ "$_dev_type" != "1732/03" ] && [ "$_dev_type" != "1732/04" ] ; then
23 [ -e ${_rule} ] && return 0
25 if [ ! -f "$_rule" ] ; then
27 ACTION=="add", SUBSYSTEM=="ccw", KERNEL=="$ccw", IMPORT{program}="collect $ccw %k ${ccw} zfcp"
28 ACTION=="add", SUBSYSTEM=="drivers", KERNEL=="zfcp", IMPORT{program}="collect $ccw %k ${ccw} zfcp"
29 ACTION=="add", ENV{COLLECT_$ccw}=="0", ATTR{[ccw/$ccw]online}="1"
32 m
=$
(sed -n "/.*${wwpn}.*${lun}.*/p" $_rule)
35 ACTION=="add", KERNEL=="rport-*", ATTR{port_name}=="$wwpn", SUBSYSTEMS=="ccw", KERNELS=="$ccw", ATTR{[ccw/$ccw]$wwpn/unit_add}="$lun"
40 for zfcp_arg
in $
(getargs rd.zfcp
); do
44 create_udev_rule
$1 $2 $3
48 for zfcp_arg
in $
(getargs root
=) $
(getargs resume
=); do
51 /dev
/disk
/by-path
/ccw-
*)
52 ccw_arg
=${zfcp_arg##*/}
55 if [ -n "$ccw_arg" ] ; then
60 create_udev_rule
$2 $wwpn $lun