Add support for AR9280 from FreeBSD HAL
[madwifi/.git] / net80211 / if_media.c
index 285c5838eb2576098e4d6ebc04d1e15cbec2fcc6..97f7368cccf0fa5b39c63758657095443c3fb9ae 100644 (file)
 
 struct ifmedia_entry *ifmedia_match(struct ifmedia *, int, int);
 
+/* #define IFMEDIA_DEBUG */
+
 #ifdef IFMEDIA_DEBUG
-int ifmedia_debug = 0;
+int ifmedia_debug = 1;
 static void ifmedia_printword(int);
 #endif
 
@@ -119,10 +121,10 @@ ifmedia_add(struct ifmedia *ifm, int mword, int data, void *aux)
 #ifdef IFMEDIA_DEBUG
        if (ifmedia_debug) {
                if (ifm == NULL) {
-                       printk("ifmedia_add: null ifm\n");
+                       printk(KERN_ERR "ifmedia_add: null ifm\n");
                        return;
                }
-               printk("Adding entry for ");
+               printk(KERN_INFO "Adding entry for ");
                ifmedia_printword(mword);
        }
 #endif
@@ -166,7 +168,7 @@ ifmedia_set(struct ifmedia *ifm, int target)
        match = ifmedia_match(ifm, target, ifm->ifm_mask);
 
        if (match == NULL) {
-               printk("ifmedia_set: no match for 0x%x/0x%x\n",
+               printk(KERN_ERR "ifmedia_set: no match for 0x%x/0x%x\n",
                        target, ~ifm->ifm_mask);
                panic("ifmedia_set");
        }
@@ -174,9 +176,9 @@ ifmedia_set(struct ifmedia *ifm, int target)
 
 #ifdef IFMEDIA_DEBUG
        if (ifmedia_debug) {
-               printk("ifmedia_set: target ");
+               printk(KERN_INFO "ifmedia_set: target ");
                ifmedia_printword(target);
-               printk("ifmedia_set: setting to ");
+               printk(KERN_INFO "ifmedia_set: setting to ");
                ifmedia_printword(ifm->ifm_cur->ifm_media);
        }
 #endif
@@ -190,7 +192,7 @@ ifmedia_ioctl(struct net_device *dev, struct ifreq *ifr,
        struct ifmedia *ifm, u_long cmd)
 {
        struct ifmedia_entry *match;
-       struct ifmediareq *ifmr = (struct ifmediareq *) ifr;
+       struct ifmediareq *ifmr = (struct ifmediareq *)ifr;
        int error = 0, sticky;
 
        if (dev == NULL || ifr == NULL || ifm == NULL)