net: feed /dev/random with the MAC address when registering a device

commit 7bf2357524408b97fec58344caf7397f8140c3fd upstream.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Cc: David Miller <davem@davemloft.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Patrick Tjin <pattjin@google.com>
ipv6: use a stronger hash for tcp

It looks like its possible to open thousands of TCP IPv6
sessions on a server, all landing in a single slot of TCP hash
table. Incoming packets have to lookup sockets in a very
long list.

We should hash all bits from foreign IPv6 addresses, using
a salt and hash mix, not a simple XOR.

inet6_ehashfn() can also separately use the ports, instead
of xoring them.

Reported-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Yuchung Cheng <ycheng@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Iliyan Malchev <malchev@google.com>

Conflicts:
	include/net/ipv6.h
net: defer net_secret[] initialization

Instead of feeding net_secret[] at boot time, defer the init
at the point first socket is created.

This permits some platforms to use better entropy sources than
the ones available at boot time.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net-fixes: flow_dissector: prevent an infinite loop (CVE-2013-4348)

Jason Wang found that a malicious packet could make skb_flow_dissect()
loop forever. We must check that IP header has a valid ihl to avoid
this loop. It involves IPIP encapsulation and ihl = 0 to trigger.

Given this bug is critical, I cooked a patch before having
a fix in upstream kernel.

Tested:

 Compiled/booted
 Ran some tests on bnx2x and explicitely disabled hardware provided rxhash
 ethtool -K eth1 rxhash off
 ethtool -K eth2 rxhash off

Google-Bug-Id: 11465355
Effort: net-fixes
Change-Id: I813e4dc48cecb05f8edfa218304e1f13fd764323
Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
cfg80211: Fix memory leak

When a driver requests a specific regulatory domain after cfg80211 already
has one, a struct ieee80211_regdomain is leaked.

Change-Id: Id28fc9861b9c911a97bd242439eabca097d76258
Reported-by: Larry Finger <Larry.Finger@lwfinger.net>
Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Git-commit: b7566fc363e23f0efd3fa1e1460f9421cdc0d77e
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
[mattw@codeaurora.org: trivially backport to the msm-3.4 kernel]
Signed-off-by: Matt Wagantall <mattw@codeaurora.org>
msm: mdss: Change the Alpha scaling type to bilinear

Currently, for Alpha plane the filter used is nearest due to which
there is an aliasing effect. Using the same filter as graphics core
which is bilinear, the aliasing effect is avoided.

CRs-fixed: 517627
Change-Id: Ifb4629ddcea1ac447d151469b1f56e3400b7fac0
Signed-off-by: Sree Sesha Aravind Vadrevu <svadrevu@codeaurora.org>
mdss: display: Check for non-zero msleep values for LDOs

Change LDO power on/off sequence to check for
non-zero sleep values to prevent input values
of 0 from sleeping for a jiffy.

Change-Id: I66c0ded92e9c76bd43364de701effa96f0d5c9a5
CRs-Fixed: 514628
Signed-off-by: Casey Piper <cpiper@codeaurora.org>
msm: mdss: WARN typo correction

WARN typo correction

Change-Id: I8bbb8e63d3b5f5953ba7e629434c18f3ab29dbb8
Signed-off-by: Se Hun Kim <sean2.kim@lge.com>
mdss: Remove lock from vsync control

The lock protecting the vsync control ioctl is not needed since
the vsync control should take effect immediately and be
asynchronous to the display updates.

Change-Id: I5068246488b7fefec9e11e8422bacbe7489c827f
Signed-off-by: Naseer Ahmed <naseer@codeaurora.org>
msm: mdss: remove cleanup done during overlay kickoff

Remove kickoff done from overlay kickoff, this was done to clear
potentially stale handles when the process using it has crashed. However
this case is handled in commit a3b3d215 by handling per process
resources.

Change-Id: I9c060b107c004c6cfb726ad84ae69d77461ed74f
Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
Signed-off-by: Naseer Ahmed <naseer@codeaurora.org>