Modify _xos_i_vlan_membership() in L3::Extreme to only include tagged ports
This commit is contained in:
@@ -8,6 +8,11 @@ version 3.09 ()
|
||||
L3::IBMGbTor
|
||||
* [] set_i_untagged combines both set_i_vlan and set_i_pvid in one method
|
||||
|
||||
[BUG FIXES]
|
||||
|
||||
* Modify _xos_i_vlan_membership() in L3::Extreme to only include tagged
|
||||
ports
|
||||
|
||||
version 3.08 (2013-10-22)
|
||||
|
||||
[ENHANCEMENTS]
|
||||
|
||||
@@ -485,25 +485,21 @@ sub _xos_i_vlan_membership {
|
||||
my $index = $extreme->i_index();
|
||||
my $vlans = $extreme->ex_vlan_id();
|
||||
my $slotx = $extreme->_slot_factor() || 1000;
|
||||
my $u_ports = $extreme->ex_vlan_untagged() || {};
|
||||
my $t_ports = $extreme->ex_vlan_tagged() || {};
|
||||
|
||||
my $i_vlan_membership = {};
|
||||
foreach my $idx ( keys %$u_ports ) {
|
||||
next unless ( defined $u_ports->{$idx} );
|
||||
my $u_portlist = $u_ports->{$idx};
|
||||
foreach my $idx ( keys %$t_ports ) {
|
||||
next unless ( defined $t_ports->{$idx} );
|
||||
my $t_portlist = $t_ports->{$idx};
|
||||
my $ret = [];
|
||||
|
||||
my ( $vlan_if, $slot ) = $idx =~ /^(\d+)\.(\d+)/;
|
||||
my $vlan = $vlans->{$vlan_if} || '';
|
||||
|
||||
foreach my $portlist ( $u_portlist, $t_portlist ) {
|
||||
|
||||
# Convert portlist bit array to bp_index array
|
||||
for ( my $i = 0; $i <= $#$portlist; $i++ ) {
|
||||
for ( my $i = 0; $i <= $#$t_portlist; $i++ ) {
|
||||
push( @{$ret}, ( $slotx * $slot + $i + 1 ) )
|
||||
if ( @$portlist[$i] );
|
||||
if ( @$t_portlist[$i] );
|
||||
}
|
||||
|
||||
#Create HoA ifIndex -> VLAN array
|
||||
@@ -514,7 +510,6 @@ sub _xos_i_vlan_membership {
|
||||
push( @{ $i_vlan_membership->{$ifindex} }, $vlan );
|
||||
}
|
||||
}
|
||||
}
|
||||
return $i_vlan_membership;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user