From bdc2e4511f2c4ebc70dcbe33a009ee4f8e9350d6 Mon Sep 17 00:00:00 2001 From: sakolish Date: Mon, 10 Mar 2008 19:08:34 +0000 Subject: [PATCH] Dynamically load FSP module - Line #530 git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@746 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- perl-xCAT-2.0/xCAT/PPC.pm | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/perl-xCAT-2.0/xCAT/PPC.pm b/perl-xCAT-2.0/xCAT/PPC.pm index a51bf15ef..af16d63de 100644 --- a/perl-xCAT-2.0/xCAT/PPC.pm +++ b/perl-xCAT-2.0/xCAT/PPC.pm @@ -8,8 +8,7 @@ use POSIX "WNOHANG"; use Storable qw(freeze thaw); use Time::HiRes qw(gettimeofday); use IO::Select; -use xCAT::PPCcli; -use xCAT::PPCfsp; +use xCAT::PPCcli; use xCAT::GlobalDef; @@ -524,6 +523,15 @@ sub invoke_cmd { # Direct-attached FSP handler ######################################## if ( $hwtype eq "fsp" ) { + + #################################### + # Dynamically load FSP module + #################################### + eval { require xCAT::PPCfsp }; + if ( $@ ) { + send_msg( $request, 1, $@ ); + return; + } my @exp = xCAT::PPCfsp::connect( $request, $host ); ####################################