Author: aschnell
Date: Fri Feb 13 15:11:29 2009
New Revision: 55499
URL: http://svn.opensuse.org/viewcvs/yast?rev=55499&view=rev
Log:
- restrict number of disks considered for proposal (see bnc #468922)
Modified:
branches/SuSE-Code-11-Branch/storage/VERSION
branches/SuSE-Code-11-Branch/storage/package/yast2-storage.changes
branches/SuSE-Code-11-Branch/storage/storage/src/include/do_proposal_flexible.ycp
Modified: branches/SuSE-Code-11-Branch/storage/VERSION
URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-Branch/storage/VERSION?rev=55499&r1=55498&r2=55499&view=diff
==============================================================================
--- branches/SuSE-Code-11-Branch/storage/VERSION (original)
+++ branches/SuSE-Code-11-Branch/storage/VERSION Fri Feb 13 15:11:29 2009
@@ -1 +1 @@
-2.17.72
+2.17.73
Modified: branches/SuSE-Code-11-Branch/storage/package/yast2-storage.changes
URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-Branch/storage/package/yast2-storage.changes?rev=55499&r1=55498&r2=55499&view=diff
==============================================================================
--- branches/SuSE-Code-11-Branch/storage/package/yast2-storage.changes (original)
+++ branches/SuSE-Code-11-Branch/storage/package/yast2-storage.changes Fri Feb 13 15:11:29 2009
@@ -1,4 +1,11 @@
-------------------------------------------------------------------
+Fri Feb 13 14:40:06 CET 2009 - aschnell@suse.de
+
+- restrict number of disks considered for proposal (see bnc
+ #468922)
+- 2.17.73
+
+-------------------------------------------------------------------
Thu Feb 12 12:06:48 CET 2009 - aschnell@suse.de
- keep bios_id in functions that update target-map (bnc #472476)
Modified: branches/SuSE-Code-11-Branch/storage/storage/src/include/do_proposal_flexible.ycp
URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-Branch/storage/storage/src/include/do_proposal_flexible.ycp?rev=55499&r1=55498&r2=55499&view=diff
==============================================================================
--- branches/SuSE-Code-11-Branch/storage/storage/src/include/do_proposal_flexible.ycp (original)
+++ branches/SuSE-Code-11-Branch/storage/storage/src/include/do_proposal_flexible.ycp Fri Feb 13 15:11:29 2009
@@ -486,39 +486,29 @@
return( ret );
}
-define list<string> restrict_disk_names( list<string> disks )
+
+list<string> restrict_disk_names(list<string> disks)
+{
+ void helper(string s)
{
- list<string> ddev = disks;
- list<string> d1 = filter( string s, ddev, ``(search(s,"/dev/hd")==0));
- ddev = filter( string s, ddev, ``(search(s,"/dev/hd")!=0));
- if( size(d1)>2 )
- {
- integer count=1;
- d1 = maplist( string s, d1,
- ``{
- return( (count<=2)?s:"" );
- count=count+1;
- });
- d1 = filter( string s, d1, ``(size(s)>0));
- }
- d1 = (list<string>)merge( d1, filter( string s, ddev,
- ``(search(s,"/dev/sd")==0)));
- ddev = filter( string s, ddev, ``(search(s,"/dev/sd")!=0));
- ddev = (list<string>)merge( d1, ddev );
- if( size(ddev)>4 )
- {
- integer count=1;
- ddev = maplist( string s, ddev,
- ``{
- return( (count<=4)?s:"" );
- count=count+1;
- });
- ddev = filter( string s, ddev, ``(size(s)>0));
- }
- y2milestone( "restrict_disk_names: ret %1", ddev );
- return( ddev );
+ integer count = 0;
+ disks = filter(string dist, disks, {
+ if (search(dist, s) != 0)
+ return true;
+ count = count + 1;
+ return count <= 16;
+ });
}
+ helper("/dev/sd");
+ helper("/dev/hd");
+ helper("/dev/cciss/");
+
+ y2milestone("restrict_disk_names: ret %1", disks);
+ return disks;
+}
+
+
define map do_pflex( map