]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
Staging: wlan-ng: Eliminate usage of procfs.
authorSolomon Peachy <pizza@shaftnet.org>
Mon, 27 Oct 2008 15:14:06 +0000 (11:14 -0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Jan 2009 21:51:55 +0000 (13:51 -0800)
These files are not needed to work properly, and don't belong in procfs

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/wlan-ng/p80211netdev.c
drivers/staging/wlan-ng/p80211netdev.h
drivers/staging/wlan-ng/prism2sta.c

index fa8bc767d9b9da83b4725231e138548faf2d5e96..e948f5c3a9108c3a2defae6446f413f176013aef 100644 (file)
 
 #define __NO_VERSION__         /* prevent the static definition */
 
-#ifdef CONFIG_PROC_FS
-static struct proc_dir_entry   *proc_p80211;
-#endif
-
 /*================================================================*/
 /* Local Function Declarations */
 
@@ -134,16 +130,6 @@ static int p80211knetdev_set_mac_address(netdevice_t *dev, void *addr);
 static void p80211knetdev_tx_timeout(netdevice_t *netdev);
 static int p80211_rx_typedrop( wlandevice_t *wlandev, UINT16 fc);
 
-#ifdef CONFIG_PROC_FS
-static int
-p80211netdev_proc_read(
-       char    *page,
-       char    **start,
-       off_t   offset,
-       int     count,
-       int     *eof,
-       void    *data);
-#endif
 
 /*================================================================*/
 /* Function Definitions */
@@ -164,14 +150,6 @@ void p80211netdev_startup(void)
 {
        DBFENTER;
 
-#ifdef CONFIG_PROC_FS
-       if (init_net.proc_net != NULL) {
-               proc_p80211 = create_proc_entry(
-                               "p80211",
-                               (S_IFDIR|S_IRUGO|S_IXUGO),
-                               init_net.proc_net);
-       }
-#endif
        DBFEXIT;
        return;
 }
@@ -192,11 +170,6 @@ void
 p80211netdev_shutdown(void)
 {
        DBFENTER;
-#ifdef CONFIG_PROC_FS
-       if (proc_p80211 != NULL) {
-               remove_proc_entry("p80211", init_net.proc_net);
-       }
-#endif
        DBFEXIT;
 }
 
@@ -997,23 +970,6 @@ int register_wlandev(wlandevice_t *wlandev)
 
        strcpy(wlandev->name, dev->name);
 
-#ifdef CONFIG_PROC_FS
-       if (proc_p80211) {
-               wlandev->procdir = proc_mkdir(wlandev->name, proc_p80211);
-               if ( wlandev->procdir )
-                       wlandev->procwlandev =
-                               create_proc_read_entry("wlandev", 0,
-                                                      wlandev->procdir,
-                                                      p80211netdev_proc_read,
-                                                      wlandev);
-               if (wlandev->nsd_proc_read)
-                       create_proc_read_entry("nsd", 0,
-                                              wlandev->procdir,
-                                              wlandev->nsd_proc_read,
-                                              wlandev);
-       }
-#endif
-
        DBFEXIT;
        return 0;
 }
@@ -1042,18 +998,6 @@ int unregister_wlandev(wlandevice_t *wlandev)
 
        DBFENTER;
 
-#ifdef CONFIG_PROC_FS
-       if ( wlandev->procwlandev ) {
-               remove_proc_entry("wlandev", wlandev->procdir);
-       }
-       if ( wlandev->nsd_proc_read ) {
-               remove_proc_entry("nsd", wlandev->procdir);
-       }
-       if (wlandev->procdir) {
-               remove_proc_entry(wlandev->name, proc_p80211);
-       }
-#endif
-
        unregister_netdev(wlandev->netdev);
 
        /* Now to clean out the rx queue */
@@ -1065,76 +1009,6 @@ int unregister_wlandev(wlandevice_t *wlandev)
        return 0;
 }
 
-#ifdef CONFIG_PROC_FS
-/*----------------------------------------------------------------
-* proc_read
-*
-* Read function for /proc/net/p80211/<device>/wlandev
-*
-* Arguments:
-*      buf
-*      start
-*      offset
-*      count
-*      eof
-*      data
-* Returns:
-*      zero on success, non-zero otherwise.
-* Call Context:
-*      Can be either interrupt or not.
-----------------------------------------------------------------*/
-static int
-p80211netdev_proc_read(
-       char    *page,
-       char    **start,
-       off_t   offset,
-       int     count,
-       int     *eof,
-       void    *data)
-{
-       char     *p = page;
-       wlandevice_t *wlandev = (wlandevice_t *) data;
-
-       DBFENTER;
-       if (offset != 0) {
-               *eof = 1;
-               goto exit;
-       }
-
-       p += sprintf(p, "p80211 version: %s\n\n",
-                    WLAN_RELEASE);
-       p += sprintf(p, "name       : %s\n", wlandev->name);
-       p += sprintf(p, "nsd name   : %s\n", wlandev->nsdname);
-       p += sprintf(p, "address    : %02x:%02x:%02x:%02x:%02x:%02x\n",
-                    wlandev->netdev->dev_addr[0], wlandev->netdev->dev_addr[1], wlandev->netdev->dev_addr[2],
-                    wlandev->netdev->dev_addr[3], wlandev->netdev->dev_addr[4], wlandev->netdev->dev_addr[5]);
-       p += sprintf(p, "nsd caps   : %s%s%s%s%s%s%s%s%s%s\n",
-                    (wlandev->nsdcaps & P80211_NSDCAP_HARDWAREWEP) ? "wep_hw " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_TIEDWEP) ? "wep_tied " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_NOHOSTWEP) ? "wep_hw_only " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_PBCC) ? "pbcc " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_SHORT_PREAMBLE) ? "short_preamble " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_AGILITY) ? "agility " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_AP_RETRANSMIT) ? "ap_retransmit " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_HWFRAGMENT) ? "hw_frag " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_AUTOJOIN) ? "autojoin " : "",
-                    (wlandev->nsdcaps & P80211_NSDCAP_NOSCAN) ? "" : "scan ");
-
-
-       p += sprintf(p, "bssid      : %02x:%02x:%02x:%02x:%02x:%02x\n",
-                    wlandev->bssid[0], wlandev->bssid[1], wlandev->bssid[2],
-                    wlandev->bssid[3], wlandev->bssid[4], wlandev->bssid[5]);
-
-       p += sprintf(p, "Enabled    : %s%s\n",
-                    (wlandev->shortpreamble) ? "short_preamble " : "",
-                    (wlandev->hostwep & HOSTWEP_PRIVACYINVOKED) ? "privacy" : "");
-
-
- exit:
-       DBFEXIT;
-       return (p - page);
-}
-#endif
 
 /*----------------------------------------------------------------
 * p80211netdev_hwremoved
index ddfcc98779d7481fd54ca146c70d453f8d764071..62fc2cbaf8afd7512b05d8d7bf722c001270646e 100644 (file)
@@ -203,10 +203,6 @@ typedef struct wlandevice
                                              netdevice_t *dev);
        void            (*tx_timeout)(struct wlandevice *wlandev);
 
-#ifdef CONFIG_PROC_FS
-       int             (*nsd_proc_read)(char *page, char **start, off_t offset, int count, int *eof, void *data);
-#endif
-
        /* 802.11 State */
        UINT8           bssid[WLAN_BSSID_LEN];
        p80211pstr32_t  ssid;
@@ -228,12 +224,6 @@ typedef struct wlandevice
        netdevice_t             *netdev;        /* ptr to linux netdevice */
        struct net_device_stats linux_stats;
 
-#ifdef CONFIG_PROC_FS
-       /* Procfs support */
-       struct proc_dir_entry   *procdir;
-       struct proc_dir_entry   *procwlandev;
-#endif
-
        /* Rx bottom half */
        struct tasklet_struct   rx_bh;
 
index 05c048071e91fa55ed025655d670ecc56c3e88d9..bc48014f264b3666157a682e48794c9768570e23 100644 (file)
@@ -164,17 +164,6 @@ static void        prism2sta_inf_authreq_defer(
 static void    prism2sta_inf_psusercnt(
                        wlandevice_t *wlandev, hfa384x_InfFrame_t *inf);
 
-#ifdef CONFIG_PROC_FS
-static int
-prism2sta_proc_read(
-       char    *page,
-       char    **start,
-       off_t   offset,
-       int     count,
-       int     *eof,
-       void    *data);
-#endif
-
 /*================================================================*/
 /* Function Definitions */
 
@@ -2177,9 +2166,6 @@ static wlandevice_t *create_wlan(void)
        wlandev->open = prism2sta_open;
        wlandev->close = prism2sta_close;
        wlandev->reset = prism2sta_reset;
-#ifdef CONFIG_PROC_FS
-       wlandev->nsd_proc_read = prism2sta_proc_read;
-#endif
        wlandev->txframe = prism2sta_txframe;
        wlandev->mlmerequest = prism2sta_mlmerequest;
        wlandev->set_multicast_list = prism2sta_setmulticast;
@@ -2194,59 +2180,6 @@ static wlandevice_t *create_wlan(void)
        return wlandev;
 }
 
-#ifdef CONFIG_PROC_FS
-static int
-prism2sta_proc_read(
-       char    *page,
-       char    **start,
-       off_t   offset,
-       int     count,
-       int     *eof,
-       void    *data)
-{
-       char     *p = page;
-       wlandevice_t *wlandev = (wlandevice_t *) data;
-       hfa384x_t *hw = (hfa384x_t *) wlandev->priv;
-
-       UINT16 hwtype = 0;
-
-       DBFENTER;
-       if (offset != 0) {
-               *eof = 1;
-               goto exit;
-       }
-
-       // XXX 0x0001 for prism2.5/3, 0x0000 for prism2.
-       hwtype = BIT0;
-
-       p += sprintf(p, "# %s version %s\n\n",
-                    dev_info,
-                    WLAN_RELEASE);
-
-       p += sprintf(p, "# nic h/w: id=0x%02x %d.%d.%d\n",
-                    hw->ident_nic.id, hw->ident_nic.major,
-                    hw->ident_nic.minor, hw->ident_nic.variant);
-
-       p += sprintf(p, "# pri f/w: id=0x%02x %d.%d.%d\n",
-                    hw->ident_pri_fw.id, hw->ident_pri_fw.major,
-                    hw->ident_pri_fw.minor, hw->ident_pri_fw.variant);
-
-       if (hw->ident_sta_fw.id == 0x1f) {
-               p += sprintf(p, "# sta f/w: id=0x%02x %d.%d.%d\n",
-                            hw->ident_sta_fw.id, hw->ident_sta_fw.major,
-                            hw->ident_sta_fw.minor, hw->ident_sta_fw.variant);
-       } else {
-               p += sprintf(p, "# ap f/w: id=0x%02x %d.%d.%d\n",
-                            hw->ident_sta_fw.id, hw->ident_sta_fw.major,
-                            hw->ident_sta_fw.minor, hw->ident_sta_fw.variant);
-       }
-
- exit:
-       DBFEXIT;
-       return (p - page);
-}
-#endif
-
 void prism2sta_commsqual_defer(struct work_struct *data)
 {
        hfa384x_t               *hw = container_of(data, struct hfa384x, commsqual_bh);