Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee13...
[powerpc.git] / drivers / net / wireless / hostap / hostap_ioctl.c
index 8b37e82..d061fb3 100644 (file)
@@ -1412,9 +1412,9 @@ static int prism2_ioctl_siwretry(struct net_device *dev,
        /* what could be done, if firmware would support this.. */
 
        if (rrq->flags & IW_RETRY_LIMIT) {
-               if (rrq->flags & IW_RETRY_MAX)
+               if (rrq->flags & IW_RETRY_LONG)
                        HFA384X_RID_LONGRETRYLIMIT = rrq->value;
-               else if (rrq->flags & IW_RETRY_MIN)
+               else if (rrq->flags & IW_RETRY_SHORT)
                        HFA384X_RID_SHORTRETRYLIMIT = rrq->value;
                else {
                        HFA384X_RID_LONGRETRYLIMIT = rrq->value;
@@ -1468,14 +1468,14 @@ static int prism2_ioctl_giwretry(struct net_device *dev,
                                rrq->value = le16_to_cpu(altretry);
                        else
                                rrq->value = local->manual_retry_count;
-               } else if ((rrq->flags & IW_RETRY_MAX)) {
-                       rrq->flags = IW_RETRY_LIMIT | IW_RETRY_MAX;
+               } else if ((rrq->flags & IW_RETRY_LONG)) {
+                       rrq->flags = IW_RETRY_LIMIT | IW_RETRY_LONG;
                        rrq->value = longretry;
                } else {
                        rrq->flags = IW_RETRY_LIMIT;
                        rrq->value = shortretry;
                        if (shortretry != longretry)
-                               rrq->flags |= IW_RETRY_MIN;
+                               rrq->flags |= IW_RETRY_SHORT;
                }
        }
        return 0;
@@ -1860,7 +1860,7 @@ static char * __prism2_translate_scan(local_info_t *local,
        memset(&iwe, 0, sizeof(iwe));
        iwe.cmd = SIOCGIWFREQ;
        if (scan) {
-               chan = scan->chid;
+               chan = le16_to_cpu(scan->chid);
        } else if (bss) {
                chan = bss->chan;
        } else {
@@ -1868,7 +1868,7 @@ static char * __prism2_translate_scan(local_info_t *local,
        }
 
        if (chan > 0) {
-               iwe.u.freq.m = freq_list[le16_to_cpu(chan - 1)] * 100000;
+               iwe.u.freq.m = freq_list[chan - 1] * 100000;
                iwe.u.freq.e = 1;
                current_ev = iwe_stream_add_event(current_ev, end_buf, &iwe,
                                                  IW_EV_FREQ_LEN);
@@ -3908,7 +3908,7 @@ static void prism2_get_drvinfo(struct net_device *dev,
                 local->sta_fw_ver & 0xff);
 }
 
-struct ethtool_ops prism2_ethtool_ops = {
+const struct ethtool_ops prism2_ethtool_ops = {
        .get_drvinfo = prism2_get_drvinfo
 };