Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
3f334c26
Commit
3f334c26
authored
Jan 06, 2011
by
Leigh B Stoller
Browse files
Minor debugging/verbose output tweaks.
parent
bd0594c7
Changes
1
Hide whitespace changes
Inline
Side-by-side
tbsetup/libvtop.pm.in
View file @
3f334c26
#
!/usr/bin/perl -w
#
#
EMULAB
-
COPYRIGHT
#
Copyright
(
c
)
2005
-
201
0
University
of
Utah
and
the
Flux
Group
.
#
Copyright
(
c
)
2005
-
201
1
University
of
Utah
and
the
Flux
Group
.
#
All
rights
reserved
.
#
package
libvtop
;
...
...
@@ -181,7 +181,7 @@ sub fixcurrent($) { return $_[0]->flags() & $VTOP_FLAGS_FIXNODES; }
sub
impotent
($)
{
return
$
_
[
0
]->
flags
()
&
$
VTOP_FLAGS_IMPOTENT
;
}
sub
alloconly
($)
{
return
$
_
[
0
]->
flags
()
&
$
VTOP_FLAGS_ALLOCONLY
;
}
sub
regression
($)
{
return
$
_
[
0
]->
flags
()
&
$
VTOP_FLAGS_REGRESSION
;
}
sub
printdb
($$)
{
print
$
_
[
1
]
if
($
_
[
0
]->
verbose
());
}
sub
printdb
($$)
{
print
$
_
[
1
]
if
($
_
[
0
]->
verbose
());
return
1
;
}
#
We
name
delay
nodes
internally
as
they
are
needed
.
sub
nextdelayname
($)
{
return
"tbdelay"
.
$
_
[
0
]->{
'DELAYID'
}++;
}
...
...
@@ -5478,13 +5478,17 @@ sub InterpLinksAux($)
}
if ($virtnodeA->_onsharednode() &&
!($self->impotent() || $self->alloconly()) &&
$self->printdb(" Reserving shared BW: ".
"$member0,$bandwidth,$virtifaceA\n") &&
!($self->impotent() || $self->alloconly()) &&
$virtifaceA->ReserveSharedBandwidth($bandwidth)) {
tbinfo("Could not reserve shared bandwidth: ".
"$member0,$bandwidth,$virtifaceA\n");
return -1;
}
if ($virtnodeB->_onsharednode() &&
$self->printdb(" Reserving shared BW: ".
"$member1,$rbandwidth,$virtifaceB\n") &&
!($self->impotent() || $self->alloconly()) &&
$virtifaceB->ReserveSharedBandwidth($rbandwidth)) {
tbinfo("Could not reserve shared bandwidth: ".
...
...
@@ -5651,6 +5655,8 @@ sub InterpLinksAux($)
}
my
$
maxbw
=
max
($
bandwidth
,
$
rbandwidth
);
if
($
virtnodeA
->
_onsharednode
()
&&
$
self
->
printdb
(
" Reserving shared BW: "
.
"$member0,$maxbw,$virtiface
\n
"
)
&&
!($self->impotent() || $self->alloconly) &&
$
virtiface
->
ReserveSharedBandwidth
($
maxbw
))
{
tbinfo
(
"Could not reserve shared bandwidth: "
.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment