Author: aschnell
Date: Wed Feb 22 17:33:18 2012
New Revision: 67530
URL: http://svn.opensuse.org/viewcvs/yast?rev=67530&view=rev
Log:
- removed mostly usless checks
- fixed map lockup
Modified:
trunk/s390/src/modules/DASDController.ycp
trunk/s390/src/modules/ZFCPController.ycp
Modified: trunk/s390/src/modules/DASDController.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/s390/src/modules/DASDController.ycp?rev=67530&r1=67529&r2=67530&view=diff
==============================================================================
--- trunk/s390/src/modules/DASDController.ycp (original)
+++ trunk/s390/src/modules/DASDController.ycp Wed Feb 22 17:33:18 2012
@@ -71,6 +71,7 @@
return false;
}
+
/**
* Data was modified?
* @return true if modified
@@ -112,7 +113,7 @@
string regexp = "^([0-9a-fA-F]{1}).([0-9a-fA-F]{1}).([0-9a-fA-F]{1,4})$";
return regexpmatch(channel, regexp);
}
-
+
global string FormatChannel(string channel)
{
if (!IsValidChannel(channel))
@@ -193,6 +194,8 @@
y2milestone("Exit code: %1", ret);
UI::CloseDialog();
+
+ disk_configured = false;
}
}
@@ -264,12 +267,6 @@
map > ret = GetDevices();
- if (min_chan > 0 || min_lcss > 0 || min_css > 0 ||
- max_chan < 0xffff || max_lcss < 0xf || max_css < 0xf)
- {
- y2milestone("filter devices: %1.%2.%3 to %4.%5.%6", min_css, min_lcss, min_chan,
- max_css, max_lcss, max_chan);
-
ret = filter(integer k, map d, ret, {
list<string> tmp_strs = splitstring(d["channel"]:"", ".");
integer tmp_css = tointeger("0x" + tmp_strs[0]:"");
@@ -279,7 +276,6 @@
return tmp_css >= min_css && tmp_lcss >= min_lcss && tmp_chan >= min_chan &&
tmp_css <= max_css && tmp_lcss <= max_lcss && tmp_chan <= max_chan;
});
- }
return ret;
}
@@ -352,7 +348,7 @@
disks = filter (map d, disks, { return tolower(d["device"]:"") == "dasd"; });
integer count = size (disks);
- y2milestone ("Detected %1 DASD disks", count);
+ y2milestone("number of probed DASD devices %1", count);
return count > 0;
}
Modified: trunk/s390/src/modules/ZFCPController.ycp
URL: http://svn.opensuse.org/viewcvs/yast/trunk/s390/src/modules/ZFCPController.ycp?rev=67530&r1=67529&r2=67530&view=diff
==============================================================================
--- trunk/s390/src/modules/ZFCPController.ycp (original)
+++ trunk/s390/src/modules/ZFCPController.ycp Wed Feb 22 17:33:18 2012
@@ -44,6 +44,7 @@
*/
global boolean modified = false;
+
/**
*/
global boolean proposal_valid = false;
@@ -202,6 +203,8 @@
y2milestone("Exit code: %1", ret);
UI::CloseDialog();
+
+ disk_configured = false;
}
}
@@ -274,14 +277,8 @@
map > ret = GetDevices();
- if (min_chan > 0 || min_lcss > 0 || min_css > 0 ||
- max_chan < 0xffff || max_lcss < 0xf || max_css < 0xf)
- {
- y2milestone("filter devices: %1.%2.%3 to %4.%5.%6", min_css, min_lcss, min_chan,
- max_css, max_lcss, max_chan);
-
ret = filter(integer k, map d, ret, {
- list<string> tmp_strs = splitstring(d["channel"]:"", ".");
+ list<string> tmp_strs = splitstring(d["detail", "controller_id"]:"", ".");
integer tmp_css = tointeger("0x" + tmp_strs[0]:"");
integer tmp_lcss = tointeger("0x" + tmp_strs[1]:"");
integer tmp_chan = tointeger("0x" + tmp_strs[2]:"");
@@ -289,7 +286,6 @@
return tmp_css >= min_css && tmp_lcss >= min_lcss && tmp_chan >= min_chan &&
tmp_css <= max_css && tmp_lcss <= max_lcss && tmp_chan <= max_chan;
});
- }
return ret;
}
--
To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org
For additional commands, e-mail: yast-commit+help@opensuse.org