[yast-commit] r67255 - in /branches/SuSE-Code-11-SP2-Branch/storage: package/yast2-storage.changes storage/src/modules/Storage.ycp
Author: fehr Date: Tue Jan 24 13:51:48 2012 New Revision: 67255 URL: http://svn.opensuse.org/viewcvs/yast?rev=67255&view=rev Log: prevent display of outdated data with simple btrfs volumes Modified: branches/SuSE-Code-11-SP2-Branch/storage/package/yast2-storage.changes branches/SuSE-Code-11-SP2-Branch/storage/storage/src/modules/Storage.ycp Modified: branches/SuSE-Code-11-SP2-Branch/storage/package/yast2-storage.changes URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/storage/package/yast2-storage.changes?rev=67255&r1=67254&r2=67255&view=diff ============================================================================== --- branches/SuSE-Code-11-SP2-Branch/storage/package/yast2-storage.changes (original) +++ branches/SuSE-Code-11-SP2-Branch/storage/package/yast2-storage.changes Tue Jan 24 13:51:48 2012 @@ -1,6 +1,7 @@ ------------------------------------------------------------------- Tue Jan 24 13:28:45 CET 2012 - fehr@suse.de +- prevent display of outdated data with simple btrfs volumes - complete renaming of devs in Btrfs class (bnc#742491) - fix bug in btrfs uuid handling introduced in 2.17.124 (bnc#742491) Modified: branches/SuSE-Code-11-SP2-Branch/storage/storage/src/modules/Storage.ycp URL: http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/storage/storage/src/modules/Storage.ycp?rev=67255&r1=67254&r2=67255&view=diff ============================================================================== --- branches/SuSE-Code-11-SP2-Branch/storage/storage/src/modules/Storage.ycp (original) +++ branches/SuSE-Code-11-SP2-Branch/storage/storage/src/modules/Storage.ycp Tue Jan 24 13:51:48 2012 @@ -1979,9 +1979,18 @@ else { tg[dev] = getContainerInfo(c); - if( dev=="/dev/btrfs" ) - tg = HandleBtrfsSimpleVolumes( tg ); } + integer numbt = size(filter( map p, tg[dev,"partitions"]:[], ``(p["used_fs"]:`unknown==`btrfs ))); + y2milestone( "UpdateTargetMapDisk btrfs:%1", numbt ); + if( numbt>0 && dev!="/dev/btrfs" ) + { + map bt = tg["/dev/btrfs"]:$[]; + if( size(bt)==0 ) + bt["type"] = `CT_BTRFS; + tg["/dev/btrfs"] = getContainerInfo(bt); + } + if( numbt>0 || dev=="/dev/btrfs" ) + tg = HandleBtrfsSimpleVolumes( tg ); StorageMap[targets_key] = tg; //SCR::Write(.target.ycp, "/tmp/upd_disk_aft_"+sformat("%1",count), StorageMap[targets_key]:$[] ); //count = count+1; @@ -1995,6 +2004,8 @@ string cdev=""; map mdev = GetPartition( tg, dev ); y2milestone( "UpdateTargetMapDev mdev %1", mdev ); + boolean btrfs = mdev["used_fs"]:`unknown == `btrfs; + y2milestone( "UpdateTargetMapDev btrfs %1", btrfs ); foreach( string key, map d, tg, ``{ if( size(cdev)==0 && @@ -2035,7 +2046,9 @@ else y2error( "UpdateTargetMapDev key %1 not found in target", disk["device"]:"" ); y2milestone( "UpdateTargetMapDev mdev %1", mdev ); - if( mdev["used_fs"]:`unknown == `btrfs ) + btrfs = btrfs || mdev["used_fs"]:`unknown == `btrfs; + y2milestone( "UpdateTargetMapDev btrfs %1", btrfs ); + if( btrfs ) { map bt = tg["/dev/btrfs"]:$[]; if( size(bt)==0 ) -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
fehr@svn2.opensuse.org