summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErmal LUÇI <eri@pfsense.org>2014-11-26 20:59:13 +0100
committerErmal LUÇI <eri@pfsense.org>2014-11-26 20:59:13 +0100
commit7d5fc0b300dbe214f263a1493377bdb947db0675 (patch)
tree699a56037da062bac4d512d4dbc5d47bd77fa1a9
parent383f20a1c379139f88b6feeb8cedc711f5b6392f (diff)
downloadpfsense-7d5fc0b300dbe214f263a1493377bdb947db0675.zip
pfsense-7d5fc0b300dbe214f263a1493377bdb947db0675.tar.gz
Move these functions nearby since thy are related
-rw-r--r--etc/inc/interfaces.inc36
1 files changed, 18 insertions, 18 deletions
diff --git a/etc/inc/interfaces.inc b/etc/inc/interfaces.inc
index 1bc4527..f076845 100644
--- a/etc/inc/interfaces.inc
+++ b/etc/inc/interfaces.inc
@@ -2760,24 +2760,6 @@ function find_dhcp6c_process($interface) {
return intval($pid);
}
-function interface_vlan_mtu_configured($realhwif, $mtu) {
- global $config;
-
- if (is_array($config['vlans']) && is_array($config['vlans']['vlan'])) {
- foreach ($config['vlans']['vlan'] as $vlan) {
- if ($vlan['if'] != $realhwif)
- continue;
- $assignedport = convert_real_interface_to_friendly_interface_name($vlan['vlanif']);
- if (!empty($assignedport) && !empty($config['interfaces'][$assignedport]['mtu'])) {
- if (intval($config['interfaces'][$assignedport]['mtu']) > $mtu)
- $mtu = $config['interfaces'][$assignedport]['mtu'];
- }
- }
- }
-
- return $mtu;
-}
-
function interface_virtual_create($interface) {
global $config;
@@ -2818,6 +2800,24 @@ function interface_virtual_create($interface) {
}
}
+function interface_vlan_mtu_configured($realhwif, $mtu) {
+ global $config;
+
+ if (is_array($config['vlans']) && is_array($config['vlans']['vlan'])) {
+ foreach ($config['vlans']['vlan'] as $vlan) {
+ if ($vlan['if'] != $realhwif)
+ continue;
+ $assignedport = convert_real_interface_to_friendly_interface_name($vlan['vlanif']);
+ if (!empty($assignedport) && !empty($config['interfaces'][$assignedport]['mtu'])) {
+ if (intval($config['interfaces'][$assignedport]['mtu']) > $mtu)
+ $mtu = $config['interfaces'][$assignedport]['mtu'];
+ }
+ }
+ }
+
+ return $mtu;
+}
+
function interface_vlan_adapt_mtu($vlanifs, $mtu) {
global $config;
OpenPOWER on IntegriCloud