]> Git Repo - linux.git/log
linux.git
10 years agocxgb4: Delete an unnecessary check before the function call "release_firmware"
Markus Elfring [Wed, 4 Feb 2015 10:28:43 +0000 (11:28 +0100)]
cxgb4: Delete an unnecessary check before the function call "release_firmware"

The release_firmware() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agocxgb4: Add low latency socket busy_poll support
Hariprasad Shenai [Wed, 4 Feb 2015 10:02:52 +0000 (15:32 +0530)]
cxgb4: Add low latency socket busy_poll support

cxgb_busy_poll, corresponding to ndo_busy_poll, gets called by the socket
waiting for data.

With busy_poll enabled, improvement is seen in latency numbers as observed by
collecting netperf TCP_RR numbers.
Below are latency number, with and without busy-poll, in a switched environment
for a particular msg size:
netperf command: netperf -4 -H <ip> -l 30 -t TCP_RR -- -r1,1
Latency without busy-poll: ~16.25 us
Latency with busy-poll   : ~08.79 us

Based on original work by Kumar Sanghvi <[email protected]>

Signed-off-by: Hariprasad Shenai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoRevert "bridge: Let bridge not age 'externally' learnt FDB entries, they are removed...
David S. Miller [Thu, 5 Feb 2015 07:52:44 +0000 (23:52 -0800)]
Revert "bridge: Let bridge not age 'externally' learnt FDB entries, they are removed when 'external' entity notifies the aging"

This reverts commit 9a05dde59a35eee5643366d3d1e1f43fc9069adb.

Requested by Scott Feldman.

Signed-off-by: David S. Miller <[email protected]>
10 years agohrtimer: Fix incorrect tai offset calculation for non high-res timer systems
John Stultz [Thu, 5 Feb 2015 00:45:26 +0000 (16:45 -0800)]
hrtimer: Fix incorrect tai offset calculation for non high-res timer systems

I noticed some CLOCK_TAI timer test failures on one of my
less-frequently used configurations. And after digging in I
found in 76f4108892d9 (Cleanup hrtimer accessors to the
timekepeing state), the hrtimer_get_softirq_time tai offset
calucation was incorrectly rewritten, as the tai offset we
return shold be from CLOCK_MONOTONIC, and not CLOCK_REALTIME.

This results in CLOCK_TAI timers expiring early on non-highres
capable machines.

This patch fixes the issue, calculating the tai time properly
from the monotonic base.

Signed-off-by: John Stultz <[email protected]>
Cc: Thomas Gleixner <[email protected]>
Cc: stable <[email protected]> # 3.17+
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
10 years agopkt_sched: fq: better control of DDOS traffic
Eric Dumazet [Thu, 5 Feb 2015 05:30:40 +0000 (21:30 -0800)]
pkt_sched: fq: better control of DDOS traffic

FQ has a fast path for skb attached to a socket, as it does not
have to compute a flow hash. But for other packets, FQ being non
stochastic means that hosts exposed to random Internet traffic
can allocate million of flows structure (104 bytes each) pretty
easily. Not only host can OOM, but lookup in RB trees can take
too much cpu and memory resources.

This patch adds a new attribute, orphan_mask, that is adding
possibility of having a stochastic hash for orphaned skb.

Its default value is 1024 slots, to mimic SFQ behavior.

Note: This does not apply to locally generated TCP traffic,
and no locally generated traffic will share a flow structure
with another perfect or stochastic flow.

This patch also handles the specific case of SYNACK messages:

They are attached to the listener socket, and therefore all map
to a single hash bucket. If listener have set SO_MAX_PACING_RATE,
hoping to have new accepted socket inherit this rate, SYNACK
might be paced and even dropped.

This is very similar to an internal patch Google have used more
than one year.

Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoMerge tag 'asoc-v3.20-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie...
Takashi Iwai [Thu, 5 Feb 2015 06:08:35 +0000 (07:08 +0100)]
Merge tag 'asoc-v3.20-2' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next

ASoC: Updates for v3.20

More updates for v3.20:

 - Lots of refactoring from Lars-Peter Clausen, moving drivers to more
   data driven initialization and rationalizing a lot of DAPM usage.
 - Much improved handling of CDCLK clocks on Samsung I2S controllers.
 - Lots of driver specific cleanups and feature improvements.
 - CODEC support for TI PCM514x and TLV320AIC3104 devices.
 - Board support for Tegra systems with Realtek RT5677.

Conflicts:
sound/soc/intel/sst-mfld-platform-pcm.c

10 years agoMerge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
David S. Miller [Thu, 5 Feb 2015 04:46:55 +0000 (20:46 -0800)]
Merge branch 'for-davem' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs

More iov_iter work from Al Viro.

Signed-off-by: David S. Miller <[email protected]>
10 years agotcp: do not pace pure ack packets
Eric Dumazet [Wed, 4 Feb 2015 02:31:53 +0000 (18:31 -0800)]
tcp: do not pace pure ack packets

When we added pacing to TCP, we decided to let sch_fq take care
of actual pacing.

All TCP had to do was to compute sk->pacing_rate using simple formula:

sk->pacing_rate = 2 * cwnd * mss / rtt

It works well for senders (bulk flows), but not very well for receivers
or even RPC :

cwnd on the receiver can be less than 10, rtt can be around 100ms, so we
can end up pacing ACK packets, slowing down the sender.

Really, only the sender should pace, according to its own logic.

Instead of adding a new bit in skb, or call yet another flow
dissection, we tweak skb->truesize to a small value (2), and
we instruct sch_fq to use new helper and not pace pure ack.

Note this also helps TCP small queue, as ack packets present
in qdisc/NIC do not prevent sending a data packet (RPC workload)

This helps to reduce tx completion overhead, ack packets can use regular
sock_wfree() instead of tcp_wfree() which is a bit more expensive.

This has no impact in the case packets are sent to loopback interface,
as we do not coalesce ack packets (were we would detect skb->truesize
lie)

In case netem (with a delay) is used, skb_orphan_partial() also sets
skb->truesize to 1.

This patch is a combination of two patches we used for about one year at
Google.

Signed-off-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoMerge branch 'rhashtable-next'
David S. Miller [Thu, 5 Feb 2015 04:35:05 +0000 (20:35 -0800)]
Merge branch 'rhashtable-next'

Herbert Xu says:

====================
rhashtable: Add iterators and use them

The first patch fixes a potential crash with nft_hash destroying
the table during a shrinking process.  While the next patch adds
rhashtable iterators to replace current manual walks used by
netlink and netfilter.  The final two patches make use of these
iterators in netlink and netfilter.
====================

Signed-off-by: David S. Miller <[email protected]>
10 years agonetfilter: Use rhashtable walk iterator
Herbert Xu [Tue, 3 Feb 2015 20:33:25 +0000 (07:33 +1100)]
netfilter: Use rhashtable walk iterator

This patch gets rid of the manual rhashtable walk in nft_hash
which touches rhashtable internals that should not be exposed.
It does so by using the rhashtable iterator primitives.

Note that I'm leaving nft_hash_destroy alone since it's only
invoked on shutdown and it shouldn't be affected by changes
to rhashtable internals (or at least not what I'm planning to
change).

Signed-off-by: Herbert Xu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonetlink: Use rhashtable walk iterator
Herbert Xu [Tue, 3 Feb 2015 20:33:24 +0000 (07:33 +1100)]
netlink: Use rhashtable walk iterator

This patch gets rid of the manual rhashtable walk in netlink
which touches rhashtable internals that should not be exposed.
It does so by using the rhashtable iterator primitives.

In fact the existing code was very buggy.  Some sockets weren't
shown at all while others were shown more than once.

Signed-off-by: Herbert Xu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agorhashtable: Introduce rhashtable_walk_*
Herbert Xu [Tue, 3 Feb 2015 20:33:23 +0000 (07:33 +1100)]
rhashtable: Introduce rhashtable_walk_*

Some existing rhashtable users get too intimate with it by walking
the buckets directly.  This prevents us from easily changing the
internals of rhashtable.

This patch adds the helpers rhashtable_walk_init/exit/start/next/stop
which will replace these custom walkers.

They are meant to be usable for both procfs seq_file walks as well
as walking by a netlink dump.  The iterator structure should fit
inside a netlink dump cb structure, with at least one element to
spare.

Signed-off-by: Herbert Xu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agorhashtable: Fix potential crash on destroy in rhashtable_shrink
Herbert Xu [Tue, 3 Feb 2015 20:33:22 +0000 (07:33 +1100)]
rhashtable: Fix potential crash on destroy in rhashtable_shrink

The current being_destroyed check in rhashtable_expand is not
enough since if we start a shrinking process after freeing all
elements in the table that's also going to crash.

This patch adds a being_destroyed check to the deferred worker
thread so that we bail out as soon as we take the lock.

Signed-off-by: Herbert Xu <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoamd-xgbe: Set RSS enablement based on hardware features
Lendacky, Thomas [Tue, 3 Feb 2015 20:14:32 +0000 (14:14 -0600)]
amd-xgbe: Set RSS enablement based on hardware features

The RSS support requires enablement based on the features reported by
the hardware. The setting of this flag is missing. Add support to
set the RSS enablement flag based on the reported hardware features.

Signed-off-by: Tom Lendacky <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoNetCP: Deletion of unnecessary checks before two function calls
Markus Elfring [Tue, 3 Feb 2015 19:12:25 +0000 (20:12 +0100)]
NetCP: Deletion of unnecessary checks before two function calls

The functions cpsw_ale_destroy() and of_dev_put() test whether their argument
is NULL and then return immediately. Thus the test around the call
is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoIBM-EMAC: Delete an unnecessary check before the function call "of_dev_put"
Markus Elfring [Tue, 3 Feb 2015 18:47:33 +0000 (19:47 +0100)]
IBM-EMAC: Delete an unnecessary check before the function call "of_dev_put"

The of_dev_put() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoamd-xgbe: Adjust for zero-based traffic class count
Lendacky, Thomas [Tue, 3 Feb 2015 18:49:55 +0000 (12:49 -0600)]
amd-xgbe: Adjust for zero-based traffic class count

The number of traffic classes reported by the hardware is zero-based
so increment the value returned to get an actual count.

Signed-off-by: Tom Lendacky <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agocls_api.c: Fix dumping of non-existing actions' stats.
Ignacy Gawędzki [Tue, 3 Feb 2015 18:05:18 +0000 (19:05 +0100)]
cls_api.c: Fix dumping of non-existing actions' stats.

In tcf_exts_dump_stats(), ensure that exts->actions is not empty before
accessing the first element of that list and calling tcf_action_copy_stats()
on it.  This fixes some random segvs when adding filters of type "basic" with
no particular action.

This also fixes the dumping of those "no-action" filters, which more often
than not made calls to tcf_action_copy_stats() fail and consequently netlink
attributes added by the caller to be removed by a call to nla_nest_cancel().

Fixes: 33be62715991 ("net_sched: act: use standard struct list_head")
Signed-off-by: Ignacy Gawędzki <[email protected]>
Acked-by: Cong Wang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agopkt_sched: fq: avoid hang when quantum 0
Kenneth Klette Jonassen [Tue, 3 Feb 2015 16:49:18 +0000 (17:49 +0100)]
pkt_sched: fq: avoid hang when quantum 0

Configuring fq with quantum 0 hangs the system, presumably because of a
non-interruptible infinite loop. Either way quantum 0 does not make sense.

Reproduce with:
sudo tc qdisc add dev lo root fq quantum 0 initial_quantum 0
ping 127.0.0.1

Signed-off-by: Kenneth Klette Jonassen <[email protected]>
Acked-by: Eric Dumazet <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoBtrfs: add missing blk_finish_plug in btrfs_sync_log()
Forrest Liu [Fri, 30 Jan 2015 11:42:12 +0000 (19:42 +0800)]
Btrfs: add missing blk_finish_plug in btrfs_sync_log()

Add missing blk_finish_plug in btrfs_sync_log()

Signed-off-by: Forrest Liu <[email protected]>
Reviewed-by: David Sterba <[email protected]>
Signed-off-by: Chris Mason <[email protected]>
10 years agodrm/cirrus: Limit modes depending on bpp option
Takashi Iwai [Tue, 3 Feb 2015 16:51:23 +0000 (17:51 +0100)]
drm/cirrus: Limit modes depending on bpp option

The commit [8975626ea35a: drm/cirrus: allow 32bpp framebuffers for
cirrus drm] broke X modesetting driver because cirrus driver still
provides the full list of modes up to 1280x1024 while the 32bpp can
support only up to 800x600.

We might be able to filter out the invalid modes in mode_valid
callback, but unfortunately the bpp in question can't be referred
there for now (let me know if there is a better way to retrieve the
bpp for the probed fb).

So, instead, this patch adds the bpp module option to specify the
maximal bpp explicitly and limits the resolutions in get_modes
depending on its value.

The default value is set to 24 so that the existing stuff keeps
working.  If you need a new 32bpp feature, specify cirrus.bpp=32
option explicitly.

Fixes: 8975626ea35a ('drm/cirrus: allow 32bpp framebuffers for cirrus drm')
Signed-off-by: Takashi Iwai <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
10 years agoMerge branch 'mlx4-next'
David S. Miller [Thu, 5 Feb 2015 00:17:51 +0000 (16:17 -0800)]
Merge branch 'mlx4-next'

Amir Vadai says:

====================
Mellanox drivers updates Feb-03-2015

This patchset introduces some small bug fixes and code cleanups in mlx4_core,
mlx4_en and mlx5_core.
I am sending it in parallel to the patchset sent by Or Gerlitz today [1] because
this is the end of the time frame for 3.20. I also checked that there are no
conflicts between those two patchsets (Or's patchset is focused on the bonding
area while this on Mellanox drivers).

The patchset was applied on top of commit 7d37d0c ('net: sctp: Deletion of an
unnecessary check before the function call "kfree"')

[1] - [PATCH 00/10] Add HA and LAG support to mlx4 RoCE and SRIOV services
      http://marc.info/?l=linux-netdev&m=142297582610254&w=2
====================

Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_en: Notify TX Vlan offload change
Ido Shamay [Tue, 3 Feb 2015 15:57:21 +0000 (17:57 +0200)]
net/mlx4_en: Notify TX Vlan offload change

Notify users when TX vlan offload feature changed with ethtool.
Relevant command - ethtool -K <eth> txvlan on/off.

Signed-off-by: Ido Shamay <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_en: Adjust RX frag strides to frag sizes
Ido Shamay [Tue, 3 Feb 2015 15:57:20 +0000 (17:57 +0200)]
net/mlx4_en: Adjust RX frag strides to frag sizes

This patch improves memory utilization and therefore the packets rate
for special MTU's. Instead of setting the frag_stride to the maximal
hard coded frag_size, use the actual frag_size that is set according to
the MTU, when setting the stride of the last frag.
So, for example, for MTU 1600, where the frag_size of the 2nd frag is
86, the frag_size is set to 128 instead of 4096. See below:

Before:
 frag:0 - size:1536 prefix:0 stride:1536
 frag:1 - size:86 prefix:1536 stride:4096

 frag 0 allocator: - size:32768 frags:21
 frag 1 allocator: - size:32768 frags:8

After:
 frag:0 - size:1536 prefix:0 stride:1536
 frag:1 - size:86 prefix:1536 stride:128

 frag 0 allocator: - size:32768 frags:21
 frag 1 allocator: - size:32768 frags:256

Signed-off-by: Ido Shamay <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_en: Print page allocator information
Ido Shamay [Tue, 3 Feb 2015 15:57:19 +0000 (17:57 +0200)]
net/mlx4_en: Print page allocator information

After Initialization of page_alloc, print actual allocated page
size and number of frags it contains. prints is done only when drv
message level is set on the interface.

Signed-off-by: Ido Shamay <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx5_core: Move to use hex PCI device IDs
Or Gerlitz [Tue, 3 Feb 2015 15:57:18 +0000 (17:57 +0200)]
net/mlx5_core: Move to use hex PCI device IDs

Align the IDs in the code with the modinfo, lspci -n, etc tools outputs.

Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_core: Fix misleading debug print on CQE stride support
Or Gerlitz [Tue, 3 Feb 2015 15:57:17 +0000 (17:57 +0200)]
net/mlx4_core: Fix misleading debug print on CQE stride support

We do support cache line sizes of 32 and 64 bytes without activating the
CQE stride feature. Fix a misleading print saying that these cache line
sizes aren't supported.

Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4: mlx4_config_dev_retrieval() - Initialize struct config_dev before using
Maor Gottlieb [Tue, 3 Feb 2015 15:57:16 +0000 (17:57 +0200)]
net/mlx4: mlx4_config_dev_retrieval() - Initialize struct config_dev before using

Add Initialization to struct config_dev before filling and using it.
Fix to warning:

warning: config_dev.rx_checksum_val may be used uninitialized in this function

Signed-off-by: Maor Gottlieb <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_core: Fix mpt_entry initialization in mlx4_mr_rereg_mem_write()
Maor Gottlieb [Tue, 3 Feb 2015 15:57:15 +0000 (17:57 +0200)]
net/mlx4_core: Fix mpt_entry initialization in mlx4_mr_rereg_mem_write()

a) Previously, mlx4_mr_rereg_write filled the MPT's start
   and length with the old MPT's values.
   Fixing the initialization to take the new start and length.

b) In addition access flags in mpt_status were initialized instead of
   status due to bad boolean operation. Fixing the operation.

c) Initialization of pd_slave caused a protection error.
   Fix - removing this initialization.

d) In resource_tracker.c: Fixing vf encoding to be one-based.

Fixes: e630664c ('mlx4_core: Add helper functions to support MR re-registration')
Signed-off-by: Maor Gottlieb <[email protected]>
Signed-off-by: Amir Vadai <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoMerge branch 'mlx4-next'
David S. Miller [Thu, 5 Feb 2015 00:14:29 +0000 (16:14 -0800)]
Merge branch 'mlx4-next'

Or Gerlitz says:

====================
Add HA and LAG support to mlx4 RoCE and SRIOV services

This series takes advanges of bonding mlx4 Ethernet devices to support
a model of High-Availability and Link Aggregation for more environments.

The mlx4 driver reacts on netdev events generated by bonding when
slave state changes happen by programming a HW V2P (Virt-to-Phys)
port table. Bonding was extended to expose these state changes
through netdev events.

When an mlx4 interface such as the mlx4 IB/RoCE driver is subject to
this policy, QPs are created over virtual ports which are mapped
to one of the two physical ports. When a failure happens, the
re-programming of the V2P table allows traffic to keep flowing.

The mlx4 Ethernet driver interfaces are not subject to this
policy and act as usual.

A 2nd use-case for this model would be to add HA and Link Aggregation
support to single ported mlx4 Ethernet VFs. In this case, the PF Ethernet
intrfaces are bonded, all the VFs see single port devices (which is
supported already today), and VF QPs are subject to V2P.
====================

Signed-off-by: David S. Miller <[email protected]>
10 years agoIB/mlx4: Load balance ports in port aggregation mode
Moni Shoua [Tue, 3 Feb 2015 14:48:39 +0000 (16:48 +0200)]
IB/mlx4: Load balance ports in port aggregation mode

When the mlx4 IB (RoCE) device works in link aggregation mode, it
exposes a single port to upper layers. Therefore, applications always
set '1' in port_num attribute when modifying a QP or creating an address handle.

To make sure that a node uses all available ports the mlx4 driver will
override the port_num attribute with a round robin policy.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoIB/mlx4: Create mirror flows in port aggregation mode
Moni Shoua [Tue, 3 Feb 2015 14:48:38 +0000 (16:48 +0200)]
IB/mlx4: Create mirror flows in port aggregation mode

In port aggregation mode flows for port #1 (the only port) should be mirrored
on port #2. This is because packets can arrive from either physical ports.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoIB/mlx4: Add port aggregation support
Moni Shoua [Tue, 3 Feb 2015 14:48:37 +0000 (16:48 +0200)]
IB/mlx4: Add port aggregation support

Register the interface with the mlx4 core driver with port aggregation support
and check for port aggregation mode when the 'add' function is called.

In this mode, only one physical port is reported to the upper layer
(RoCE/IB core stack and ULPs).

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoIB/mlx4: Reuse mlx4_mac_to_u64()
Moni Shoua [Tue, 3 Feb 2015 14:48:36 +0000 (16:48 +0200)]
IB/mlx4: Reuse mlx4_mac_to_u64()

This function is implemented twice... get rid of one copy.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_en: Port aggregation configuration
Moni Shoua [Tue, 3 Feb 2015 14:48:34 +0000 (16:48 +0200)]
net/mlx4_en: Port aggregation configuration

Capture NETDEV events generated by the bonding driver and based on that
make decisions of how to configure port aggregation in the mlx4 core driver.

This includes setting the V2P port table and re-creating the interested
interfaces in bonded/non-bonded mode.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_core: Port aggregation upper layer interface
Moni Shoua [Tue, 3 Feb 2015 14:48:33 +0000 (16:48 +0200)]
net/mlx4_core: Port aggregation upper layer interface

Supply interface functions to bond and unbond ports of a mlx4 internal
interfaces. Example for such an interface is the one registered by the
mlx4 IB driver under RoCE.

There are

1. Functions to go in/out to/from bonded mode
2. Function to remap virtual ports to physical ports

The bond_mutex prevents simultaneous access to data that keep status of
the device in bonded mode.

The upper mlx4 interface marks to the mlx4 core module that they
want to be subject for such bonding by setting the MLX4_INTFF_BONDING
flag. Interface which goes to/from bonded mode is re-created.

The mlx4 Ethernet driver does not set this flag when registering the
interface, the IB driver does.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/mlx4_core: Port aggregation low level interface
Moni Shoua [Tue, 3 Feb 2015 14:48:32 +0000 (16:48 +0200)]
net/mlx4_core: Port aggregation low level interface

Implement the hardware interface required for port aggregation.

1. Disable RX port check on receive - don't perform a validity check
that matches to QP's port and the port where the packet is received.

2. Virtual to physical port remap - configure virtual to physical port
mapping. Port remap capability for virtual functions.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/bonding: Notify state change on slaves
Moni Shoua [Tue, 3 Feb 2015 14:48:31 +0000 (16:48 +0200)]
net/bonding: Notify state change on slaves

Use notifier chain to dispatch an event upon a change in slave state.
Event is dispatched with slave specific info.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/bonding: Move slave state changes to a helper function
Moni Shoua [Tue, 3 Feb 2015 14:48:30 +0000 (16:48 +0200)]
net/bonding: Move slave state changes to a helper function

Move slave state changes to a helper function, this is a pre-step for adding
functionality of dispatching an event when this helper is called.

This commit doesn't add new functionality.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet/core: Add event for a change in slave state
Moni Shoua [Tue, 3 Feb 2015 14:48:29 +0000 (16:48 +0200)]
net/core: Add event for a change in slave state

Add event which provides an indication on a change in the state
of a bonding slave. The event handler should cast the pointer to the
appropriate type (struct netdev_bonding_info) in order to get the
full info about the slave.

Signed-off-by: Moni Shoua <[email protected]>
Signed-off-by: Or Gerlitz <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoxfs: xfs_ioctl_setattr_check_projid can be static
kbuild test robot [Thu, 5 Feb 2015 00:13:21 +0000 (11:13 +1100)]
xfs: xfs_ioctl_setattr_check_projid can be static

fs/xfs/xfs_ioctl.c:1146:1: sparse: symbol 'xfs_ioctl_setattr_check_projid' was not declared. Should it be static?

Also fix xfs_ioctl_setattr_check_extsize at the same time.

Signed-off-by: Fengguang Wu <[email protected]>
Reviewed-by: Dave Chinner <[email protected]>
Signed-off-by: Dave Chinner <[email protected]>
10 years agoxfs: growfs should use synchronous transactions
Christoph Hellwig [Thu, 5 Feb 2015 00:13:21 +0000 (11:13 +1100)]
xfs: growfs should use synchronous transactions

Growfs updates the secondary superblocks using synchronous unlogged
buffer writes after committing the updates to the primary superblock.

Mark the transaction to the primary superblock as synchronous so that
we guarantee it is committed to disk before we update the secondary
superblocks.

Signed-off-by: Christoph Hellwig <[email protected]>
Reviewed-by: Dave Chinner <[email protected]>
Signed-off-by: Dave Chinner <[email protected]>
10 years agoMerge branch 'tipc-next'
David S. Miller [Thu, 5 Feb 2015 00:09:38 +0000 (16:09 -0800)]
Merge branch 'tipc-next'

Jon Maloy says:

====================
tipc: some small fixes

During extensive testing and analysis of running dual links between
nodes, we have encountered some issues that potentially may cause
problems. We choose to fix those proactively in this series.
====================

Signed-off-by: David S. Miller <[email protected]>
10 years agotipc: separate link starting event from link timeout event
Jon Paul Maloy [Tue, 3 Feb 2015 13:59:20 +0000 (08:59 -0500)]
tipc: separate link starting event from link timeout event

When a new link instance is created, it is trigged to start by
sending it a TIPC_STARTING_EVT, whereafter a regular link
reset is applied to it.

The starting event is codewise treated as a timeout event, and prompts
a link RESET message to be sent to the peer node, carrying a link
session identifier. The later link_reset() call nudges this session
identifier, whereafter all subsequent RESET messages will be sent out
with the new identifier. The latter session number overrides the former,
causing the peer to unconditionally accept it irrespective of its
current working state.

We don't think that this causes any problem, but it is not in accordance
with the protocol spec, and may cause confusion when debugging TIPC
sessions.

To avoid this, we make the starting event distinct from the
subsequent timeout events, by not allowing the former to send
out any RESET message. This eliminates the described problem.

Reviewed-by: Erik Hugne <[email protected]>
Reviewed-by: Ying Xue <[email protected]>
Signed-off-by: Jon Maloy <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agotipc: eliminate race during node creation
Jon Paul Maloy [Tue, 3 Feb 2015 13:59:19 +0000 (08:59 -0500)]
tipc: eliminate race during node creation

Instances of struct node are created in the function tipc_disc_rcv()
under the assumption that there is no race between received discovery
messages arriving from the same node. This assumption is wrong.
When we use more than one bearer, it is possible that discovery
messages from the same node arrive at the same moment, resulting in
creation of two instances of struct tipc_node. This may later cause
confusion during link establishment, and may result in one of the links
never becoming activated.

We fix this by making lookup and potential creation of nodes atomic.
Instead of first looking up the node, and in case of failure, create it,
we now start with looking up the node inside node_link_create(), and
return a reference to that one if found. Otherwise, we go ahead and
create the node as we did before.

Reviewed-by: Erik Hugne <[email protected]>
Reviewed-by: Ying Xue <[email protected]>
Signed-off-by: Jon Maloy <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agotipc: avoid stale link after aborted failover
Jon Paul Maloy [Tue, 3 Feb 2015 13:59:18 +0000 (08:59 -0500)]
tipc: avoid stale link after aborted failover

During link failover it may happen that the remaining link goes
down while it is still in the process of taking over traffic
from a previously failed link. When this happens, we currently
abort the failover procedure and reset the first failed link to
non-failover mode, so that it will be ready to re-establish
contact with its peer when it comes available.

However, if the first link goes down because its bearer was manually
disabled, it is not enough to reset it; it must also be deleted;
which is supposed to happen when the failover procedure is finished.
Otherwise it will remain a zombie link: attached to the owner node
structure, in mode LINK_STOPPED, and permanently blocking any re-
establishing of the link to the peer via the interface in question.

We fix this by amending the failover abort procedure. Apart from
resetting the link to non-failover state, we test if the link is
also in LINK_STOPPED mode. If so, we delete it, using the conditional
tipc_link_delete() function introduced in the previous commit.

Reviewed-by: Erik Hugne <[email protected]>
Reviewed-by: Ying Xue <[email protected]>
Signed-off-by: Jon Maloy <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agotipc: add reference count to struct tipc_link
Jon Paul Maloy [Tue, 3 Feb 2015 13:59:17 +0000 (08:59 -0500)]
tipc: add reference count to struct tipc_link

When a bearer is disabled, all pertaining links will be reset and
deleted. However, if there is a second active link towards a killed
link's destination, the delete has to be postponed until the failover
is finished. During this interval, we currently put the link in zombie
mode, i.e., we take it out of traffic, delete its timer, but leave it
attached to the owner node structure until all missing packets have
been received.  When this is done, we detach the link from its node
and delete it, assuming that the synchronous timer deletion that was
initiated earlier in a different thread has finished.

This is unsafe, as the failover may finish before del_timer_sync()
has returned in the other thread.

We fix this by adding an atomic reference counter of type kref in
struct tipc_link. The counter keeps track of the references kept
to the link by the owner node and the timer. We then do a conditional
delete, based on the reference counter, both after the failover has
been finished and when the timer expires, if applicable. Whoever
comes last, will actually delete the link. This approach also implies
that we can make the deletion of the timer asynchronous.

Reviewed-by: Erik Hugne <[email protected]>
Reviewed-by: Ying Xue <[email protected]>
Signed-off-by: Jon Maloy <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet: rds: use correct size for max unacked packets and bytes
Sasha Levin [Tue, 3 Feb 2015 13:55:58 +0000 (08:55 -0500)]
net: rds: use correct size for max unacked packets and bytes

Max unacked packets/bytes is an int while sizeof(long) was used in the
sysctl table.

This means that when they were getting read we'd also leak kernel memory
to userspace along with the timeout values.

Signed-off-by: Sasha Levin <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoACPI / PCC: Use pr_debug() for debug messages in pcc_init()
Rafael J. Wysocki [Wed, 4 Feb 2015 23:40:08 +0000 (00:40 +0100)]
ACPI / PCC: Use pr_debug() for debug messages in pcc_init()

pcc_init() uses pr_err() to print two messages that are really debug
and not interesting to users.  Replace those pr_err() with pr_debug().

Reported-by: Cristian <[email protected]>
Signed-off-by: Rafael J. Wysocki <[email protected]>
10 years agoMerge tag 'mac80211-next-for-davem-2015-02-03' of git://git.kernel.org/pub/scm/linux...
David S. Miller [Wed, 4 Feb 2015 22:57:45 +0000 (14:57 -0800)]
Merge tag 'mac80211-next-for-davem-2015-02-03' of git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next

Last round of updates for net-next:
 * revert a patch that caused a regression with mesh userspace (Bob)
 * fix a number of suspend/resume related races
   (from Emmanuel, Luca and myself - we'll look at backporting later)
 * add software implementations for new ciphers (Jouni)
 * add a new ACPI ID for Broadcom's rfkill (Mika)
 * allow using netns FD for wireless (Vadim)
 * some other cleanups (various)

Signed-off-by: David S. Miller <[email protected]>
10 years agocsiostor:Use firmware version from cxgb4/t4fw_version.h
Praveen Madhavan [Tue, 3 Feb 2015 11:48:26 +0000 (17:18 +0530)]
csiostor:Use firmware version from cxgb4/t4fw_version.h

This patch is to use firmware version macros from t4fw_version.h
and also enables 40g T5 adapter.

Signed-off-by: Praveen Madhavan <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agovhost/net: fix up num_buffers endian-ness
Michael S. Tsirkin [Tue, 3 Feb 2015 09:07:06 +0000 (11:07 +0200)]
vhost/net: fix up num_buffers endian-ness

In virtio 1.0 mode, when mergeable buffers are enabled on a big-endian
host, num_buffers wasn't byte-swapped correctly, so large incoming
packets got corrupted.

To fix, fill it in within hdr - this also makes sure it gets
the correct type.

Signed-off-by: Michael S. Tsirkin <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agotlan: msecs_to_jiffies convrsion
Nicholas Mc Guire [Tue, 3 Feb 2015 08:45:11 +0000 (03:45 -0500)]
tlan: msecs_to_jiffies convrsion

This is only an API consolidation and should make things more readable
it replaces var * HZ / 1000 by msecs_to_jiffies(var).

As there is a discrepancy between the code and the comments this is in
a separate patch.

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agotlan: use msecs_to_jiffies for conversion
Nicholas Mc Guire [Tue, 3 Feb 2015 08:44:45 +0000 (03:44 -0500)]
tlan: use msecs_to_jiffies for conversion

This is only an API consolidation and should make things more readable
it replaces var * HZ / 1000 by msecs_to_jiffies(var).

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoMerge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetoot...
David S. Miller [Wed, 4 Feb 2015 21:56:37 +0000 (13:56 -0800)]
Merge branch 'for-upstream' of git://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next

Johan Hedberg says:

====================
pull request: bluetooth-next 2015-02-03

Here's what's likely the last bluetooth-next pull request for 3.20.
Notable changes include:

 - xHCI workaround + a new id for the ath3k driver
 - Several new ids for the btusb driver
 - Support for new Intel Bluetooth controllers
 - Minor cleanups to ieee802154 code
 - Nested sleep warning fix in socket accept() code path
 - Fixes for Out of Band pairing handling
 - Support for LE scan restarting for HCI_QUIRK_STRICT_DUPLICATE_FILTER
 - Improvements to data we expose through debugfs
 - Proper handling of Hardware Error HCI events

Please let me know if there are any issues pulling. Thanks.
====================

Signed-off-by: David S. Miller <[email protected]>
10 years agogianfar: correct the bad expression while writing bit-pattern
Sanjeev Sharma [Tue, 3 Feb 2015 07:32:02 +0000 (13:02 +0530)]
gianfar: correct the bad expression while writing bit-pattern

This patch correct the bad expression while writing the
bit-pattern from software's buffer to hardware registers.

Signed-off-by: Sanjeev Sharma <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet: add skb functions to process remote checksum offload
Tom Herbert [Tue, 3 Feb 2015 00:07:34 +0000 (16:07 -0800)]
net: add skb functions to process remote checksum offload

This patch adds skb_remcsum_process and skb_gro_remcsum_process to
perform the appropriate adjustments to the skb when receiving
remote checksum offload.

Updated vxlan and gue to use these functions.

Tested: Ran TCP_RR and TCP_STREAM netperf for VXLAN and GUE, did
not see any change in performance.

Signed-off-by: Tom Herbert <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet: usb: sr9700: Use 'SR_' prefix for the common register macros
Chen Gang [Mon, 2 Feb 2015 21:00:40 +0000 (05:00 +0800)]
net: usb: sr9700: Use 'SR_' prefix for the common register macros

The commone register macors (e.g. RSR) is too commont to drivers, it may
be conflict with the architectures (e.g. xtensa, sh).

The related warnings (with allmodconfig under xtensa):

    CC [M]  drivers/net/usb/sr9700.o
  In file included from drivers/net/usb/sr9700.c:24:0:
  drivers/net/usb/sr9700.h:65:0: warning: "RSR" redefined
   #define RSR   0x06
   ^
  In file included from ./arch/xtensa/include/asm/bitops.h:22:0,
                   from include/linux/bitops.h:36,
                   from include/linux/kernel.h:10,
                   from include/linux/list.h:8,
                   from include/linux/module.h:9,
                   from drivers/net/usb/sr9700.c:13:
  ./arch/xtensa/include/asm/processor.h:190:0: note: this is the location of the previous definition
   #define RSR(v,sr) __asm__ __volatile__ ("rsr %0,"__stringify(sr) : "=a"(v));
   ^

Signed-off-by: Chen Gang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agobridge: Let bridge not age 'externally' learnt FDB entries, they are removed when...
Siva Mannem [Mon, 2 Feb 2015 17:21:54 +0000 (22:51 +0530)]
bridge: Let bridge not age 'externally' learnt FDB entries, they are removed when 'external' entity notifies the aging

When 'learned_sync' flag is turned on, the offloaded switch
 port syncs learned MAC addresses to bridge's FDB via switchdev notifier
 (NETDEV_SWITCH_FDB_ADD). Currently, FDB entries learnt via this mechanism are
 wrongly being deleted by bridge aging logic. This patch ensures that FDB
 entries synced from offloaded switch ports are not deleted by bridging logic.
 Such entries can only be deleted via switchdev notifier
 (NETDEV_SWITCH_FDB_DEL).

Signed-off-by: Siva Mannem <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agonet: fs_enet: Implement NETIF_F_SG feature
LEROY Christophe [Mon, 2 Feb 2015 17:06:54 +0000 (18:06 +0100)]
net: fs_enet: Implement NETIF_F_SG feature

Freescale ethernet controllers have the capability to re-assemble fragmented
data into a single ethernet frame. This patch uses this capability and
implements NETIP_F_SG feature into the fs_enet ethernet driver.

On a MPC885, I get 53% performance improvement on a ftp transfer of a 15Mb file:
  * Without the patch : 2,8 Mbps
  * With the patch : 4,3 Mbps

Signed-off-by: Christophe Leroy <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoASoC: jz4740: Add DT support to jz4740-i2s driver
Zubair Lutfullah Kakakhel [Tue, 3 Feb 2015 10:55:59 +0000 (10:55 +0000)]
ASoC: jz4740: Add DT support to jz4740-i2s driver

This patch adds device tree support for the jz4740 driver.

Signed-off-by: Zubair Lutfullah Kakakhel <[email protected]>
Acked-by: Lars-Peter Clausen <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoASoC: jz4740: Add binding documentation for jz4740-i2s
Zubair Lutfullah Kakakhel [Tue, 3 Feb 2015 10:55:58 +0000 (10:55 +0000)]
ASoC: jz4740: Add binding documentation for jz4740-i2s

This patch adds binding for the jz4740-i2s driver.

Signed-off-by: Zubair Lutfullah Kakakhel <[email protected]>
Acked-by: Lars-Peter Clausen <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoASoC: jz4740: Add dynamic sampling rate support to jz4740-i2s
Zubair Lutfullah Kakakhel [Tue, 3 Feb 2015 10:55:57 +0000 (10:55 +0000)]
ASoC: jz4740: Add dynamic sampling rate support to jz4740-i2s

The div clock register is not modified during jz4740_i2s_hw_params.
Hence, default sampling rates are actually used regardless of
sampling rates input from userspace.

This patch adds support to calculate the value of the divider from
the parameters passed from userspace and update the relevant div
registers

Signed-off-by: Zubair Lutfullah Kakakhel <[email protected]>
Acked-by: Lars-Peter Clausen <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoxps: fix xps for stacked devices
Eric Dumazet [Wed, 4 Feb 2015 07:48:24 +0000 (23:48 -0800)]
xps: fix xps for stacked devices

A typical qdisc setup is the following :

bond0 : bonding device, using HTB hierarchy
eth1/eth2 : slaves, multiqueue NIC, using MQ + FQ qdisc

XPS allows to spread packets on specific tx queues, based on the cpu
doing the send.

Problem is that dequeues from bond0 qdisc can happen on random cpus,
due to the fact that qdisc_run() can dequeue a batch of packets.

CPUA -> queue packet P1 on bond0 qdisc, P1->ooo_okay=1
CPUA -> queue packet P2 on bond0 qdisc, P2->ooo_okay=0

CPUB -> dequeue packet P1 from bond0
        enqueue packet on eth1/eth2
CPUC -> dequeue packet P2 from bond0
        enqueue packet on eth1/eth2 using sk cache (ooo_okay is 0)

get_xps_queue() then might select wrong queue for P1, since current cpu
might be different than CPUA.

P2 might be sent on the old queue (stored in sk->sk_tx_queue_mapping),
if CPUC runs a bit faster (or CPUB spins a bit on qdisc lock)

Effect of this bug is TCP reorders, and more generally not optimal
TX queue placement. (A victim bulk flow can be migrated to the wrong TX
queue for a while)

To fix this, we have to record sender cpu number the first time
dev_queue_xmit() is called for one tx skb.

We can union napi_id (used on receive path) and sender_cpu,
granted we clear sender_cpu in skb_scrub_packet() (credit to Willem for
this union idea)

Signed-off-by: Eric Dumazet <[email protected]>
Cc: Willem de Bruijn <[email protected]>
Cc: Nandita Dukkipati <[email protected]>
Cc: Yuchung Cheng <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
10 years agoMerge remote-tracking branches 'spi/fix/fsl-dspi' and 'spi/fix/imx' into spi-linus
Mark Brown [Wed, 4 Feb 2015 20:57:31 +0000 (20:57 +0000)]
Merge remote-tracking branches 'spi/fix/fsl-dspi' and 'spi/fix/imx' into spi-linus

10 years agoMerge remote-tracking branches 'asoc/topic/wm8960', 'asoc/topic/wm8988' and 'asoc...
Mark Brown [Wed, 4 Feb 2015 20:57:26 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/wm8960', 'asoc/topic/wm8988' and 'asoc/topic/xtfpga' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/txx9', 'asoc/topic/wm8750', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:24 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/txx9', 'asoc/topic/wm8750', 'asoc/topic/wm8804' and 'asoc/topic/wm8904' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/tdm-slot', 'asoc/topic/tegra', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:21 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/tdm-slot', 'asoc/topic/tegra', 'asoc/topic/tlv320aic3x', 'asoc/topic/ts3a227e' and 'asoc/topic/ts3a277e' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/rx51', 'asoc/topic/samsung', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:18 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/rx51', 'asoc/topic/samsung', 'asoc/topic/sh', 'asoc/topic/simple' and 'asoc/topic/sta32x' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/rockchip', 'asoc/topic/rt5645' and 'asoc...
Mark Brown [Wed, 4 Feb 2015 20:57:17 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/rockchip', 'asoc/topic/rt5645' and 'asoc/topic/rt5677' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/omap', 'asoc/topic/pxa' and 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:16 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/omap', 'asoc/topic/pxa' and 'asoc/topic/rcar' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/fsl-spdif', 'asoc/topic/imx', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:13 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/fsl-spdif', 'asoc/topic/imx', 'asoc/topic/intel', 'asoc/topic/mxs-saif' and 'asoc/topic/nuc900' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/doc', 'asoc/topic/dwc', 'asoc/topic/fsi...
Mark Brown [Wed, 4 Feb 2015 20:57:11 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/doc', 'asoc/topic/dwc', 'asoc/topic/fsi', 'asoc/topic/fsl' and 'asoc/topic/fsl-asrc' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/cs42l73', 'asoc/topic/dai' and 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:10 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/cs42l73', 'asoc/topic/dai' and 'asoc/topic/davinci' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/bt-sco', 'asoc/topic/cs35l32', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:09 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/bt-sco', 'asoc/topic/cs35l32', 'asoc/topic/cs42l52' and 'asoc/topic/cs42l56' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/topic/ad193x', 'asoc/topic/alc5632', 'asoc/topic...
Mark Brown [Wed, 4 Feb 2015 20:57:07 +0000 (20:57 +0000)]
Merge remote-tracking branches 'asoc/topic/ad193x', 'asoc/topic/alc5632', 'asoc/topic/atmel' and 'asoc/topic/au1x' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/w-codec' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:06 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/w-codec' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/pcm512x' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:06 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/pcm512x' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/pcm' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:05 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/pcm' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/dmaengine' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:05 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/dmaengine' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/dapm' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:04 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/dapm' into asoc-next

10 years agoMerge remote-tracking branch 'asoc/topic/core' into asoc-next
Mark Brown [Wed, 4 Feb 2015 20:57:04 +0000 (20:57 +0000)]
Merge remote-tracking branch 'asoc/topic/core' into asoc-next

10 years agoMerge remote-tracking branches 'asoc/fix/ac97', 'asoc/fix/atmel', 'asoc/fix/intel...
Mark Brown [Wed, 4 Feb 2015 20:56:58 +0000 (20:56 +0000)]
Merge remote-tracking branches 'asoc/fix/ac97', 'asoc/fix/atmel', 'asoc/fix/intel', 'asoc/fix/rt286', 'asoc/fix/rt5640', 'asoc/fix/sgtl5000', 'asoc/fix/sta32x', 'asoc/fix/tlv320aic3x' and 'asoc/fix/wm8731' into asoc-linus

10 years agospi: spi-imx: cleanup wait_for_completion handling
Nicholas Mc Guire [Mon, 2 Feb 2015 08:30:35 +0000 (03:30 -0500)]
spi: spi-imx: cleanup wait_for_completion handling

return type of wait_for_completion_timeout is unsigned long not int and
always returns >=0 , this patch adds a suitable return variable and
simplifies the return value checking as there is no < 0 case.

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agospi: sh-msiof: cleanup wait_for_completion return handling
Nicholas Mc Guire [Mon, 2 Feb 2015 08:30:34 +0000 (03:30 -0500)]
spi: sh-msiof: cleanup wait_for_completion return handling

return type of wait_for_completion_timeout is unsigned long not int, this
patch uses the return value of wait_for_completion_timeout in the condition
directly rather than assigning it to an incorrect type variable.

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agospi: match var type to return type of wait_for_completion
Nicholas Mc Guire [Mon, 2 Feb 2015 08:30:32 +0000 (03:30 -0500)]
spi: match var type to return type of wait_for_completion

return type of wait_for_completion_timeout is unsigned long not int, this
patch changes the type of m from int to unsigned long.

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoregmap: Fix i2c word access when using SMBus access functions
Guenter Roeck [Tue, 3 Feb 2015 18:01:19 +0000 (10:01 -0800)]
regmap: Fix i2c word access when using SMBus access functions

SMBus access functions assume that 16-bit values are formatted as
little endian numbers. The direct i2c access functions in regmap,
however, assume that 16-bit values are formatted as big endian numbers.
As a result, the current code returns different values if an i2c chip's
16-bit registers are accessed through i2c access functions vs. SMBus
access functions.

Use regmap_smbus_read_word_swapped and regmap_smbus_write_word_swapped
for 16-bit SMBus accesses if a chip is configured as REGMAP_ENDIAN_BIG.
If the chip is configured as REGMAP_ENDIAN_LITTLE, keep using
regmap_smbus_write_word_data and regmap_smbus_read_word_data. Otherwise
reject registration if the controller does not support direct i2c accesses.

Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoregmap: Export regmap_get_val_endian
Guenter Roeck [Tue, 3 Feb 2015 18:01:18 +0000 (10:01 -0800)]
regmap: Export regmap_get_val_endian

We'll need to call it from regmap-i2c.c, which can be built as module.

Signed-off-by: Guenter Roeck <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agospi: spi-pxa2xx: only include mach/dma.h for legacy DMA
Rob Herring [Tue, 3 Feb 2015 23:03:35 +0000 (17:03 -0600)]
spi: spi-pxa2xx: only include mach/dma.h for legacy DMA

Move the include of mach/dma.h to the legacy PXA DMA code where it is used.
This enables building spi-pxa2xx on ARM64.

Signed-off-by: Rob Herring <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoASoC: ts3a227e: fix sparse warning
Lad, Prabhakar [Wed, 4 Feb 2015 17:29:30 +0000 (17:29 +0000)]
ASoC: ts3a227e: fix sparse warning

this patch fixes following sparse warning:
ts3a227e.c:222:5: warning: symbol 'ts3a227e_enable_jack_detect' was not declared. Should it be static?

Signed-off-by: Lad, Prabhakar <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
10 years agoInput: gscps2 - fix MODULE_DEVICE_TABLE invocation
Geert Uytterhoeven [Wed, 4 Feb 2015 18:59:25 +0000 (10:59 -0800)]
Input: gscps2 - fix MODULE_DEVICE_TABLE invocation

The patch "module: fix types of device tables aliases" newly requires
that invocations of

MODULE_DEVICE_TABLE(type, name);

come *after* the definition of `name'.  That is reasonable, but gscps2
wasn't doing this.  Fix it.

Signed-off-by: Geert Uytterhoeven <[email protected]>
Signed-off-by: Dmitry Torokhov <[email protected]>
10 years agoMerge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6
Linus Torvalds [Wed, 4 Feb 2015 18:22:08 +0000 (10:22 -0800)]
Merge branch 'for-next' of git://git.samba.org/sfrench/cifs-2.6

Pull cifs fixes from Steve French:
 "Three small cifs fixes.  One fixes a hang under stress, and the other
  two are security related"

* 'for-next' of git://git.samba.org/sfrench/cifs-2.6:
  cifs: fix MUST SecurityFlags filtering
  Complete oplock break jobs before closing file handle
  cifs: use memzero_explicit to clear stack buffer

10 years agoMerge branch 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm
Linus Torvalds [Wed, 4 Feb 2015 17:42:55 +0000 (09:42 -0800)]
Merge branch 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm

Pull ARM fixes from Russell King:
 "A number of ARM fixes, the biggest is fixing a regression caused by
  appended DT blobs exceeding 64K, causing the decompressor fixup code
  to fail to patch the DT blob.  Another important fix is for the ASID
  allocator from Will Deacon which prevents some rare crashes seen on
  some systems.  Lastly, there's a build fix for v7M systems when printk
  support is disabled.

  The last two remaining fixes are more cosmetic - the IOMMU one
  prevents an annoying harmless warning message, and we disable the
  kernel strict memory permissions on non-MMU which can't support it
  anyway"

* 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm:
  ARM: 8299/1: mm: ensure local active ASID is marked as allocated on rollover
  ARM: 8298/1: ARM_KERNMEM_PERMS only works with MMU enabled
  ARM: 8295/1: fix v7M build for !CONFIG_PRINTK
  ARM: 8294/1: ATAG_DTB_COMPAT: remove the DT workspace's hardcoded 64KB size
  ARM: 8288/1: dma-mapping: don't detach devices without an IOMMU during teardown

10 years agoscsi_logging: return void for dev_printk() functions
Hannes Reinecke [Wed, 4 Feb 2015 07:11:34 +0000 (08:11 +0100)]
scsi_logging: return void for dev_printk() functions

dev_printk() is now a void function, so the related functions
scmd_printk() and sdev_prefix_printk() should be made void, too.

Reported-by: Stephen Rothwell <[email protected]>
Signed-off-by: Hannes Reinecke <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
10 years agoMIPS: Fix syscall_get_nr for the syscall exit tracing.
Lars Persson [Tue, 3 Feb 2015 16:08:17 +0000 (17:08 +0100)]
MIPS: Fix syscall_get_nr for the syscall exit tracing.

Register 2 is alredy overwritten by the return value when
syscall_trace_leave() is called.

Signed-off-by: Lars Persson <[email protected]>
Cc: [email protected]
Patchwork: https://patchwork.linux-mips.org/patch/9187/
Signed-off-by: Ralf Baechle <[email protected]>
10 years agoMIPS: elf2ecoff: Ignore PT_MIPS_ABIFLAGS program headers.
Ralf Baechle [Wed, 4 Feb 2015 11:59:43 +0000 (12:59 +0100)]
MIPS: elf2ecoff: Ignore PT_MIPS_ABIFLAGS program headers.

These are generated by very recent toolchains and result in an error
message when attenpting to convert a kernel from ELF to ECOFF.

Signed-off-by: Ralf Baechle <[email protected]>
10 years agoMIPS: elf2ecoff: Rewrite main processing loop to switch.
Ralf Baechle [Mon, 2 Feb 2015 00:01:46 +0000 (01:01 +0100)]
MIPS: elf2ecoff: Rewrite main processing loop to switch.

The if construct was getting hard to read and would be getting even more
complex with the next bug fix.

Signed-off-by: Ralf Baechle <[email protected]>
10 years agocan: kvaser_usb: Ignore spurious error events after a busoff
Ahmed S. Darwish [Mon, 2 Feb 2015 20:15:55 +0000 (15:15 -0500)]
can: kvaser_usb: Ignore spurious error events after a busoff

Sending data in high speed then introducing a busoff results
in spurious BUS_ERROR events from the USBCan-II firmware directly
_after_ the triggered BUS_OFF event.

In the current CAN state handling code, this will lead to an
invalid can state of ACTIVE, ERROR, or PASSIVE even though the
CAN controller has been already shut down due to the busoff.

Guard the state handling code from such invalid events.

Signed-off-by: Ahmed S. Darwish <[email protected]>
Signed-off-by: Marc Kleine-Budde <[email protected]>
10 years agocan: janz-ican3: fix type mismatch in assignment
Nicholas Mc Guire [Sun, 1 Feb 2015 08:34:34 +0000 (03:34 -0500)]
can: janz-ican3: fix type mismatch in assignment

return type of wait_for_completion_timeout is unsigned long not int, this patch
removes the type mismatch by moving the call into the condition.

Signed-off-by: Nicholas Mc Guire <[email protected]>
Signed-off-by: Marc Kleine-Budde <[email protected]>
10 years agommc: sdhci-s3c: solve problem with sleeping in atomic context
Paul Osmialowski [Wed, 4 Feb 2015 09:16:59 +0000 (10:16 +0100)]
mmc: sdhci-s3c: solve problem with sleeping in atomic context

This change addresses following problem:

[    2.560726] ------------[ cut here ]------------
[    2.565341] WARNING: CPU: 0 PID: 1 at kernel/locking/lockdep.c:2744 lockdep_trace_alloc+0xec/0x118()
[    2.574439] DEBUG_LOCKS_WARN_ON(irqs_disabled_flags(flags))
[    2.579821] Modules linked in:
[    2.583038] CPU: 0 PID: 1 Comm: swapper/0 Tainted: G        W      3.18.0-next-20141216-00002-g4ff197fc1902-dirty #1318
[    2.593796] Hardware name: SAMSUNG EXYNOS (Flattened Device Tree)
[    2.599892] [<c0014c44>] (unwind_backtrace) from [<c0011bbc>] (show_stack+0x10/0x14)
[    2.607612] [<c0011bbc>] (show_stack) from [<c04953b8>] (dump_stack+0x70/0xbc)
[    2.614822] [<c04953b8>] (dump_stack) from [<c0023444>] (warn_slowpath_common+0x74/0xb0)
[    2.622885] [<c0023444>] (warn_slowpath_common) from [<c0023514>] (warn_slowpath_fmt+0x30/0x40)
[    2.631569] [<c0023514>] (warn_slowpath_fmt) from [<c0063644>] (lockdep_trace_alloc+0xec/0x118)
[    2.640246] [<c0063644>] (lockdep_trace_alloc) from [<c00df52c>] (__kmalloc+0x3c/0x1cc)
[    2.648240] [<c00df52c>] (__kmalloc) from [<c0394970>] (clk_fetch_parent_index+0xb8/0xd4)
[    2.656390] [<c0394970>] (clk_fetch_parent_index) from [<c0394a6c>] (clk_calc_new_rates+0xe0/0x1fc)
[    2.665415] [<c0394a6c>] (clk_calc_new_rates) from [<c0394b40>] (clk_calc_new_rates+0x1b4/0x1fc)
[    2.674181] [<c0394b40>] (clk_calc_new_rates) from [<c0395408>] (clk_set_rate+0x50/0xc8)
[    2.682265] [<c0395408>] (clk_set_rate) from [<c0377708>] (sdhci_cmu_set_clock+0x68/0x16c)
[    2.690503] [<c0377708>] (sdhci_cmu_set_clock) from [<c03735cc>] (sdhci_do_set_ios+0xf0/0x64c)
[    2.699095] [<c03735cc>] (sdhci_do_set_ios) from [<c0373b48>] (sdhci_set_ios+0x20/0x2c)
[    2.707080] [<c0373b48>] (sdhci_set_ios) from [<c035ddf0>] (mmc_power_up+0x118/0x1fc)
[    2.714889] [<c035ddf0>] (mmc_power_up) from [<c035ecd0>] (mmc_start_host+0x44/0x6c)
[    2.722615] [<c035ecd0>] (mmc_start_host) from [<c035fd60>] (mmc_add_host+0x58/0x7c)
[    2.730341] [<c035fd60>] (mmc_add_host) from [<c037454c>] (sdhci_add_host+0x968/0xd94)
[    2.738240] [<c037454c>] (sdhci_add_host) from [<c0377b60>] (sdhci_s3c_probe+0x354/0x52c)
[    2.746406] [<c0377b60>] (sdhci_s3c_probe) from [<c0283b58>] (platform_drv_probe+0x48/0xa4)
[    2.754733] [<c0283b58>] (platform_drv_probe) from [<c02824e8>] (driver_probe_device+0x13c/0x37c)
[    2.763585] [<c02824e8>] (driver_probe_device) from [<c02827bc>] (__driver_attach+0x94/0x98)
[    2.772003] [<c02827bc>] (__driver_attach) from [<c0280a60>] (bus_for_each_dev+0x54/0x88)
[    2.780163] [<c0280a60>] (bus_for_each_dev) from [<c0281b48>] (bus_add_driver+0xe4/0x200)
[    2.788322] [<c0281b48>] (bus_add_driver) from [<c0282dfc>] (driver_register+0x78/0xf4)
[    2.796308] [<c0282dfc>] (driver_register) from [<c00089b0>] (do_one_initcall+0xac/0x1f0)
[    2.804473] [<c00089b0>] (do_one_initcall) from [<c0673d94>] (kernel_init_freeable+0x10c/0x1d8)
[    2.813153] [<c0673d94>] (kernel_init_freeable) from [<c0490058>] (kernel_init+0x28/0x108)
[    2.821398] [<c0490058>] (kernel_init) from [<c000f268>] (ret_from_fork+0x14/0x2c)
[    2.828939] ---[ end trace 03cc00e539849d1f ]---

clk_set_rate() tries to take clk's prepare_lock mutex while being in atomic
context entered in sdhci_do_set_ios().

The solution is inspired by similar situation in sdhci_set_power() also called
from sdhci_do_set_ios():

                spin_unlock_irq(&host->lock);
                mmc_regulator_set_ocr(mmc, mmc->supply.vmmc, vdd);
                spin_lock_irq(&host->lock);

Note that since sdhci_s3c_set_clock() sets SDHCI_CLOCK_CARD_EN, proposed change
first resets this bit. It is reset anyway (by setting SDHCI_CLOCK_INT_EN bit
only) after call to clk_set_rate() in order to wait for the clock to stabilize
and is set again as soon as the clock becomes stable.

Signed-off-by: Paul Osmialowski <[email protected]>
Tested-by: Jaehoon Chung <[email protected]>
Acked-by: Jaehoon Chung <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
This page took 0.124968 seconds and 4 git commands to generate.