need to talk to ethtool - ug
authorpaulr <me@pjr.cc>
Tue, 4 Oct 2011 16:54:22 +0000 (03:54 +1100)
committerpaulr <me@pjr.cc>
Tue, 4 Oct 2011 16:54:22 +0000 (03:54 +1100)
libcbfwr/config.php

index c0c43d1..2f6ce0b 100644 (file)
@@ -41,6 +41,11 @@ class Config {
                $this->config = $config;
        }
        
+       function parseEthtool($interface)
+       {
+               // im not going to enjoy this, not one little bit
+       }
+       
        function findHardware()
        {
                
@@ -63,6 +68,8 @@ class Config {
                                        }
                                        fclose($fp);
                                }
+                               
+                               // find hardware 
                                if(file_exists("/sys/class/net/$fname/mtu")) $this->config["hardware"]["netdev"][$fname]["mtu"] = trim(file_get_contents("/sys/class/net/$fname/mtu"));
                                if(file_exists("/sys/class/net/$fname/address")) $this->config["hardware"]["netdev"][$fname]["hwaddress"] = trim(file_get_contents("/sys/class/net/$fname/address"));
                                if(file_exists("/sys/class/net/$fname/bonding")) $this->config["hardware"]["netdev"][$fname]["bonding"] = true;