]> err.no Git - linux-2.6/log
linux-2.6
16 years agosctp: Correctly implement Fast Recovery cwnd manipulations.
Vlad Yasevich [Wed, 4 Jun 2008 19:38:43 +0000 (12:38 -0700)]
sctp: Correctly implement Fast Recovery cwnd manipulations.

Correctly keep track of Fast Recovery state and do not reduce
congestion window multiple times during sucht state.

Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Tested-by: Wei Yongjun <yjwei@cn.fujitsu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agosctp: Move sctp_v4_dst_saddr out of loop
Gui Jianfeng [Wed, 4 Jun 2008 19:38:07 +0000 (12:38 -0700)]
sctp: Move sctp_v4_dst_saddr out of loop

There's no need to execute sctp_v4_dst_saddr() for each
iteration, just move it out of loop.

Signed-off-by: Gui Jianfeng <guijianfeng@cn.fujitsu.com>
Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agosctp: retran_path update bug fix
Gui Jianfeng [Wed, 4 Jun 2008 19:37:33 +0000 (12:37 -0700)]
sctp: retran_path update bug fix

If the current retran_path is the only active one, it should
update it to the the next inactive one.

Signed-off-by: Gui Jianfeng <guijianfeng@cn.fujitsu.com>
Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoMerge branch 'net-2.6-misc-20080605a' of git://git.linux-ipv6.org/gitroot/yoshfuji...
David S. Miller [Wed, 4 Jun 2008 19:10:21 +0000 (12:10 -0700)]
Merge branch 'net-2.6-misc-20080605a' of git://git.linux-ipv6.org/gitroot/yoshfuji/linux-2.6-fix

16 years agotcp: fix skb vs fack_count out-of-sync condition
Ilpo Järvinen [Wed, 4 Jun 2008 19:07:44 +0000 (12:07 -0700)]
tcp: fix skb vs fack_count out-of-sync condition

This bug is able to corrupt fackets_out in very rare cases.
In order for this to cause corruption:
  1) DSACK in the middle of previous SACK block must be generated.
  2) In order to take that particular branch, part or all of the
     DSACKed segment must already be SACKed so that we have that
     in cache in the first place.
  3) The new info must be top enough so that fackets_out will be
     updated on this iteration.
...then fack_count is updated while skb wasn't, then we walk again
that particular segment thus updating fack_count twice for
a single skb and finally that value is assigned to fackets_out
by tcp_sacktag_one.

It is safe to call tcp_sacktag_one just once for a segment (at
DSACK), no need to call again for plain SACK.

Potential problem of the miscount are limited to premature entry
to recovery and to inflated reordering metric (which could even
cancel each other out in the most the luckiest scenarios :-)).
Both are quite insignificant in worst case too and there exists
also code to reset them (fackets_out once sacked_out becomes zero
and reordering metric on RTO).

This has been reported by a number of people, because it occurred
quite rarely, it has been very evasive. Andy Furniss was able to
get it to occur couple of times so that a bit more info was
collected about the problem using a debug patch, though it still
required lot of checking around. Thanks also to others who have
tried to help here.

This is listed as Bugzilla #10346. The bug was introduced by
me in commit 68f8353b48 ([TCP]: Rewrite SACK block processing &
sack_recv_cache use), I probably thought back then that there's
need to scan that entry twice or didn't dare to make it go
through it just once there. Going through twice would have
required restoring fack_count after the walk but as noted above,
I chose to drop the additional walk step altogether here.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agosunhme: Cleanup use of deprecated calls to save_and_cli and restore_flags.
Mark Asselstine [Wed, 4 Jun 2008 19:06:28 +0000 (12:06 -0700)]
sunhme: Cleanup use of deprecated calls to save_and_cli and restore_flags.

Make use of local_irq_save and local_irq_restore rather then the
deprecated save_and_cli and restore_flags calls.

Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoxfrm: xfrm_algo: correct usage of RIPEMD-160
Adrian-Ken Rueegsegger [Wed, 4 Jun 2008 19:04:55 +0000 (12:04 -0700)]
xfrm: xfrm_algo: correct usage of RIPEMD-160

This patch fixes the usage of RIPEMD-160 in xfrm_algo which in turn
allows hmac(rmd160) to be used as authentication mechanism in IPsec
ESP and AH (see RFC 2857).

Signed-off-by: Adrian-Ken Rueegsegger <rueegsegger@swiss-it.ch>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago[IPV6]: Do not change protocol for UDPv6 sockets with pending sent data.
Denis V. Lunev [Wed, 4 Jun 2008 11:49:08 +0000 (15:49 +0400)]
[IPV6]: Do not change protocol for UDPv6 sockets with pending sent data.

Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6]: inet_sk(sk)->cork.opt leak
Denis V. Lunev [Wed, 4 Jun 2008 11:49:07 +0000 (15:49 +0400)]
[IPV6]: inet_sk(sk)->cork.opt leak

IPv6 UDP sockets wth IPv4 mapped address use udp_sendmsg to send the data
actually. In this case ip_flush_pending_frames should be called instead
of ip6_flush_pending_frames.

Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6]: Do not change protocol for raw IPv6 sockets.
Denis V. Lunev [Wed, 4 Jun 2008 11:49:06 +0000 (15:49 +0400)]
[IPV6]: Do not change protocol for raw IPv6 sockets.

It is not allowed to change underlying protocol for
   int fd = socket(PF_INET6, SOCK_RAW, IPPROTO_UDP);

Signed-off-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6] NETNS: Handle ancillary data in appropriate namespace.
YOSHIFUJI Hideaki [Wed, 4 Jun 2008 04:02:49 +0000 (13:02 +0900)]
[IPV6] NETNS: Handle ancillary data in appropriate namespace.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6]: Check outgoing interface even if source address is unspecified.
YOSHIFUJI Hideaki [Wed, 4 Jun 2008 04:01:37 +0000 (13:01 +0900)]
[IPV6]: Check outgoing interface even if source address is unspecified.

The outgoing interface index (ipi6_ifindex) in IPV6_PKTINFO
ancillary data, is not checked if the source address (ipi6_addr)
is unspecified.  If the ipi6_ifindex is the not-exist interface,
it should be fail.

Based on patch from Shan Wei <shanwei@cn.fujitsu.com> and
Brian Haley <brian.haley@hp.com>.

Signed-off-by: Shan Wei <shanwei@cn.fujitsu.com>
Signed-off-by: Brian Haley <brian.haley@hp.com>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6]: Fix the data length of get destination options with short length
Yang Hongyang [Wed, 28 May 2008 08:27:28 +0000 (16:27 +0800)]
[IPV6]: Fix the data length of get destination options with short length

 If get destination options with length which is not enough for that
option,getsockopt() will still return the real length of the option,
which is larger then the buffer space.
 This is because ipv6_getsockopt_sticky() returns the real length of
the option.

This patch fix this problem.

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6]: Fix the return value of get destination options with NULL data pointer
Yang Hongyang [Wed, 28 May 2008 08:23:47 +0000 (16:23 +0800)]
[IPV6]: Fix the return value of get destination options with NULL data pointer

If we pass NULL data buffer to getsockopt(), it will return 0,
and the option length is set to -EFAULT:
    getsockopt(sk, IPPROTO_IPV6, IPV6_DSTOPTS, NULL, &len);

This is because ipv6_getsockopt_sticky() will return -EFAULT or
-EINVAL if some error occur.

This patch fix this problem.

Signed-off-by: Yang Hongyang <yanghy@cn.fujitsu.com>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6] ADDRCONF: Allow longer lifetime on 64bit archs.
YOSHIFUJI Hideaki [Tue, 27 May 2008 08:37:49 +0000 (17:37 +0900)]
[IPV6] ADDRCONF: Allow longer lifetime on 64bit archs.

- Allow longer lifetimes (>= 0x7fffffff/HZ) on 64bit archs
  by using unsigned long.
- Shadow this arithmetic overflow workaround by introducing
  helper functions: addrconf_timeout_fixup() and
  addrconf_finite_timeout().

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV4] TUNNEL4: Fix incoming packet length check for inter-protocol tunnel.
YOSHIFUJI Hideaki [Fri, 30 May 2008 02:35:03 +0000 (11:35 +0900)]
[IPV4] TUNNEL4: Fix incoming packet length check for inter-protocol tunnel.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6] TUNNEL6: Fix incoming packet length check for inter-protocol tunnel.
Colin [Mon, 26 May 2008 16:04:43 +0000 (00:04 +0800)]
[IPV6] TUNNEL6: Fix incoming packet length check for inter-protocol tunnel.

I discover a strange behavior in [ipv4 in ipv6] tunnel. When IPv6 tunnel
payload is less than 40(0x28), packet can be sent to network, received in
physical interface, but not seen in IP tunnel interface. No counter increase
in tunnel interface.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6] ADDRCONF: Check range of prefix length
Thomas Graf [Wed, 28 May 2008 14:54:22 +0000 (16:54 +0200)]
[IPV6] ADDRCONF: Check range of prefix length

As of now, the prefix length is not vaildated when adding or deleting
addresses. The value is passed directly into the inet6_ifaddr structure
and later passed on to memcmp() as length indicator which relies on
the value never to exceed 128 (bits).

Due to the missing check, the currently code allows for any 8 bit
value to be passed on as prefix length while using the netlink
interface, and any 32 bit value while using the ioctl interface.

[Use unsigned int instead to generate better code - yoshfuji]

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years ago[IPV6] UDP: Possible dst leak in udpv6_sendmsg.
YOSHIFUJI Hideaki [Tue, 3 Jun 2008 16:30:25 +0000 (01:30 +0900)]
[IPV6] UDP: Possible dst leak in udpv6_sendmsg.

ip6_sk_dst_lookup returns held dst entry. It should be released
on all paths beyond this point. Add missed release when up->pending
is set.

Bug report and initial patch by Denis V. Lunev <den@openvz.org>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Acked-by: Denis V. Lunev <den@openvz.org>
16 years ago[SCTP]: Fix NULL dereference of asoc.
YOSHIFUJI Hideaki [Thu, 29 May 2008 10:55:05 +0000 (19:55 +0900)]
[SCTP]: Fix NULL dereference of asoc.

Commit 7cbca67c073263c179f605bdbbdc565ab29d801d ("[IPV6]: Support
Source Address Selection API (RFC5014)") introduced NULL dereference
of asoc to sctp_v6_get_saddr in net/sctp/ipv6.c.
Pointed out by Johann Felix Soden <johfel@users.sourceforge.net>.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
16 years agoMerge branch 'davem-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik...
David S. Miller [Wed, 4 Jun 2008 18:50:00 +0000 (11:50 -0700)]
Merge branch 'davem-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6

16 years agotcp: Fix inconsistency source (CA_Open only when !tcp_left_out(tp))
Ilpo Järvinen [Wed, 4 Jun 2008 18:34:22 +0000 (11:34 -0700)]
tcp: Fix inconsistency source (CA_Open only when !tcp_left_out(tp))

It is possible that this skip path causes TCP to end up into an
invalid state where ca_state was left to CA_Open while some
segments already came into sacked_out. If next valid ACK doesn't
contain new SACK information TCP fails to enter into
tcp_fastretrans_alert(). Thus at least high_seq is set
incorrectly to a too high seqno because some new data segments
could be sent in between (and also, limited transmit is not
being correctly invoked there). Reordering in both directions
can easily cause this situation to occur.

I guess we would want to use tcp_moderate_cwnd(tp) there as well
as it may be possible to use this to trigger oversized burst to
network by sending an old ACK with huge amount of SACK info, but
I'm a bit unsure about its effects (mainly to FlightSize), so to
be on the safe side I just currently fixed it minimally to keep
TCP's state consistent (obviously, such nasty ACKs have been
possible this far). Though it seems that FlightSize is already
underestimated by some amount, so probably on the long term we
might want to trigger recovery there too, if appropriate, to make
FlightSize calculation to resemble reality at the time when the
losses where discovered (but such change scares me too much now
and requires some more thinking anyway how to do that as it
likely involves some code shuffling).

This bug was found by Brian Vowell while running my TCP debug
patch to find cause of another TCP issue (fackets_out
miscount).

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonetfilter: nf_conntrack_ipv6: fix inconsistent lock state in nf_ct_frag6_gather()
Jarek Poplawski [Wed, 4 Jun 2008 16:58:27 +0000 (09:58 -0700)]
netfilter: nf_conntrack_ipv6: fix inconsistent lock state in nf_ct_frag6_gather()

[   63.531438] =================================
[   63.531520] [ INFO: inconsistent lock state ]
[   63.531520] 2.6.26-rc4 #7
[   63.531520] ---------------------------------
[   63.531520] inconsistent {softirq-on-W} -> {in-softirq-W} usage.
[   63.531520] tcpsic6/3864 [HC0[0]:SC1[1]:HE1:SE0] takes:
[   63.531520]  (&q->lock#2){-+..}, at: [<c07175b0>] ipv6_frag_rcv+0xd0/0xbd0
[   63.531520] {softirq-on-W} state was registered at:
[   63.531520]   [<c0143bba>] __lock_acquire+0x3aa/0x1080
[   63.531520]   [<c0144906>] lock_acquire+0x76/0xa0
[   63.531520]   [<c07a8f0b>] _spin_lock+0x2b/0x40
[   63.531520]   [<c0727636>] nf_ct_frag6_gather+0x3f6/0x910
 ...

According to this and another similar lockdep report inet_fragment
locks are taken from nf_ct_frag6_gather() with softirqs enabled, but
these locks are mainly used in softirq context, so disabling BHs is
necessary.

Reported-and-tested-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Jarek Poplawski <jarkao2@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonetfilter: xt_connlimit: fix accouning when receive RST packet in ESTABLISHED state
Dong Wei [Wed, 4 Jun 2008 16:57:51 +0000 (09:57 -0700)]
netfilter: xt_connlimit: fix accouning when receive RST packet in ESTABLISHED state

In xt_connlimit match module, the counter of an IP is decreased when
the TCP packet is go through the chain with ip_conntrack state TW.
Well, it's very natural that the server and client close the socket
with FIN packet. But when the client/server close the socket with RST
packet(using so_linger), the counter for this connection still exsit.
The following patch can fix it which is based on linux-2.6.25.4

Signed-off-by: Dong Wei <dwei.zh@gmail.com>
Acked-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoroute: Remove unused ifa_anycast field
Thomas Graf [Tue, 3 Jun 2008 23:37:33 +0000 (16:37 -0700)]
route: Remove unused ifa_anycast field

The field was supposed to allow the creation of an anycast route by
assigning an anycast address to an address prefix. It was never
implemented so this field is unused and serves no purpose. Remove it.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonetlink: Improve returned error codes
Thomas Graf [Tue, 3 Jun 2008 23:36:54 +0000 (16:36 -0700)]
netlink: Improve returned error codes

Make nlmsg_trim(), nlmsg_cancel(), genlmsg_cancel(), and
nla_nest_cancel() void functions.

Return -EMSGSIZE instead of -1 if the provided message buffer is not
big enough.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoroute: Mark unused routing attributes as such
Thomas Graf [Tue, 3 Jun 2008 23:36:27 +0000 (16:36 -0700)]
route: Mark unused routing attributes as such

Also removes an unused policy entry for an attribute which is
only used in kernel->user direction.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoroute: Mark unused route cache flags as such.
Thomas Graf [Tue, 3 Jun 2008 23:36:01 +0000 (16:36 -0700)]
route: Mark unused route cache flags as such.

Also removes an obsolete check for the unused flag RTCF_MASQ.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonet_dma: remove duplicate assignment in dma_skb_copy_datagram_iovec
Brice Goglin [Tue, 3 Jun 2008 23:07:45 +0000 (16:07 -0700)]
net_dma: remove duplicate assignment in dma_skb_copy_datagram_iovec

No need to compute copy twice in the frags loop in
dma_skb_copy_datagram_iovec().

Signed-off-by: Brice Goglin <Brice.Goglin@inria.fr>
Acked-by: Shannon Nelson <shannon.nelson@intel.com>
Signed-off-by: Maciej Sosnowski <maciej.sosnowski@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agonet: neighbour table ABI problem
Stephen Hemminger [Tue, 3 Jun 2008 23:03:15 +0000 (16:03 -0700)]
net: neighbour table ABI problem

The neighbor table time of last use information is returned in the
incorrect unit. Kernel to user space ABI's need to use USER_HZ (or
milliseconds), otherwise the application has to try and discover the
real system HZ value which is problematic.  Linux has standardized on
keeping USER_HZ consistent (100hz) even when kernel is running
internally at some other value.

This change is small, but it breaks the ABI for older version of
iproute2 utilities.  But these utilities are already broken since they
are looking at the psched_hz values which are completely different. So
let's just go ahead and fix both kernel and user space. Older
utilities will just print wrong values.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agobridge: update URL
Adrian Bunk [Tue, 3 Jun 2008 23:00:01 +0000 (16:00 -0700)]
bridge: update URL

This patch updates the URL of the bridge homepage.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoirda: Sock leak on error path in irda_create.
Pavel Emelyanov [Tue, 3 Jun 2008 22:18:36 +0000 (15:18 -0700)]
irda: Sock leak on error path in irda_create.

Bad type/protocol specified result in sk leak.

Fix is simple - release the sk if bad values are given,
but to make it possible just to call sk_free(), I move
some sk initialization a bit lower.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agoax25: Fix NULL pointer dereference and lockup.
Jarek Poplawski [Tue, 3 Jun 2008 21:53:46 +0000 (14:53 -0700)]
ax25: Fix NULL pointer dereference and lockup.

From: Jarek Poplawski <jarkao2@gmail.com>

There is only one function in AX25 calling skb_append(), and it really
looks suspicious: appends skb after previously enqueued one, but in
the meantime this previous skb could be removed from the queue.

This patch Fixes it the simple way, so this is not fully compatible with
the current method, but testing hasn't shown any problems.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agobluetooth: rfcomm_dev_state_change deadlock fix
Dave Young [Mon, 2 Jun 2008 06:50:52 +0000 (23:50 -0700)]
bluetooth: rfcomm_dev_state_change deadlock fix

There's logic in __rfcomm_dlc_close:
rfcomm_dlc_lock(d);
d->state = BT_CLOSED;
d->state_changed(d, err);
rfcomm_dlc_unlock(d);

In rfcomm_dev_state_change, it's possible that rfcomm_dev_put try to
take the dlc lock, then we will deadlock.

Here fixed it by unlock dlc before rfcomm_dev_get in
rfcomm_dev_state_change.

why not unlock just before rfcomm_dev_put? it's because there's
another problem.  rfcomm_dev_get/rfcomm_dev_del will take
rfcomm_dev_lock, but in rfcomm_dev_add the lock order is :
rfcomm_dev_lock --> dlc lock

so I unlock dlc before the taken of rfcomm_dev_lock.

Actually it's a regression caused by commit
1905f6c736cb618e07eca0c96e60e3c024023428 ("bluetooth :
__rfcomm_dlc_close lock fix"), the dlc state_change could be two
callbacks : rfcomm_sk_state_change and rfcomm_dev_state_change. I
missed the rfcomm_sk_state_change that time.

Thanks Arjan van de Ven <arjan@linux.intel.com> for the effort in
commit 4c8411f8c115def968820a4df6658ccfd55d7f1a ("bluetooth: fix
locking bug in the rfcomm socket cleanup handling") but he missed the
rfcomm_dev_state_change lock issue.

Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years agolibertas: unify various CF-related defines
Holger Schurig [Mon, 2 Jun 2008 07:25:05 +0000 (09:25 +0200)]
libertas: unify various CF-related defines

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: removing shadowed sband
Tomas Winkler [Mon, 2 Jun 2008 17:31:57 +0000 (20:31 +0300)]
mac80211: removing shadowed sband

This patch removes doubly defined sband variable

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: fix unbalanced locking in ieee80211_get_buffered_bc
Tomas Winkler [Mon, 2 Jun 2008 17:31:56 +0000 (20:31 +0300)]
mac80211: fix unbalanced locking in ieee80211_get_buffered_bc

This patch fixes unbalanced locking in ieee80211_get_buffered_bc

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: fix panic when using hardware WEP
Pavel Roskin [Mon, 2 Jun 2008 11:54:50 +0000 (07:54 -0400)]
mac80211: fix panic when using hardware WEP

e039fa4a4195ac4ee895e6f3d1334beed63256fe ("mac80211: move TX info into
skb->cb") misplaced code for setting hardware WEP keys.  Move it back.
This fixes kernel panic in b43 if WEP is used and hardware encryption
is enabled.

Signed-off-by: Pavel Roskin <proski@gnu.org>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: fix rate control initialisation
Johannes Berg [Mon, 2 Jun 2008 07:38:04 +0000 (09:38 +0200)]
mac80211: fix rate control initialisation

In commit 2e92e6f2c50b4baf85cca968f0e6f1b5c0df7d39 ("mac80211: use rate
index in TX control") I forgot to initialise a few new variables to -1 which
means that the rate control algorithm is never triggered and 0 is used as
the only rate index, effectively fixing the transmit bitrate at the lowest
supported.

This patch adds the missing initialisation.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Bisected-by: Sitsofe Wheeler <sitsofe@yahoo.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoPS3: gelic: Add support for ESSID scan
Masakazu Mokuno [Mon, 2 Jun 2008 03:49:16 +0000 (12:49 +0900)]
PS3: gelic: Add support for ESSID scan

This adds the support for ESSID scanning

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agop54: fix skb->cb tx info conversion
Johannes Berg [Fri, 30 May 2008 19:07:15 +0000 (21:07 +0200)]
p54: fix skb->cb tx info conversion

When I moved the TX info into skb->cb apparently I forgot to change a
few places to put the p54-internal data into info->driver_data rather
than skb->cb. This should fix it.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoPS3: gelic: Deprecate the private ioctls in the gelic driver
Masakazu Mokuno [Fri, 30 May 2008 07:52:55 +0000 (16:52 +0900)]
PS3: gelic: Deprecate the private ioctls in the gelic driver

As the driver has the standard way to handle PSK, deprecate the old
interface.

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoPS3: gelic: Use the new PMK interface in the gelic driver
Masakazu Mokuno [Fri, 30 May 2008 07:52:44 +0000 (16:52 +0900)]
PS3: gelic: Use the new PMK interface in the gelic driver

With the new WEXT flags, the PS3 wireless driver can tell the user space that
it would do handle 4-way handshake by itself and needs the PSK without private
ioctls.

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoWEXT: Add support for passing PMK and capability flags to WEXT
Masakazu Mokuno [Fri, 30 May 2008 07:52:23 +0000 (16:52 +0900)]
WEXT: Add support for passing PMK and capability flags to WEXT

This defines the flags for setting the PMK to the driver and the
capability flag for this so that the user space program can figure out
whether the target driver wants to do 4-way hand shake by itself and
pass the PMK which is needed before 4-way handshake to the driver.

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoPS3: gelic: Kill the static bounce buffer
Masakazu Mokuno [Fri, 30 May 2008 07:27:42 +0000 (16:27 +0900)]
PS3: gelic: Kill the static bounce buffer

As the bounce buffer is allocaetd dynamically, kill the static bounce buffer.

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoPS3: gelic: Allocate the bounce buffer dynamically
Masakazu Mokuno [Fri, 30 May 2008 07:27:24 +0000 (16:27 +0900)]
PS3: gelic: Allocate the bounce buffer dynamically

Allocate the bouce buffer for the wireless command dynamically.

Signed-off-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: clean iwl4965_mac_config
Tomas Winkler [Thu, 29 May 2008 08:35:28 +0000 (16:35 +0800)]
iwlwifi: clean iwl4965_mac_config

This patch cleans up iwl4965_mac_config.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: send calibration results as HUGE commands
Emmanuel Grumbach [Thu, 29 May 2008 08:35:27 +0000 (16:35 +0800)]
iwlwifi: send calibration results as HUGE commands

This patch saves memory by reducing the size of the entry in the txq. It
was 640 because of the calibration commands. Calibration commands are now
sent as HUGE commands (using the extra 1024 bytes at the end of the command
txq), hence, there is no need for 640 in every entry any more.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: remove debugfs entries before cfg80211
Emmanuel Grumbach [Thu, 29 May 2008 08:35:26 +0000 (16:35 +0800)]
iwlwifi: remove debugfs entries before cfg80211

This patch solves a bug in debugfs unregistration. iwlwifi registers its
debugfs files under cfg80211's dir, but removed its files only after having
unregistered mac80211 that removes cfg80211 debugfs dir. This garbaged
debugfs and didn't allow to rmmod and insmod iwlwifi several times in a
row.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: fix a memory leak in scan
Emmanuel Grumbach [Thu, 29 May 2008 08:35:25 +0000 (16:35 +0800)]
iwlwifi: fix a memory leak in scan

This patch fixes a memory leak that the scan buffer isn't released
on exit.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: disable FAT channel when not permitted
Emmanuel Grumbach [Thu, 29 May 2008 08:35:24 +0000 (16:35 +0800)]
iwlwifi: disable FAT channel when not permitted

This patch disables FAT channel when it is not permitted according to
the EEPROM.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: allow disable FAT in specific configurations
Emmanuel Grumbach [Thu, 29 May 2008 08:35:23 +0000 (16:35 +0800)]
mac80211: allow disable FAT in specific configurations

This patch allows to disable FAT channel in specific configurations.

For example the configuration (8, +1), (primary channel 8, extension
channel 12) isn't permitted in U.S., but (8, -1), (primary channel 8,
extension channel 4) is. When FAT channel configuration is not
permitted, FAT channel should be reported as not supported in the
capabilities of the HT IE in association request. And sssociation is
performed on 20Mhz channel.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move iwl_get_hw_mode to iwl-core.h
Ron Rindjunsky [Thu, 29 May 2008 08:35:19 +0000 (16:35 +0800)]
iwlwifi: move iwl_get_hw_mode to iwl-core.h

This patch moves iwl_get_hw_mode to iwl-core.h.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: Rx handlers common use for 4965 and 5000
Ron Rindjunsky [Thu, 29 May 2008 08:35:18 +0000 (16:35 +0800)]
iwlwifi: Rx handlers common use for 4965 and 5000

This patch moves Rx handlers from iwl 4965 only use to common use along
with iwl 5000, thus enables Rx path to iwl 5000.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: add frame count limit to link quality command
Tomas Winkler [Thu, 29 May 2008 08:35:17 +0000 (16:35 +0800)]
iwlwifi: add frame count limit to link quality command

This patch adds frame count limit to link quality host command.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move aggregation code to iwl-tx.c
Tomas Winkler [Thu, 29 May 2008 08:35:16 +0000 (16:35 +0800)]
iwlwifi: move aggregation code to iwl-tx.c

This patch moves aggregation action code to iwl-tx.c in iwlcore.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move iwl_sta_modify_enable_tid_tx to iwl-sta.c
Tomas Winkler [Thu, 29 May 2008 08:35:15 +0000 (16:35 +0800)]
iwlwifi: move iwl_sta_modify_enable_tid_tx to iwl-sta.c

This patch moves iwl_sta_modify_enable_tid_tx into iwl-sta.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: iwl-5000 add rxon_assoc
Ron Rindjunsky [Thu, 29 May 2008 08:35:14 +0000 (16:35 +0800)]
iwlwifi: iwl-5000 add rxon_assoc

This patch adds rxon assoc command for 5000 HW.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: implement txq invalidate byte count table
Tomas Winkler [Thu, 29 May 2008 08:35:13 +0000 (16:35 +0800)]
iwlwifi: implement txq invalidate byte count table

This is required to overcome a bug in 5000 HW byte count table.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move tx reclaim flow into iwl-tx
Tomas Winkler [Thu, 29 May 2008 08:35:12 +0000 (16:35 +0800)]
iwlwifi: move tx reclaim flow into iwl-tx

This patch
1. moves TX reclaim flow into iwl-tx
2. separates command queue and tx queue reclaim flow

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: fix in-column rate scaling
Guy Cohen [Thu, 29 May 2008 08:35:11 +0000 (16:35 +0800)]
iwlwifi: fix in-column rate scaling

This patch fixes cases that the code raised or didn't decrease
the rate although the success ratio was not good.

Signed-off-by: Guy Cohen <guy.cohen@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move 4965 tx response into iwl-4965.c
Tomas Winkler [Thu, 29 May 2008 08:35:10 +0000 (16:35 +0800)]
iwlwifi: move 4965 tx response into iwl-4965.c

This patch moves 4965 tx repsone into iwl-4965.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwlifi: impelemnt 5000 tx response path
Ron Rindjunsky [Thu, 29 May 2008 08:35:09 +0000 (16:35 +0800)]
iwlwlifi: impelemnt 5000 tx response path

This patch implements 5000 HW tx response path.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move tx response common handlers to iwlcore
Tomas Winkler [Thu, 29 May 2008 08:35:08 +0000 (16:35 +0800)]
iwlwifi: move tx response common handlers to iwlcore

This pach moves common tx response handlers to the header files
and iwl-tx.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: add iwl5000_tx_response structure
Ron Rindjunsky [Thu, 29 May 2008 08:35:07 +0000 (16:35 +0800)]
iwlwifi: add iwl5000_tx_response structure

This patch adds iwl5000_tx_repsons structure.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: activate status ready timeout only for run time ucode
Ron Rindjunsky [Thu, 29 May 2008 08:35:06 +0000 (16:35 +0800)]
iwlwifi: activate status ready timeout only for run time ucode

This patch makes driver state timeout checks on ucode alive response
only if run time ucode have been loaded.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi-5000: implement initial calibration for 5000
Tomas Winkler [Thu, 29 May 2008 08:35:05 +0000 (16:35 +0800)]
iwlwifi-5000: implement initial calibration for 5000

This patch adds initial calibration framework for 5000 HW faimily.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move iwl_rx_missed_beacon_notif to iwl-rx.c
Tomas Winkler [Thu, 29 May 2008 08:35:04 +0000 (16:35 +0800)]
iwlwifi: move iwl_rx_missed_beacon_notif to iwl-rx.c

This patch moves iwl_rx_missed_beacon_notif rx handler to iwl-rx.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move add sta handler to iwl-sta.c
Tomas Winkler [Thu, 29 May 2008 08:35:03 +0000 (16:35 +0800)]
iwlwifi: move add sta handler to iwl-sta.c

This patch moves add_sta hander to iwl-sta.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: add remove station functionality
Tomas Winkler [Thu, 29 May 2008 08:35:02 +0000 (16:35 +0800)]
iwlwifi: add remove station functionality

This patch adds remove station functionality, which is required for
5000 and AP mode.

There are still some gaps in managment that need to be closed but it
provides sufficient functionality for 5000 HW.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move iwl_rxq_stop into iwl-rx.c
Tomas Winkler [Thu, 29 May 2008 08:35:01 +0000 (16:35 +0800)]
iwlwifi: move iwl_rxq_stop into iwl-rx.c

This patch moves iwl_rxq_stop into iwl-rx.c.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move txq_ctx_stop into iwl-tx.c
Tomas Winkler [Thu, 29 May 2008 08:35:00 +0000 (16:35 +0800)]
iwlwifi: move txq_ctx_stop into iwl-tx.c

This patch moves txq_ctx_stop into iwl-tx.c iwlcore module.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: refactor stop master function
Tomas Winkler [Thu, 29 May 2008 08:34:59 +0000 (16:34 +0800)]
iwlwifi: refactor stop master function

This patch refactors stop master function for 4965 and 5000.
Currently it duplicates the function.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: implement apm stop function
Tomas Winkler [Thu, 29 May 2008 08:34:58 +0000 (16:34 +0800)]
iwlwifi: implement apm stop function

This patch adds apm stop function for 4965 and 5000.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: implement apm reset flow
Tomas Winkler [Thu, 29 May 2008 08:34:57 +0000 (16:34 +0800)]
iwlwifi: implement apm reset flow

This patch implements apm reset flow for 4965 and 5000.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: setup correctly L1 L0S pi link values
Tomas Winkler [Thu, 29 May 2008 08:34:56 +0000 (16:34 +0800)]
iwlwifi: setup correctly L1 L0S pi link values

This patch setups L1 L0S pci link values.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: remove 4965 from alive_resp structures
Tomas Winkler [Thu, 29 May 2008 08:34:55 +0000 (16:34 +0800)]
iwlwifi: remove 4965 from alive_resp structures

This patch removes 4965 from alive_resp and init_alivie_resp.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: clean up alive_start routine
Tomas Winkler [Thu, 29 May 2008 08:34:54 +0000 (16:34 +0800)]
iwlwifi: clean up alive_start routine

This patch cleans up alive_start routine. It removes 4965 from the common
code and moves the run time calibration reset into a common code.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: remove notif_missed_beacons variable
Tomas Winkler [Thu, 29 May 2008 08:34:53 +0000 (16:34 +0800)]
iwlwifi: remove notif_missed_beacons variable

This patch removes notif_missed_beacons from priv since it was never
used. Missed beacons notification will have only meaning if roaming
will be implemented in mac80211.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: remove unused variable form __iwl4965_down
Tomas Winkler [Thu, 29 May 2008 08:34:52 +0000 (16:34 +0800)]
iwlwifi: remove unused variable form __iwl4965_down

This patch removes unused variable from __iwl4965_down.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: mark 4965 ucode types
Tomas Winkler [Thu, 29 May 2008 08:34:51 +0000 (16:34 +0800)]
iwlwifi: mark 4965 ucode types

This patch marks 4965 ucode types.

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: create drivers debugfs dir under wiphy->debugfsdir
Zhu Yi [Thu, 29 May 2008 08:34:50 +0000 (16:34 +0800)]
iwlwifi: create drivers debugfs dir under wiphy->debugfsdir

This patch creates driver's debugfs tree under wiphy->debugfsdir.
This patch fixes collision in debugfs if two or more NICs are plugged.

Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: increase max payload of iwl_cmd
Ron Rindjunsky [Thu, 29 May 2008 08:34:49 +0000 (16:34 +0800)]
iwlwifi: increase max payload of iwl_cmd

This patch increases iwl_cmd payload maximum size from 360 to 640
to fit some of iwl5000 commands as well.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: use uCode error and event tables pointer w.r.t loaded image
Gregory Greenman [Thu, 29 May 2008 08:34:48 +0000 (16:34 +0800)]
iwlwifi: use uCode error and event tables pointer w.r.t loaded image

This patch updates the usage of the pointers to error and log tables
received in alive response w.r.t. the current uCode image.

Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: add RTC data address for iwl5000
Ron Rindjunsky [Thu, 29 May 2008 08:34:47 +0000 (16:34 +0800)]
iwlwifi: add RTC data address for iwl5000

This patch fills the valid_rtc_data_addr handler in iwl5000.

Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoiwlwifi: move iwl_dump_nic_error_log to iwlcore module
Ester Kummer [Thu, 29 May 2008 08:34:46 +0000 (16:34 +0800)]
iwlwifi: move iwl_dump_nic_error_log to iwlcore module

This patch moves the function iwl_dump_nic_error_log to iwlcore.
Remove sysfs entry it cannot be really triggered.

Signed-off-by: Ester Kummer <ester.kummer@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: sends HT IE to user level through wext
Emmanuel Grumbach [Tue, 27 May 2008 17:00:11 +0000 (20:00 +0300)]
mac80211: sends HT IE to user level through wext

This patch adds HT IE in the scan list that is returned to user level
through wext. This is useful to let wpa_supplicant if a bss supports 11n or
not: WEP and TKIP are not supported in 11n.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: fix compact flash interrupt handling
Holger Schurig [Mon, 26 May 2008 10:50:23 +0000 (12:50 +0200)]
libertas: fix compact flash interrupt handling

The old code misbehaved because it polled card status and always called the
"tx over" code-path.

This also fixes a hard lockup by not allowing and card interrupts while
transferring a TX frame or a command into the card.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: rate adaptation configuration via iwconfig.
Javier Cardona [Sat, 24 May 2008 09:59:49 +0000 (10:59 +0100)]
libertas: rate adaptation configuration via iwconfig.

Implemented rate adaptation support via 'iwconfig rate' API.  It is now
possible to specify a bit-rate value and append 'auto'.  That will configure
rate adaptation to use all bit-rates equal or lower than than selected value.

Made lbs_cmd_802_11_rate_adapt_rateset a direct command.

Signed-off-by: Javier Cardona <javier@cozybit.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agob43legacy: fix build errors when DMA or PIO are not selected
Johannes Berg [Sat, 24 May 2008 18:07:55 +0000 (20:07 +0200)]
b43legacy: fix build errors when DMA or PIO are not selected

Currently, b43legacy is broken due to

commit fbad4598ca826b994d0fd4ce3deebc9cd1960b31
Author: Johannes Berg <johannes@sipsolutions.net>
Date:   Thu May 15 12:55:29 2008 +0200

    mac80211: move TX info into skb->cb

when compiled with only PIO or only DMA because I forgot to update two
stubs. This patch fixes it.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: fix deadlock in sta->lock
Tomas Winkler [Tue, 27 May 2008 14:50:52 +0000 (17:50 +0300)]
mac80211: fix deadlock in sta->lock

This patch fixes a deadlock of sta->lock use, occurring while changing
tx aggregation states, as dev_queue_xmit end up in new function
test_and_clear_sta_flags that uses that lock thus leading to deadlock

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: fix ieee80211_get_buffered_bc
Tomas Winkler [Tue, 27 May 2008 14:50:51 +0000 (17:50 +0300)]
mac80211: fix ieee80211_get_buffered_bc

fix bss not initialized in ieee80211_get_buffered_bc
and unbalanced locking

Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agorndis_wlan: use ARRAY_SIZE instead of sizeof when adding 11g rates
Scott Ashcroft [Tue, 27 May 2008 08:15:02 +0000 (11:15 +0300)]
rndis_wlan: use ARRAY_SIZE instead of sizeof when adding 11g rates

While figuring out the TKIP problem I found a bug in the code which adds the 11g
rates. It's using sizeof instead of ARRAY_SIZE to terminate the for loop. This makes
it fall off the end of the rates array start into the frequency array instead. Running
"iwlist rate" should show the problem as there will always be 32 rates with the last
few being bogus.

The following patch will fix it.

Signed-off-by: Scott Ashcroft <scott.ashcroft@talk21.com>
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agoath5k: use IEEE80211_SKB_CB
Johannes Berg [Mon, 26 May 2008 14:43:39 +0000 (16:43 +0200)]
ath5k: use IEEE80211_SKB_CB

ath5k still uses the "(void*) skb->cb" direct cast, use IEEE80211_SKB_CB
instead.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: before sleeping, check for a command result
Holger Schurig [Fri, 23 May 2008 14:04:13 +0000 (16:04 +0200)]
libertas: before sleeping, check for a command result

If we don't check for a command response early, but rather sleep,
then we might sleep despite an already-received command response.
This will lead to a command-timeout.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: use lbs_pr_XX instead of printk
Holger Schurig [Fri, 23 May 2008 10:16:51 +0000 (12:16 +0200)]
libertas: use lbs_pr_XX instead of printk

... because lbs_pr_XXX prefixes all messages with "libertas: "

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: speeds up downloading of CF firmware
Holger Schurig [Fri, 23 May 2008 08:18:26 +0000 (10:18 +0200)]
libertas: speeds up downloading of CF firmware

Keep the timeout the same (1000*500 == 100000 * 5), but take shorter
naps. Makes downloading the firmware slightly faster.

Signed-off-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agolibertas: don't spin_unlock_irq() twice
Holger Schurig [Fri, 23 May 2008 08:07:56 +0000 (10:07 +0200)]
libertas: don't spin_unlock_irq() twice

priv->driver_lock has already been unlocked some lines above. This patch
fixes the sparse warning:

drivers/net/wireless/libertas/main.c:792:6: warning: context problem in 'lbs_thread': '_spin_unlock_irq' expected different context
drivers/net/wireless/libertas/main.c:792:6:    context 'lock': wanted >= 1, got 0

Signed-of-by: Holger Schurig <hs4233@mail.mn-solutions.de>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agomac80211: clean up skb reallocation code
Johannes Berg [Thu, 29 May 2008 08:38:53 +0000 (10:38 +0200)]
mac80211: clean up skb reallocation code

This cleans up the skb reallocation code to avoid problems with
skb->truesize, not resize an skb twice for a single output path
because we didn't expand it enough during the first copy and also
removes the code to further expand it during crypto operations
which will no longer be necessary.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
16 years agops3: gelic: updown_lock semaphore to mutex
Daniel Walker [Thu, 22 May 2008 07:00:03 +0000 (00:00 -0700)]
ps3: gelic: updown_lock semaphore to mutex

Signed-off-by: Daniel Walker <dwalker@mvista.com>
Acked-by: Masakazu Mokuno <mokuno@sm.sony.co.jp>
Signed-off-by: John W. Linville <linville@tuxdriver.com>