Re: [RFC PATCH 1/1] Add a usbredir kernel module to remotely connect USB devices over IP.

2015-12-09 Thread Jeremy White
I've parked some working code, and I wanted to leave a pointer to it to end this thread. That is, the sense was that usbredir was not appropriate for the linux kernel, because Intel was working on a driver implementing the Media Agnostic USB standard, and having a proliferation of drivers didn't m

[PATCH v2 2/5] test: firmware_class: use kstrndup() where appropriate

2015-12-09 Thread Brian Norris
We're essentially just doing an open-coded kstrndup(). The only differences are with what happens after the first '\0' character, but request_firmware() doesn't care about that. Suggested-by: Kees Cook Signed-off-by: Brian Norris --- New in v2 lib/test_firmware.c | 3 +-- 1 file changed, 1 ins

[PATCH v5] fs: clear file privilege bits when mmap writing

2015-12-09 Thread Kees Cook
Normally, when a user can modify a file that has setuid or setgid bits, those bits are cleared when they are not the file owner or a member of the group. This is enforced when using write and truncate but not when writing to a shared mmap on the file. This could allow the file writer to gain privil

[PATCH v2 5/5] selftests: firmware: add empty string and async tests

2015-12-09 Thread Brian Norris
Now that we've added a 'trigger_async_request' knob to test the request_firmware_nowait() API, let's use it. Also add tests for the empty ("") string, since there have been a couple errors in that handling already. Since we now have real ways that the sysfs write might fail, let's add the appropri

Re: [PATCH 1/8] kernfs: Add API to generate relative kernfs path

2015-12-09 Thread Serge E. Hallyn
On Wed, Dec 09, 2015 at 05:36:51PM -0500, Tejun Heo wrote: > Hey, > > On Wed, Dec 09, 2015 at 10:13:27PM +, Serge Hallyn wrote: > > we can rename kn_root to from here if you think that's clearer (and > > change the order here as well). > > I think it'd be better for them to be consistent and

Re: [PATCH v3 0/5] ACPI / processor_idle: Add ACPI v6.0 LPI support

2015-12-09 Thread Prakash, Prashanth
Reviewed the patch-set and tested it on an ARM platform over the last couple of days without any issues, so Tested-by: Prashanth Prakash Thanks, Prashanth On 12/2/2015 7:10 AM, Sudeep Holla wrote: > ACPI 6.0 introduced LPI(Low Power Idle) states that provides an alternate > method to describe p

Re: [PATCH] fs: Drop CAP_SYS_RAWIO requirement for FIBMAP

2015-12-09 Thread Serge E. Hallyn
On Sat, Dec 05, 2015 at 12:15:16AM -0600, Seth Forshee wrote: > The information exposed by FIBMAP is not privileged and is > similar to the information provided by FIEMAP, which does not > require privileges. According to [1] the reason the capability > check was originally added was to prevent cra

Re: [PATCH 4/5] pinctrl: mediatek: Add Pinctrl/GPIO/EINT driver for mt2701

2015-12-09 Thread Linus Walleij
On Thu, Nov 26, 2015 at 9:44 AM, Biao Huang wrote: > Add mt2701 support using mediatek common pinctrl driver. > MT2701 have some special pins need an extra setting register > than other ICs, so adding this support to common code. > > Signed-off-by: Biao Huang This looks uncontroversial, but I w

Re: [PATCH v2] clear file privilege bits when mmap writing

2015-12-09 Thread Kees Cook
On Wed, Dec 9, 2015 at 12:26 AM, Jan Kara wrote: > On Mon 07-12-15 16:40:14, Kees Cook wrote: >> On Mon, Dec 7, 2015 at 2:42 PM, Kees Cook wrote: >> > On Thu, Dec 3, 2015 at 5:45 PM, yalin wang >> > wrote: >> >> >> >>> On Dec 2, 2015, at 16:03, Kees Cook wrote: >> >>> >> >>> Normally, when a u

[PATCH v2 4/5] firmware: actually return NULL on failed request_firmware_nowait()

2015-12-09 Thread Brian Norris
The kerneldoc for request_firmware_nowait() says that it may call the provided cont() callback with @fw == NULL, if the firmware request fails. However, this is not the case when called with an empty string (""). This case is short-circuited by the 'name[0] == '\0'' check introduced in commit 471b0

[PATCH v2 3/5] test: firmware_class: add asynchronous request trigger

2015-12-09 Thread Brian Norris
We might want to test for bugs like that found in commit f9692b2699bd ("firmware: fix possible use after free on name on asynchronous request"), where the asynchronous request API had race conditions. Let's add a simple file that will launch the async request, then wait until it's complete and rep

[PATCH v2 1/5] test: firmware_class: report errors properly on failure

2015-12-09 Thread Brian Norris
request_firmware() failures currently won't get reported at all (the error code is discarded). What's more, we get confusing messages, like: # echo -n notafile > /sys/devices/virtual/misc/test_firmware/trigger_request [ 8280.311856] test_firmware: loading 'notafile' [ 8280.317042] test

Re: linux-next: build failure after merge of the vfs tree

2015-12-09 Thread Andreas Grünbacher
2015-12-09 23:20 GMT+01:00 Stephen Rothwell : > OK, I wrote all that and then I realised that the preferred names > (XATTR_NAME_POSIX_ACL_..) have been in Linus' tree for a long time (in > include/uapi/linux/xattr.h), so you could just change the orangefs tree > to use those already. i.e. my patch

[PATCH v9 6/7] drivers:hv: Define the channel type of Hyper-V PCI Express pass-through

2015-12-09 Thread jakeo
From: Jake Oshins This defines the channel type for PCI front-ends in Hyper-V VMs. Signed-off-by: Jake Oshins --- include/linux/hyperv.h | 11 +++ 1 file changed, 11 insertions(+) diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h index 24d0b65..c9a9eed 100644 --- a/include/

[PATCH v9 7/7] PCI: hv: New paravirtual PCI front-end for Hyper-V VMs

2015-12-09 Thread jakeo
From: Jake Oshins This patch introduces a new driver which exposes a root PCI bus whenever a PCI Express device is passed through to a guest VM under Hyper-V. The device can be single- or multi-function. The interrupts for the devices are managed by an IRQ domain, implemented within the driver.

[PATCH v6] sun4i-codec: Add FM, Line and Mic inputs

2015-12-09 Thread Danny Milosavljevic
Add inputs to sun4i-codec: - FM-in Left and Right - Line-in Left and Right - Mic1-in - Mic2-in Signed-off-by: Danny Milosavljevic Tested-by: Danny Milosavljevic (ONLY ON A20!) --- Hi, this is the sixth version of the patch that adds inputs to sun4i-codec. Changes compared to v5 are: - Mic

[PATCH v9 2/7] drivers:hv: Export hv_do_hypercall()

2015-12-09 Thread jakeo
From: Jake Oshins This patch exposes the function that hv_vmbus.ko uses to make hypercalls. This is necessary for retargeting an interrupt when it is given a new affinity and vector. Signed-off-by: Jake Oshins --- drivers/hv/hv.c | 20 ++-- drivers/hv/hyperv_vmbus.h |

[PATCH v9 5/7] PCI: irqdomain: Look up IRQ domain by fwnode_handle

2015-12-09 Thread jakeo
From: Jake Oshins This patch adds a second way of finding an IRQ domain associated with a root PCI bus. After looking to see if one can be found through the OF tree, it attempts to look up the IRQ domain through an fwnode_handle stored in the pci_sysdata struct. Signed-off-by: Jake Oshins ---

[RESEND PATCH] kconfig: allow kconfig to handle longer path names

2015-12-09 Thread Markus Mayer
The current (arbitrary) limit of 128 characters for path names has proven too short for Android builds, as longer path names are used there. Change conf.c, so it can handle path lengths up to PATH_MAX characters. Signed-off-by: Markus Mayer --- scripts/kconfig/conf.c | 7 --- 1 file changed

[PATCH v9 1/7] drivers:hv: Export a function that maps Linux CPU num onto Hyper-V proc num

2015-12-09 Thread jakeo
From: Jake Oshins This patch exposes the mapping between Linux CPU number and Hyper-V virtual processor number. This is necessary because the hypervisor needs to know which virtual processor to target when making a mapping in the Interrupt Redirection Table in the I/O MMU. Signed-off-by: Jake Os

[PATCH v9 0/7] PCI: hv: New paravirtual PCI front-end for Hyper-V VMs

2015-12-09 Thread jakeo
From: Jake Oshins This version of the patch series removes warning when compiling x86 32-bit. First, export functions that allow correlating Hyper-V virtual processors and Linux cpus, along with the means for invoking a hypercall that targets interrupts at chosen vectors on specific cpus. Secon

[PATCH v9 3/7] PCI: Make it possible to implement a PCI MSI IRQ Domain in a module.

2015-12-09 Thread jakeo
From: Jake Oshins The Linux kernel already has the concpet of IRQ domain, wherein a component can expose a set of IRQs which are managed by a particular interrupt controller chip or other subsystem. The PCI driver exposes the notion of an IRQ domain for Message-Signaled Interrupts (MSI) from PCI

[PATCH v9 4/7] PCI: Add fwnode_handle to pci_sysdata

2015-12-09 Thread jakeo
From: Jake Oshins This patch adds an fwnode_handle to struct pci_sysdata, which is used by the next patch in the series when trying to locate an IRQ domain associated with a root PCI bus. Signed-off-by: Jake Oshins --- arch/x86/include/asm/pci.h | 15 +++ drivers/pci/probe.c

Re: [PATCH 0/4] gpio: pxa: integrate with pincontrol

2015-12-09 Thread Linus Walleij
On Sat, Nov 28, 2015 at 10:37 PM, Robert Jarzmik wrote: > Hi Linus, Alexandre and Haojian, > > This serie aims at several cleanups and improvements in the pxa gpio driver, > to I have concerns about this series. I am worried that joining the banks into one gpio_chip makes it impossible for you

Re: [PATCH] hexdump: Add ability to do endian conversions in print_hex_dump functions

2015-12-09 Thread Joe Perches
On Wed, 2015-12-09 at 14:45 -0800, Andrew Morton wrote: > On Wed, 09 Dec 2015 14:16:36 -0800 Joe Perches wrote: > > > Will patches be forthcoming to convert them? > > Sure, after a settling period for Masahiro's patch > > to be applied upstream. > > > > https://lkml.org/lkml/2015/12/8/480 > > On

[PATCH v2 tip/core/rcu 0/11] Expedited-grace-period changes for 4.5

2015-12-09 Thread Paul E. McKenney
Hello! This series contains follow-on cleanup changes to RCU's expedited grace-period functionality. The patches in this series are as follows: 1. Short-circuit synchronize_sched_expedited() if there is only one CPU. 2. Update comment to clarify the role of ->expmaskinitnext. 3.

[PATCH v2 tip/core/rcu 09/11] rcu: Wire up rcu_end_inkernel_boot()

2015-12-09 Thread Paul E. McKenney
This commit adds the invocation of rcu_end_inkernel_boot() just before init is invoked. This allows the CONFIG_RCU_EXPEDITE_BOOT Kconfig option to do something useful and prepares for the upcoming rcupdate.rcu_normal_after_boot kernel parameter. Signed-off-by: Paul E. McKenney --- init/main.c |

[PATCH v2 tip/core/rcu 08/11] rcu: Add rcu_normal kernel parameter to suppress expediting

2015-12-09 Thread Paul E. McKenney
Although expedited grace periods can be quite useful, and although their OS jitter has been greatly reduced, they can still pose problems for extreme real-time workloads. This commit therefore adds a rcu_normal kernel boot parameter (which can also be manipulated via sysfs) to suppress expedited g

[PATCH v2 tip/core/rcu 06/11] rcu: Make expedited grace periods resolve stall-warning ties

2015-12-09 Thread Paul E. McKenney
Currently, if a grace period ends just as the stall-warning timeout fires, an empty stall warning will be printed. This is not helpful, so this commit avoids these useless warnings by rechecking completion after awakening in synchronize_sched_expedited_wait(). Signed-off-by: Paul E. McKenney ---

[PATCH] ppc64: select HAVE_CONTEXT_TRACKING by default

2015-12-09 Thread Yang Shi
The functionality of context tracking has been implemented by PPC64 and HAVE_CONTEXT_TRACKING was selected by pseries by default. Actually, it is applicale to all PPC64 platforms, so select it in PPC64 generic Kconfig. NO_HZ_FULL depends on it, with this change NO_HZ_FULL could be enabled for all

[PATCH v2 tip/core/rcu 07/11] rcu: Add more diagnostics to expedited stall warning messages.

2015-12-09 Thread Paul E. McKenney
This commit adds print statements that check the rcu_node structure to find which ->expmask bits and which ->exp_tasks structures are blocking the current expedited grace period. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 24 +--- 1 file changed, 21 insertions(+)

[PATCH v2 tip/core/rcu 04/11] rcu: Invert sync_rcu_exp_select_cpus() "if" statement

2015-12-09 Thread Paul E. McKenney
This commit saves a couple lines of code and reduces indentation by inverting the sense of an "if" statement in the function sync_rcu_exp_select_cpus(). Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 30 ++ 1 file changed, 14 insertions(+), 16 deletions(-) d

[PATCH v2 tip/core/rcu 03/11] rcu: Move smp_mb() from rcu_seq_snap() to rcu_exp_gp_seq_snap()

2015-12-09 Thread Paul E. McKenney
The memory barrier in rcu_seq_snap() is needed only for grace periods, so this commit moves it to the grace-period-oriented wrapper rcu_exp_gp_seq_snap(). Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/rcu/tree.c b

[PATCH v2 tip/core/rcu 02/11] rcu: Clarify role of ->expmaskinitnext

2015-12-09 Thread Paul E. McKenney
Analogy with the ->qsmaskinitnext field might lead one to believe that ->expmaskinitnext tracks online CPUs. This belief is incorrect: Any CPU that has ever been online will have its bit set in the ->expmaskinitnext field. This commit therefore adds a comment to make this clear, at least to peopl

Re: [PATCH] mm: memcontrol: only manage socket pressure for CONFIG_INET

2015-12-09 Thread Johannes Weiner
On Wed, Dec 09, 2015 at 02:28:36PM -0800, Andrew Morton wrote: > On Wed, 9 Dec 2015 13:58:58 -0500 Johannes Weiner wrote: > > > > diff --git a/mm/memcontrol.c b/mm/memcontrol.c > > > index 6faea81e66d7..73cd572167bb 100644 > > > --- a/mm/memcontrol.c > > > +++ b/mm/memcontrol.c > > > @@ -4220,13

[PATCH v2 tip/core/rcu 05/11] rcu: Reduce expedited GP memory contention via per-CPU variables

2015-12-09 Thread Paul E. McKenney
Currently, the piggybacked-work checks carried out by sync_exp_work_done() atomically increment a small set of variables (the ->expedited_workdone0, ->expedited_workdone1, ->expedited_workdone2, ->expedited_workdone3 fields in the rcu_state structure), which will form a memory-contention bottleneck

[PATCH v2 tip/core/rcu 10/11] rcu: Allow expedited grace periods to be disabled at init

2015-12-09 Thread Paul E. McKenney
Expedited grace periods can speed up boot, but are undesirable in aggressive real-time systems. This commit therefore introduces a kernel parameter rcupdate.rcu_normal_after_boot that disables expedited grace periods just before init is spawned. Signed-off-by: Paul E. McKenney --- Documentation

[PATCH v2 tip/core/rcu 11/11] rcu: Remove TINY_RCU bloat from pointless boot parameters

2015-12-09 Thread Paul E. McKenney
The rcu_expedited, rcu_normal, and rcu_normal_after_boot kernel boot parameters are pointless in the case of TINY_RCU because in that case synchronous grace periods, both expedited and normal, are no-ops. However, these three symbols contribute several hundred bytes of bloat. This commit therefore

[PATCH v2 tip/core/rcu 01/11] rcu: Short-circuit synchronize_sched_expedited() if only one CPU

2015-12-09 Thread Paul E. McKenney
If there is only one CPU, then invoking synchronize_sched_expedited() is by definition a grace period. This commit checks for this condition and does a short-circuit return in that case. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 4 1 file changed, 4 insertions(+) diff --git

[PATCHv3] printf: Add format for 8-byte EUI-64 type

2015-12-09 Thread Keith Busch
MAC addresses may be formed using rules based on EUI-64, which is 2 bytes longer than a typical 6-byte MAC. This patch adds a long specifier to the %pM format to support the extended unique identifier. Since there are multiple valid possible permutations of format specifiers, the decoding is done

Re: [PATCH v2] powercap, intel_rapl.c, fix BIOS lock check

2015-12-09 Thread Rafael J. Wysocki
On Wednesday, December 09, 2015 08:53:55 AM Jacob Pan wrote: > On Wed, 9 Dec 2015 08:31:12 -0500 > Prarit Bhargava wrote: > > > Intel RAPL initialized on several systems where the BIOS lock bit (msr > > 0x610, bit 63) was set. This occured because the return value of > > rapl_read_data_raw() wa

[PATCH v2 tip/core/rcu 0/14] Miscellaneous fixes for 4.5

2015-12-09 Thread Paul E. McKenney
Hello! This series contains miscellaneous fixes for 4.5: 1. Move lock_class_key to local scope within rcu_init_one(). 2. Make rcu/tree_trace.c explicitly non-modular, courtesy of Paul Gortmaker. 3. Save a line of code by streamlining rcu_sched_qs() control flow. 4.

Re: [PATCH] hexdump: Add ability to do endian conversions in print_hex_dump functions

2015-12-09 Thread Andy Shevchenko
On Thu, Dec 10, 2015 at 12:11 AM, Andy Shevchenko wrote: > On Wed, Dec 9, 2015 at 11:59 PM, Joe Perches wrote: >> There are use cases for dumping buffers with specific endian types >> for 2, 4, and 8 byte variables in arrays. >> >> Add an enum for DUMP_TYPE_(LE|BE|CPU) to enable emitting them as

[PATCH v2 tip/core/rcu 10/14] rcu: Don't redundantly disable irqs in rcu_irq_{enter,exit}()

2015-12-09 Thread Paul E. McKenney
This commit replaces a local_irq_save()/local_irq_restore() pair with a lockdep assertion that interrupts are already disabled. This should remove the corresponding overhead from the interrupt entry/exit fastpaths. This change was inspired by the fact that Iftekhar Ahmed's mutation testing showed

[PATCH v2 tip/core/rcu 06/14] rcu: Avoid tick_nohz_active checks on NOCBs CPUs

2015-12-09 Thread Paul E. McKenney
Currently, rcu_prepare_for_idle() checks for tick_nohz_active, even on individual NOCBs CPUs, unless all CPUs are marked as NOCBs CPUs at build time. This check is pointless on NOCBs CPUs because they never have any callbacks posted, given that all of their callbacks are handed off to the correspo

[PATCH v2 tip/core/rcu 02/14] kernel: Make rcu/tree_trace.c explicitly non-modular

2015-12-09 Thread Paul E. McKenney
From: Paul Gortmaker The Kconfig currently controlling compilation of this code is: init/Kconfig:config TREE_RCU_TRACE init/Kconfig: def_bool RCU_TRACE && ( TREE_RCU || PREEMPT_RCU ) ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is e

[PATCH v2 tip/core/rcu 12/14] rcu: Move wakeup out from under rnp->lock

2015-12-09 Thread Paul E. McKenney
From: Peter Zijlstra This patch removes a potential deadlock hazard by moving the wake_up_process() in rcu_spawn_gp_kthread() out from under rnp->lock. Signed-off-by: Peter Zijlstra Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

Re: [PATCH v1 4/8] dt-bindings: add documentation of rk3228 clock controller

2015-12-09 Thread Heiko Stuebner
Hi Rob, Am Mittwoch, 9. Dezember 2015, 14:12:00 schrieb Rob Herring: > On Wed, Dec 09, 2015 at 05:04:09PM +0800, Jeffy Chen wrote: > > Add the devicetree binding for the cru on the rk3228 which quite similar > > structured as previous clock controllers. > > > > Signed-off-by: Jeffy Chen > > See

[PATCH v2 tip/core/rcu 14/14] list: Add lockless list traversal primitives

2015-12-09 Thread Paul E. McKenney
From: Alexey Kardashevskiy Although list_for_each_entry_rcu() can in theory be used anywhere preemption is disabled, it can result in calls to lockdep, which cannot be used in certain constrained execution environments, such as exception handlers that do not map the entire kernel into their addre

[PATCH 2/5] x86, vdso, pvclock: Simplify and speed up the vdso pvclock reader

2015-12-09 Thread Andy Lutomirski
From: Andy Lutomirski The pvclock vdso code was too abstracted to understand easily and excessively paranoid. Simplify it for a huge speedup. This opens the door for additional simplifications, as the vdso no longer accesses the pvti for any vcpu other than vcpu 0. Before, vclock_gettime using

[PATCH 5/5] x86/vdso: Enable vdso pvclock access on all vdso variants

2015-12-09 Thread Andy Lutomirski
Now that pvclock doesn't require access to the fixmap, all vdso variants can use it. The kernel side isn't wired up for 32-bit kernels yet, but this covers 32-bit and x32 userspace on 64-bit kernels. Signed-off-by: Andy Lutomirski --- arch/x86/entry/vdso/vclock_gettime.c | 91 --

[PATCH 4/5] x86/vdso: Remove pvclock fixmap machinery

2015-12-09 Thread Andy Lutomirski
Signed-off-by: Andy Lutomirski --- arch/x86/entry/vdso/vclock_gettime.c | 1 - arch/x86/entry/vdso/vma.c| 1 + arch/x86/include/asm/fixmap.h| 5 - arch/x86/include/asm/pvclock.h | 5 - arch/x86/kernel/kvmclock.c | 6 -- arch/x86/kernel/pvclock.

Re: [PATCH] mm: memcontrol: only manage socket pressure for CONFIG_INET

2015-12-09 Thread Andrew Morton
On Wed, 9 Dec 2015 18:05:05 -0500 Johannes Weiner wrote: > On Wed, Dec 09, 2015 at 02:28:36PM -0800, Andrew Morton wrote: > > On Wed, 9 Dec 2015 13:58:58 -0500 Johannes Weiner > > wrote: > > > The calls to tcp_init_cgroup() appear earlier in the series than "mm: > > > memcontrol: hook up vmpres

[PATCH 3/5] x86/vdso: Get pvclock data from the vvar VMA instead of the fixmap

2015-12-09 Thread Andy Lutomirski
Signed-off-by: Andy Lutomirski --- arch/x86/entry/vdso/vclock_gettime.c | 20 arch/x86/entry/vdso/vdso-layout.lds.S | 3 ++- arch/x86/entry/vdso/vdso2c.c | 3 +++ arch/x86/entry/vdso/vma.c | 13 + arch/x86/include/asm/pvclock.h| 9

Re: [PATCH v3 8/8] x86, vdso: mark vDSO read-only after init

2015-12-09 Thread Andy Lutomirski
On Wed, Dec 9, 2015 at 1:43 PM, Kees Cook wrote: > The vDSO does not need to be writable after __init, so mark it as > __ro_after_init. The result kills the exploit method of writing to the > vDSO from kernel space resulting in userspace executing the modified code, > as shown here to bypass SMEP

[PATCH v2 tip/core/rcu 0/8] Documentation updates for 4.5

2015-12-09 Thread Paul E. McKenney
Hello! This series contains documentation updates, perhaps most notably a first installment of RCU design documentation, which first appeared on LWN (http://lwn.net/Articles/652156/, http://lwn.net/Articles/652677/, and http://lwn.net/Articles/653326/). The individual patches are as follows: 1.

[PATCH 1/5] x86/kvm: On KVM re-enable (e.g. after suspend), update clocks

2015-12-09 Thread Andy Lutomirski
This gets rid of the "did TSC go backwards" logic and just updates all clocks. It should work better (no more disabling of fast timing) and more reliably (all of the clocks are actually updated). Signed-off-by: Andy Lutomirski --- arch/x86/kvm/x86.c | 75 +++-

[PATCH 0/5] x86: KVM vdso and clock improvements

2015-12-09 Thread Andy Lutomirski
NB: patch 1 doesn't really belong here, but it makes this a lot easier for me to test. Patch 1, if it's okay at all, should go though the kvm tree. The rest should probably go through tip:x86/vdso once they're reviewed. I'll do a followup to enable vdso pvclock on 32-bit guests. I'm not currentl

[PATCH v2 tip/core/rcu 5/8] documentation: Expand on scheduler/RCU deadlock requirements

2015-12-09 Thread Paul E. McKenney
This commit adds a second option for avoiding scheduler/RCU deadlocks, namely that preemption be disabled across the entire RCU read-side critical section in question. Signed-off-by: Paul E. McKenney --- Documentation/RCU/Design/Requirements/Requirements.html | 14 +- Documentation/

[PATCH v2 tip/core/rcu 8/8] Documentation/memory-barriers.txt: Fix ACCESS_ONCE thinko

2015-12-09 Thread Paul E. McKenney
From: Chris Metcalf In commit 2ecf810121c7 ("Documentation/memory-barriers.txt: Add needed ACCESS_ONCE() calls to memory-barriers.txt") the statement "Q = P" was converted to "ACCESS_ONCE(Q) = P". This should have been "Q = ACCESS_ONCE(P)". It later became "WRITE_ONCE(Q, P)". This doesn't match

[PATCH v2 tip/core/rcu 3/8] documentation: Cover requirements controlling stall warnings

2015-12-09 Thread Paul E. McKenney
This commit adds verbiage on boot and sysfs parameters that can be used to control RCU CPU stall warnings, both to change the timeout and to suppress these warnings entirely. Signed-off-by: Paul E. McKenney --- .../RCU/Design/Requirements/Requirements.html | 25 +- .../R

Re: [PATCH] hexdump: Add ability to do endian conversions in print_hex_dump functions

2015-12-09 Thread Joe Perches
On Thu, 2015-12-10 at 01:09 +0200, Andy Shevchenko wrote: > On Thu, Dec 10, 2015 at 12:11 AM, Andy Shevchenko > wrote: > > On Wed, Dec 9, 2015 at 11:59 PM, Joe Perches wrote: > > > There are use cases for dumping buffers with specific endian types > > > for 2, 4, and 8 byte variables in arrays. >

[PATCH v2 tip/core/rcu 4/8] documentation: Composability analogies

2015-12-09 Thread Paul E. McKenney
This commit expands on RCU's composability by comparing it to that of transactional memory and of locking. Signed-off-by: Paul E. McKenney --- Documentation/RCU/Design/Requirements/Requirements.html | 8 Documentation/RCU/Design/Requirements/Requirements.htmlx | 8 2 files cha

[PATCH v2 tip/core/rcu 2/8] Documentation: Record bottom-bit-zero guarantee for ->next

2015-12-09 Thread Paul E. McKenney
This commit records RCU's guarantee that the bottom bit of the rcu_head structure's ->next field will remain zero for callbacks posted via call_rcu(), but not necessarily for kfree_rcu() or some possible future call_rcu_lazy() variant that might one day be created for energy-efficiency purposese.

[PATCH v2 tip/core/rcu 07/14] rcu: Stop disabling interrupts in scheduler fastpaths

2015-12-09 Thread Paul E. McKenney
We need the scheduler's fastpaths to be, well, fast, and unnecessarily disabling and re-enabling interrupts is not necessarily consistent with this goal. Especially given that there are regions of the scheduler that already have interrupts disabled. This commit therefore moves the call to rcu_not

Re: [PATCH v1 2/8] clk: rockchip: add dt-binding header for rk3228

2015-12-09 Thread Heiko Stuebner
Am Mittwoch, 9. Dezember 2015, 17:04:07 schrieb Jeffy Chen: > Add the dt-bindings header for the rk3228, that gets shared between > the clock controller and the clock references in the dts. > > Signed-off-by: Jeffy Chen applied to my clk branch for 4.5 -- To unsubscribe from this list: send the

[PATCH v2 tip/core/rcu 6/8] documentation: Clarify RCU memory barriers and requirements

2015-12-09 Thread Paul E. McKenney
The RCU requirements do not make it absolutely clear that the memory-barrier requirements are not intended to replace the fundamental requirement that all pre-existing RCU readers complete before a grace period completes. This commit therefore pulls the memory-barrier requirements into a separate

[PATCH v2 tip/core/rcu 7/8] documentation: Update RCU requirements based on expedited changes

2015-12-09 Thread Paul E. McKenney
Because RCU-sched expedited grace periods now use IPIs and interact with rcu_read_unlock(), it is no longer sufficient to disable preemption across RCU read-side critical sections that acquire and hold scheduler locks. It is now necessary to instead disable interrupts. This commit documents this

Re: [PATCH v1 4/8] dt-bindings: add documentation of rk3228 clock controller

2015-12-09 Thread Heiko Stuebner
Am Mittwoch, 9. Dezember 2015, 17:04:09 schrieb Jeffy Chen: > Add the devicetree binding for the cru on the rk3228 which quite similar > structured as previous clock controllers. > > Signed-off-by: Jeffy Chen applied to my clock branch with Rob's ack -- To unsubscribe from this list: send the li

[PATCH v2 tip/core/rcu 11/14] rcu: Fix comment for rcu_dereference_raw_notrace

2015-12-09 Thread Paul E. McKenney
From: Alexey Kardashevskiy rcu_dereference_raw() calls indirectly rcu_read_lock_held() while rcu_dereference_raw_notrace() does not so fix the comment about the latter. Signed-off-by: Alexey Kardashevskiy Signed-off-by: Paul E. McKenney --- include/linux/rcupdate.h | 2 +- 1 file changed, 1 i

[PATCH v2 tip/core/rcu 01/14] rcu: Move lock_class_key to local scope

2015-12-09 Thread Paul E. McKenney
Currently, the rcu_node_class[], rcu_fqs_class[], and rcu_exp_class[] arrays needlessly pollute the global namespace within tree.c. This commit therefore converts them to static local variables within rcu_init_one(). Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 7 +++ 1 file chan

Re: mtd, nand, omap2: parse cmdline partition fail

2015-12-09 Thread Brian Norris
On Fri, Dec 04, 2015 at 09:42:06AM +0100, Heiko Schocher wrote: > Am 04.12.2015 um 08:17 schrieb Frans Klaver: > >On Fri, Dec 4, 2015 at 7:48 AM, Heiko Schocher wrote: > >>So the question is, is it intended to change the "mtd->name"? > > > >That's definitely not intended. The expectation with thi

[PATCH v2 tip/core/rcu 04/14] rcu: Remove lock-acquisition loop from rcu_read_unlock_special()

2015-12-09 Thread Paul E. McKenney
Several releases have come and gone without the warning triggering, so remove the lock-acquisition loop. Retain the WARN_ON_ONCE() out of sheer paranoia. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree_plugin.h | 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) diff

Re: [PATCH v11] PCI: Xilinx-NWL-PCIe: Added support for Xilinx NWL PCIe Host Controller

2015-12-09 Thread Bjorn Helgaas
[+cc Michal, Paul, Thierry, Stephen, Alexandre (see irq_dispose_mapping questions below)] On Sun, Nov 29, 2015 at 05:33:53PM +0530, Bharat Kumar Gogada wrote: > Adding PCIe Root Port driver for Xilinx PCIe NWL bridge IP. > > Signed-off-by: Bharat Kumar Gogada > Signed-off-by: Ravi Kiran Gummalu

[PATCH v2 tip/core/rcu 09/14] rcu: Make cpu_needs_another_gp() be bool

2015-12-09 Thread Paul E. McKenney
The cpu_needs_another_gp() function is currently of type int, but only returns zero or one. Bow to reality and make it be of type bool. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/kernel/rcu/tree.c b/ke

[PATCH v2 tip/core/rcu 05/14] rcu: Fix obsolete rcu_bootup_announce_oddness() comment

2015-12-09 Thread Paul E. McKenney
This function no longer has #ifdefs, so this commit removes the header comment calling them out. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree_plugin.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/rcu/tree_plugin.h b/kernel/rcu/tree_plugin.h index ae4ce2b665

[PATCH v2 tip/core/rcu 03/14] rcu: Simplify rcu_sched_qs() control flow

2015-12-09 Thread Paul E. McKenney
This commit applies an early-exit approach to rcu_sched_qs(), reducing the nesting level and saving a line of code. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 29 ++--- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/kernel/rcu/tree.c b/kernel

[PATCH v2 tip/core/rcu 13/14] rcu: Make rcu_gp_init() be bool rather than int

2015-12-09 Thread Paul E. McKenney
The return value from rcu_gp_init() is always used as a bool, so this commit makes it be a bool. Reported-by: Iftekhar Ahmed Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c

[PATCH v2 tip/core/rcu 08/14] rcu: Eliminate unused rcu_init_one() argument

2015-12-09 Thread Paul E. McKenney
Now that the rcu_state structure's ->rda field is compile-time initialized, there is no need to pass the per-CPU rcu_data structure into rcu_init_one(). This commit therefore eliminates this now-unused parameter. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c| 7 +++ kernel/rc

Re: [PATCHv3] printf: Add format for 8-byte EUI-64 type

2015-12-09 Thread Joe Perches
On Wed, 2015-12-09 at 16:06 -0700, Keith Busch wrote: > MAC addresses may be formed using rules based on EUI-64, which is 2 bytes > longer than a typical 6-byte MAC. This patch adds a long specifier to > the %pM format to support the extended unique identifier. > > Since there are multiple valid p

Re: [PATCH v2 3/5] test: firmware_class: add asynchronous request trigger

2015-12-09 Thread Kees Cook
On Wed, Dec 9, 2015 at 2:50 PM, Brian Norris wrote: > We might want to test for bugs like that found in commit f9692b2699bd > ("firmware: fix possible use after free on name on asynchronous > request"), where the asynchronous request API had race conditions. > > Let's add a simple file that will l

[PATCH v2 tip/core/rcu 0/9] Torture-test updates for 4.5

2015-12-09 Thread Paul E. McKenney
Hello! This series contains torture-test updates: 1. Add batch number to script printout to allow easier estimation of test duration. 2. Flag non-existent RCU grace-period kthread. 3. Dump stack when RCU's grace-period kthread stalls. 4. Set the scripting's default

Re: [PATCH 1/1] perf/x86/intel: Add perf core PMU support for Intel Knights Landing

2015-12-09 Thread Harish Chegondi
On 12/08/2015 12:37 AM, Peter Zijlstra wrote: > On Mon, Dec 07, 2015 at 02:28:18PM -0800, Harish Chegondi wrote: >> Knights Landing core is based on Silvermont core with several differences. >> Like Silvermont, Knights Landing has 8 pairs of LBR MSRs. However, the >> LBR MSRs addresses match thos

[PATCH 5/6] drivers/dma: make sh/shdma-*.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of these files is: config SH_DMAE_BASE bool "Renesas SuperH DMA Engine support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading the driver the

[PATCH v2 tip/core/rcu 2/9] rcutorture: Flag nonexistent RCU GP kthread

2015-12-09 Thread Paul E. McKenney
Currently, if the RCU grace-period kthread has not yet been created, in which case the starvation-check code will print zero for the state, which maps to TASK_RUNNING. This could clearly be quite confusing, so this commit prints ~0, which does not map to any legal ->state value. Signed-off-by: Pa

[GIT PULL] VFIO fixes for v4.4-rc5

2015-12-09 Thread Alex Williamson
Hi Linus, The following changes since commit 8005c49d9aea74d382f474ce11afbbc7d7130bec: Linux 4.4-rc1 (2015-11-15 17:00:27 -0800) are available in the git repository at: git://github.com/awilliam/linux-vfio.git tags/vfio-v4.4-rc5 for you to fetch changes up to ae5515d66362b9d96cdcfce504567f

[PATCH v2 tip/core/rcu 7/9] rcutorture: Print symbolic name for ->gp_state

2015-12-09 Thread Paul E. McKenney
Currently, ->gp_state is printed as an integer, which slows debugging. This commit therefore prints a symbolic name in addition to the integer. Signed-off-by: Paul E. McKenney [ paulmck: Updated to fix relational operator called out by Dan Carpenter. ] [ paulmck: More "const", as suggested by Jos

[PATCH 4/6] drivers/dma: make pxa_dma.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: drivers/dma/Kconfig:config PXA_DMA drivers/dma/Kconfig:bool "PXA DMA support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading

[PATCH v2 tip/core/rcu 4/9] rcutorture: Default grace period to three minutes, allow override

2015-12-09 Thread Paul E. McKenney
The default test grace period of two minutes is insufficient in some cases and excessive in others. This commit therefore increases the default to three minutes, but also adds a --shutdown-grace parameter to allow the default to be overridden. Signed-off-by: Paul E. McKenney Reviewed-by: Josh Tr

[PATCH v2 tip/core/rcu 6/9] rcutorture: Print symbolic name for rcu_torture_writer_state

2015-12-09 Thread Paul E. McKenney
Currently, rcu_torture_writer_state is printed as an integer, which slows debugging. This commit therefore prints a symbolic name in addition to the integer. Signed-off-by: Paul E. McKenney [ paulmck: More "const", as suggested by Josh Triplett. ] Reviewed-by: Josh Triplett --- kernel/rcu/rcut

[PATCH 0/6] drivers/dma: drop modular code from non modular drivers

2015-12-09 Thread Paul Gortmaker
This series of commits is a slice of a larger project to ensure people don't have dead code for module removal in non-modular drivers. Overall there is roughly 5k lines of dead code in the kernel due to this. There is a quasi-separate theme, in that some of the drivers were allowing an unbind imp

[PATCH v2 tip/core/rcu 1/9] rcutorture: Add batch number to script printout

2015-12-09 Thread Paul E. McKenney
Currently, the scripts print "Start batch" at the beginning of each batch, which does serve as a good visual delimiter between batches. Unfortunately, if there are a lot of batches, it is hard to quickly estimate test runtime from the output of "--dryrun sched". This commit therefore adds a ba

[PATCH v2 tip/core/rcu 8/9] torture: Abbreviate console error dump

2015-12-09 Thread Paul E. McKenney
Currently, the scripts print a list of warning/bug indicators from the console.log file. This works well if there are only a few warnings or bugs, but can be quite annoying if there is a large number. This commit therefore prints a summary listing the number of each type of warning/bug indicator,

[PATCH v2 tip/core/rcu 5/9] rcutorture: Remove CONFIG_RCU_USER_QS from rcutorture selftest doc

2015-12-09 Thread Paul E. McKenney
From: Yang Shi Commit d1ec4c34c7a9 ("rcu: Drop RCU_USER_QS in favor of NO_HZ_FULL") has removed RCU_USER_QS from Kconfig file, so remove it from some documents to avoid any confusion. Signed-off-by: Yang Shi Signed-off-by: Paul E. McKenney Acked-by: Frederic Weisbecker Reviewed-by: Josh Tripl

[PATCH v2 tip/core/rcu 9/9] torture: Place console.log files correctly from the get-go

2015-12-09 Thread Paul E. McKenney
Currently, the console output files ("console.log") are placed in the build directory initially, then copied to the results directory. One problem with this is if a qemu refuses to die in a timely fashion after a kernel hang, it will continue to write after the next qemu starts up, resulting in con

[PATCH v2 tip/core/rcu 3/9] rcutorture: Dump stack when GP kthread stalls

2015-12-09 Thread Paul E. McKenney
This commit increases debug information in the case where the grace-period kthread is being prevented from running by dumping that kthread's stack. Signed-off-by: Paul E. McKenney [ paulmck: Split into prior commit and this commit, as suggested by Josh Triplett. ] Reviewed-by: Josh Triplett --

[PATCH 6/6] drivers/dma: make tegra20-apb-dma.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: drivers/dma/Kconfig:config TEGRA20_APB_DMA drivers/dma/Kconfig:bool "NVIDIA Tegra20 APB DMA support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned

[PATCH 2/6] drivers/dma: make mmp_pdma.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: drivers/dma/Kconfig:config MMP_PDMA drivers/dma/Kconfig:bool "MMP PDMA support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when readin

[PATCH 1/6] drivers/dma: make edma.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: drivers/dma/Kconfig:config TI_EDMA drivers/dma/Kconfig:bool "TI EDMA support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that when reading

[PATCH 3/6] drivers/dma: make mmp_tdma.c explicitly non-modular

2015-12-09 Thread Paul Gortmaker
The Kconfig currently controlling compilation of this code is: drivers/dma/Kconfig:config MMP_TDMA drivers/dma/Kconfig:bool "MMP Two-Channel DMA support" ...meaning that it currently is not being built as a module by anyone. Lets remove the modular code that is essentially orphaned, so that

<    4   5   6   7   8   9   10   11   12   >