From a3952720787320d7739c9d8b16d80ef78690826e Mon Sep 17 00:00:00 2001 From: zhaoertao Date: Tue, 15 May 2012 03:05:17 +0000 Subject: [PATCH] update for perl code of Firmware Deferred update Item git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.7@12673 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT/xCAT/FSPUtils.pm | 2 ++ perl-xCAT/xCAT/FSPflash.pm | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/perl-xCAT/xCAT/FSPUtils.pm b/perl-xCAT/xCAT/FSPUtils.pm index 8efc2296d..3feb9a790 100644 --- a/perl-xCAT/xCAT/FSPUtils.pm +++ b/perl-xCAT/xCAT/FSPUtils.pm @@ -351,6 +351,8 @@ sub fsp_api_action { my $install_dir = xCAT::Utils->getInstallDir(); if( $action =~ /^(code_update|get_compatible_version_from_rpm)$/) { $cmd = "$fsp_api -a $action -T $tooltype -t $type:$fsp_ip:$id:$node_name:$parameter -d $install_dir/packages_fw/"; + } elsif($action =~ /^code_updateD$/) { + $cmd = "fsp_api -a code_update -D -T $tooltype -t $type:$fsp_ip:$id:$node_name:$parameter -d $install_dir/packages_fw/"; } elsif($action =~ /^add_connection$/) { $cmd = "$fsp_api -a $action -u $user -p $password -T $tooltype -t $type:$fsp_ip:$id:$node_name:"; } elsif ($action =~ /^set_frame_number$/) { diff --git a/perl-xCAT/xCAT/FSPflash.pm b/perl-xCAT/xCAT/FSPflash.pm index ac2a5b937..69e5b0abe 100644 --- a/perl-xCAT/xCAT/FSPflash.pm +++ b/perl-xCAT/xCAT/FSPflash.pm @@ -328,8 +328,10 @@ sub rflash { if($housekeeping =~ /^commit$/) { $action = "code_commit"} if($housekeeping =~ /^recover$/) { $action = "code_reject"} if($housekeeping =~ /^bpa_acdl$/) { $action = "acdl"} - if($activate =~ /^(disruptive|deferred)$/) { + if($activate eq "disruptive") { $action = "code_update"; + } elsif ($activate eq "deferred") { + $action = "code_updateD"; } elsif (exists($activate)){ #if($activate =~ /^concurrent$/) { my $res = "\'$activate\' option not supported in FSPflash. Please use disruptive or deferred mode";