Re: [PATCH] x86/vm86: fix unused variable warning if THP is disabled.

2017-02-13 Thread Borislav Petkov
On Mon, Feb 13, 2017 at 03:52:28PM +0300, Kirill A. Shutemov wrote: > GCC complaines on unused variable 'vma' in mark_screen_rdonly() if THP > is disalbed: > > arch/x86/kernel/vm86_32.c: In function ‘mark_screen_rdonly’: > arch/x86/kernel/vm86_32.c:180:26: warning: unused variable ‘vma’ > [-Wunuse

Re: [tip:locking/core] refcount_t: Introduce a special purpose refcount type

2017-02-13 Thread Kees Cook
On Mon, Feb 13, 2017 at 6:34 AM, Peter Zijlstra wrote: > On Fri, Feb 10, 2017 at 12:31:15AM -0800, tip-bot for Peter Zijlstra wrote: >> Commit-ID: f405df5de3170c00e5c54f8b7cf4766044a032ba >> Gitweb: >> http://git.kernel.org/tip/f405df5de3170c00e5c54f8b7cf4766044a032ba >> Author: Peter Zi

Re: [PATCH] kernfs: fix locking around kernfs_ops->release() callback

2017-02-13 Thread Tony Lindgren
* Tejun Heo [170211 12:34]: > The release callback may be called from two places - file release > operation and kernfs open file draining. kernfs_open_file->mutex is > used to synchronize the two callsites. This unfortunately leads to > possible circular locking because of->mutex is used to prot

Re: [PATCH RFC v2 tip/core/rcu] Maintain special bits at bottom of ->dynticks counter

2017-02-13 Thread Peter Zijlstra
On Mon, Feb 13, 2017 at 09:01:04AM -0800, Paul E. McKenney wrote: > > I think I've asked this before, but why does this live in the guts of > > RCU? > > > > Should we lift this state tracking stuff out and make RCU and > > NOHZ(_FULL) users of it, or doesn't that make sense (reason)? > > The dynt

Re: [tip:locking/core] refcount_t: Introduce a special purpose refcount type

2017-02-13 Thread Peter Zijlstra
On Mon, Feb 13, 2017 at 09:48:42AM -0800, Kees Cook wrote: > On Mon, Feb 13, 2017 at 6:34 AM, Peter Zijlstra wrote: > > Linus asked to please make this real C code. > > No objection from me, but I'm curious to see the conversation. Where > did this discussion happen? (I'm curious to see the reas

Re: [PATCH v2] regulator: devres: introduce managed enable and disable operations

2017-02-13 Thread Mark Brown
On Sun, Feb 12, 2017 at 06:32:49PM -0800, Dmitry Torokhov wrote: > v2: restored lost regulator_disable() stub > Mark, note that there is also patch introducing devm_clk_prepare() and > devm_clk_prepare_enable() that Russell did not hate so I think it will > get applied eventually. I believe lack

Re: [PATCH 1/2] exec: don't wait for zombie threads with cred_guard_mutex held

2017-02-13 Thread Oleg Nesterov
On 02/13, Mika Penttilä wrote: > > > +int de_thread(struct task_struct *tsk) > > { > > struct signal_struct *sig = tsk->signal; > > struct sighand_struct *oldsighand = tsk->sighand; > > @@ -1051,60 +1100,24 @@ static int de_thread(struct task_struct *tsk) > > if (thread_group_empty(tsk

Re: [PATCH v2 3/5] pci: set msi_domain_ops as __ro_after_init

2017-02-13 Thread Keith Busch
On Fri, Feb 10, 2017 at 05:37:56PM -0800, Jess Frazelle wrote: > Marked msi_domain_ops structs as __ro_after_init when called only during init. > This protects the data structure from accidental corruption. > > Suggested-by: Kees Cook > Signed-off-by: Jess Frazelle > > drivers/pci/host/pci-hype

[PATCH V2 1/2] exec: don't wait for zombie threads with cred_guard_mutex held

2017-02-13 Thread Oleg Nesterov
de_thread() waits for other threads with ->cred_guard_mutex held and this is really bad because the time is not bounded, debugger can delay the exit and this lock has a lot of users (mostly abusers imo) in fs/proc and more. And this leads to deadlock if debugger tries to take the same mutex:

[tip:x86/urgent] x86/vm86: Fix unused variable warning if THP is disabled

2017-02-13 Thread tip-bot for Kirill A. Shutemov
Commit-ID: 3ba5b5ea7dc3a10ef50819b43a9f8de2705f4eec Gitweb: http://git.kernel.org/tip/3ba5b5ea7dc3a10ef50819b43a9f8de2705f4eec Author: Kirill A. Shutemov AuthorDate: Mon, 13 Feb 2017 15:52:28 +0300 Committer: Thomas Gleixner CommitDate: Mon, 13 Feb 2017 19:04:38 +0100 x86/vm86: Fix unu

[PATCH] pci-hyperv: Use device serial number as PCI domain

2017-02-13 Thread Haiyang Zhang
This allows PCI domain numbers starts with 1, and also unique on the same VM. So names, such as VF NIC names, that include domain number as part of the name, can be shorter than that based on part of bus UUID previously. The new names will also stay same for VMs created with copied VHD and same nu

Re: [RFC simple allocator v2 0/2] Simple allocator

2017-02-13 Thread Mark Brown
On Mon, Feb 13, 2017 at 03:45:04PM +0100, Benjamin Gaignard wrote: > An other question is: do we have others memory regions that could be > interested > by this new framework ? I have in mind that some title memory regions could > use > it or replace ION heaps (system, carveout, etc...). > Maybe

Re: [PATCH RFC v2 tip/core/rcu] Maintain special bits at bottom of ->dynticks counter

2017-02-13 Thread Paul E. McKenney
On Mon, Feb 13, 2017 at 06:57:50PM +0100, Peter Zijlstra wrote: > On Mon, Feb 13, 2017 at 09:01:04AM -0800, Paul E. McKenney wrote: > > > I think I've asked this before, but why does this live in the guts of > > > RCU? > > > > > > Should we lift this state tracking stuff out and make RCU and > > >

Re: [PATCH 1/4] ipc/shm: do not check for MAP_POPULATE

2017-02-13 Thread Davidlohr Bueso
On Thu, 09 Feb 2017, Hugh Dickins wrote: I haven't checked, but are you sure that "populated" does nothing when the attacher had previously called mlockall(MCL_FUTURE)? I checked and you are certainly right. Andrew, please do not consider this patch, it's bogus. Thanks, Davidlohr

Re: [PATCH] usercopy: add testcases to check zeroing on failure of usercopy

2017-02-13 Thread Kees Cook
On Sat, Feb 11, 2017 at 10:13 PM, Hoeun Ryu wrote: > In the hardend usercopy, the destination buffer will be zeroed if > copy_from_user/get_user fails. This patch adds testcases for it. > The destination buffer is set with non-zero value before illegal > copy_from_user/get_user is executed and the

Re: [PATCH] kernfs: fix locking around kernfs_ops->release() callback

2017-02-13 Thread Greg Kroah-Hartman
On Mon, Feb 13, 2017 at 09:57:25AM -0800, Tony Lindgren wrote: > * Tejun Heo [170211 12:34]: > > The release callback may be called from two places - file release > > operation and kernfs open file draining. kernfs_open_file->mutex is > > used to synchronize the two callsites. This unfortunately

Re: [PATCH 02/10] ARM: dts: da850-evm: fix whitespace errors

2017-02-13 Thread Kevin Hilman
Bartosz Golaszewski writes: > Signed-off-by: Bartosz Golaszewski Acked-by: Kevin Hilman > --- > arch/arm/boot/dts/da850-evm.dts | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/arch/arm/boot/dts/da850-evm.dts b/arch/arm/boot/dts/da850-evm.dts > index c970b6

Re: module: fix memory leak on early load_module() failures

2017-02-13 Thread Jessica Yu
+++ Luis R. Rodriguez [10/02/17 14:06 -0800]: While looking for early possible module loading failures I was able to reproduce a memory leak possible with kmemleak. There are a few rare ways to trigger a failure: o we've run into a failure while processing kernel parameters (parse_args() ret

Re: [PATCH] usercopy: add testcases to check zeroing on failure of usercopy

2017-02-13 Thread Kees Cook
On Sat, Feb 11, 2017 at 10:13 PM, Hoeun Ryu wrote: > In the hardend usercopy, the destination buffer will be zeroed if > copy_from_user/get_user fails. This patch adds testcases for it. > The destination buffer is set with non-zero value before illegal > copy_from_user/get_user is executed and the

[PATCH 0/3] pstore fixes for v4.11

2017-02-13 Thread Kees Cook
Here's a dump to the mailing list of the fixes landing in the pstore tree for v4.11: - [PATCH 1/3] pstore: Correctly initialize spinlock and flags - [PATCH 2/3] pstore: Check for prz allocation in walker - [PATCH 3/3] MAINTAINERS: Adjust pstore git repo URI, add files -Kees

[PATCH 2/3] pstore: Check for prz allocation in walker

2017-02-13 Thread Kees Cook
Instead of needing additional checks in callers for unallocated przs, perform the check in the walker, which gives us a more universal way to handle the situation. Signed-off-by: Kees Cook --- fs/pstore/ram.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/pstore/ram.

[PATCH 1/3] pstore: Correctly initialize spinlock and flags

2017-02-13 Thread Kees Cook
The ram backend wasn't always initializing its spinlock correctly. Since it was coming from kzalloc memory, though, it was harmless on architectures that initialize unlocked spinlocks to 0 (at least x86 and ARM). This also fixes a possibly ignored flag setting too. When running under CONFIG_DEBUG_

[PATCH 3/3] MAINTAINERS: Adjust pstore git repo URI, add files

2017-02-13 Thread Kees Cook
The tree used for staging pstore changes has moved to my repo. The -next tree already pulls from here, so update MAINTAINERS to reflect reality. While at it, add some more pstore-related files to track. Signed-off-by: Kees Cook --- MAINTAINERS | 7 +-- 1 file changed, 5 insertions(+), 2 dele

Re: [PATCH 02/10] ARM: dts: da850-evm: fix whitespace errors

2017-02-13 Thread Kevin Hilman
Bartosz Golaszewski writes: > Signed-off-by: Bartosz Golaszewski I'll fold this one into the original since it's not yet merged. Kevin > --- > arch/arm/boot/dts/da850-evm.dts | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/arch/arm/boot/dts/da850-evm.dts b

Re: [PATCH 07/10] ARM: davinci: fix a whitespace error

2017-02-13 Thread Kevin Hilman
Bartosz Golaszewski writes: > There's a stray tab in da850_vpif_legacy_init(). Remove it. > > Signed-off-by: Bartosz Golaszewski Folding into the original, Kevin > --- > arch/arm/mach-davinci/pdata-quirks.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/arm/mac

Re: [PATCH 08/10] ARM: davinci: fix the DT boot on da850-evm

2017-02-13 Thread Kevin Hilman
Sekhar Nori writes: > On Tuesday 07 February 2017 11:51 PM, Kevin Hilman wrote: >> Bartosz Golaszewski writes: >> >>> When we enable vpif capture on the da850-evm we hit a BUG_ON() because >>> the i2c adapter can't be found. The board file boot uses i2c adapter 1 >>> but in the DT mode it's act

Question about DEC Alpha memory ordering

2017-02-13 Thread Paul E. McKenney
Hello! We have a question about DEC Alpha memory ordering. Given the litmus test shown at the end of this email, some of us believe that DEC Alpha won't ever have both P0()'s and P1()'s READ_ONCE() calls return 1, but others believe otherwise. Our current Linux-kernel memory model assumes that i

Re: Please turn "Cannot use CONFIG_STACK_VALIDATION" into build error

2017-02-13 Thread Josh Poimboeuf
On Mon, Feb 13, 2017 at 12:07:09AM -0800, Marc MERLIN wrote: > Hi Josh, > > I'll start with the story as to why. > i've lost more hours than I care to list, because I was unable to build > the virtualbox kernel driver with newer kernels. > Sadly, it gives no useful debug info outside of > make[1]:

Re: [PATCH 1/2] driver core: emit uevents when device is bound to a driver

2017-02-13 Thread Dmitry Torokhov
On Mon, Feb 13, 2017 at 04:07:01AM -0800, Greg Kroah-Hartman wrote: > On Sun, Feb 12, 2017 at 04:36:18PM -0800, Dmitry Torokhov wrote: > > Majority of standard for a subsystem device attributes are created at the > > same time devices are created, before KOBJECT_ADD uevent is emitted by the > > dri

Re: [PATCH v2] regulator: devres: introduce managed enable and disable operations

2017-02-13 Thread Dmitry Torokhov
On Mon, Feb 13, 2017 at 06:01:29PM +, Mark Brown wrote: > On Sun, Feb 12, 2017 at 06:32:49PM -0800, Dmitry Torokhov wrote: > > > v2: restored lost regulator_disable() stub > > > Mark, note that there is also patch introducing devm_clk_prepare() and > > devm_clk_prepare_enable() that Russell d

Re: [PATCH v3 1/3] xen/privcmd: return -ENOTTY for unimplemented IOCTLs

2017-02-13 Thread Boris Ostrovsky
On 02/13/2017 12:03 PM, Paul Durrant wrote: The code sets the default return code to -ENOSYS but then overrides this to -EINVAL in the switch() statement's default case, which is clearly silly. This patch removes the override and sets the default return code to -ENOTTY, which is the convention

Applied "ASoC: fsl_sai: support more than 2 channels" to the asoc tree

2017-02-13 Thread Mark Brown
The patch ASoC: fsl_sai: support more than 2 channels has been applied to the asoc tree at git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Lin

Applied "spi: s3c64xx: fix inconsistency between binding and driver" to the spi tree

2017-02-13 Thread Mark Brown
The patch spi: s3c64xx: fix inconsistency between binding and driver has been applied to the spi tree at git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and

Regression in next with use printk_safe buffers in printk

2017-02-13 Thread Tony Lindgren
the relevant one as pointed out by Peter. Regards, Tony 8< - [ 48.950592] == [ 48.950622] [ INFO: possible circular locking dependency detected ] [ 48.950622] 4.10.0-rc7-next-20170213+ #101 Not tainted [ 48.950622] -

[PATCH v4 net-next 4/8] sunvnet: add memory barrier before check for tx enable

2017-02-13 Thread Shannon Nelson
In order to allow the underlying LDC and outstanding memory operations to potentially catch up with the driver's Tx requests, add a memory barrier before checking again for available tx descriptors. Signed-off-by: Shannon Nelson --- drivers/net/ethernet/sun/sunvnet_common.c |1 + 1 files cha

[PATCH v4 net-next 7/8] ldmvsw: update and simplify version string

2017-02-13 Thread Shannon Nelson
New version and simplify the print code. Signed-off-by: Shannon Nelson --- drivers/net/ethernet/sun/ldmvsw.c | 14 -- 1 files changed, 4 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/sun/ldmvsw.c b/drivers/net/ethernet/sun/ldmvsw.c index 335b876..f0fe6cf 100644

[PATCH v4 net-next 5/8] sunvnet: straighten up message event handling logic

2017-02-13 Thread Shannon Nelson
The use of gotos for handling the incoming events made this code harder to read and support than it should be. This patch straightens out and clears up the logic. Signed-off-by: Shannon Nelson --- drivers/net/ethernet/sun/sunvnet_common.c | 94 ++--- 1 files changed, 4

[PATCH v4 net-next 6/8] sunvnet: remove extra rcu_read_unlocks

2017-02-13 Thread Shannon Nelson
The RCU read lock is grabbed first thing in sunvnet_start_xmit_common() so it always needs to be released. This removes the conditional release in the dropped packet error path and removes a couple of superfluous calls in the middle of the code. Reported-by: Bijan Mottahedeh Signed-off-by: Shann

Re: [RFC simple allocator v2 0/2] Simple allocator

2017-02-13 Thread Laura Abbott
On 02/13/2017 10:18 AM, Mark Brown wrote: > On Mon, Feb 13, 2017 at 03:45:04PM +0100, Benjamin Gaignard wrote: > >> An other question is: do we have others memory regions that could be >> interested >> by this new framework ? I have in mind that some title memory regions could >> use >> it or re

[PATCH v4 net-next 8/8] ldmvsw: disable tso and gso for bridge operations

2017-02-13 Thread Shannon Nelson
The ldmvsw driver is specifically for supporting the ldom virtual networking by running in the primary ldom and using the LDC to connect the remaining ldoms to the outside world via a bridge. With TSO and GSO supported while connected the bridge, things tend to misbehave as seen in our case by del

Re: [PATCH v4 2/2] procfs/tasks: add a simple per-task procfs hidepid= field

2017-02-13 Thread Andy Lutomirski
On Fri, Feb 10, 2017 at 3:44 PM, Kees Cook wrote: > On Wed, Jan 18, 2017 at 3:35 PM, Andy Lutomirski wrote: >> On Wed, Jan 18, 2017 at 2:50 PM, Djalal Harouni wrote: >>> Andy I don't follow here, no_new_privs is never cleared right ? I >>> can't see the corresponding clear bit code for it. >> >>

[PATCH v4 net-next 3/8] sunvnet: update version and version printing

2017-02-13 Thread Shannon Nelson
There have been several changes since the first version of this code, so we bump the version number. While we're at it, we can simplify the version printing a bit and drop a couple lines of code. Signed-off-by: Shannon Nelson --- drivers/net/ethernet/sun/sunvnet.c | 14 -- 1 files

RE: [Resend PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2017-02-13 Thread Long Li
> -Original Message- > From: Bjorn Helgaas [mailto:bhelg...@google.com] > Sent: Saturday, February 11, 2017 9:35 AM > To: Long Li > Cc: KY Srinivasan ; Haiyang Zhang > ; de...@linuxdriverproject.org; linux- > p...@vger.kernel.org; linux-kernel@vger.kernel.org > Subject: Re: [Resend PATCH 1

[PATCH v4 net-next 2/8] sunvnet: remove unused variable in maybe_tx_wakeup

2017-02-13 Thread Shannon Nelson
From: Sowmini Varadhan The vio_dring_state *dr variable is unused in maybe_tx_wakeup(). As the comments indicate, we call maybe_tx_wakeup() whenever we get a STOPPED LDC message on the port. If the queue is stopped, we want to wake it up so that we will send another START message at the next TX a

[PATCH v4 net-next 1/8] sunvnet: make sunvnet common code dynamically loadable

2017-02-13 Thread Shannon Nelson
When the sunvnet_common code was split out for use by both sunvnet and the newer ldmvsw, it was made into a static kernel library, which limits the usefulness of sunvnet and ldmvsw as loadables, since most of the real work is being done in the shared code. Also, this is simply dead code in kernels

[PATCH v4 net-next 0/8] sunvnet driver updates

2017-02-13 Thread Shannon Nelson
The sunvnet ldom virtual network driver was due for some updates and a bugfix or two. These patches address a few items left over from last year's make-over. v2: - changed memory barrier fix to use smp_wmb - put NETIF_F_SG back into the advertised ldmvsw hw_features v3: - the sunvnet_common m

[PATCH V2 1/2] sched/deadline: Replenishment timer should fire in the next period

2017-02-13 Thread Daniel Bristot de Oliveira
Currently, the replenishment timer is set to fire at the deadline of a task. Although that works for implicit deadline tasks because the deadline is equals to the begin of the next period, that is not correct for constrained deadline tasks (deadline < period). For instance: f.c: ---

[PATCH V2 0/2] sched/deadline: Fixes for constrained deadline tasks

2017-02-13 Thread Daniel Bristot de Oliveira
While reading sched deadline code, I find out that a constrained deadline task could be replenished before the next period if activated after the deadline, opening the window to run for more than Q/P. The patch [2] explains and fixes this problem. Furthermore, while fixing this issue, I found that

[PATCH V2 2/2] sched/deadline: Throttle a constrained deadline task activated after the deadline

2017-02-13 Thread Daniel Bristot de Oliveira
During the activation, CBS checks if it can reuse the current task's runtime and period. If the deadline of the task is in the past, CBS cannot use the runtime, and so it replenishes the task. This rule works fine for implicit deadline tasks (deadline == period), and the CBS was designed for implic

Re: [PATCHv3] x86/selftests: add clobbers for int80 on x86_64

2017-02-13 Thread Andy Lutomirski
On Mon, Feb 13, 2017 at 2:13 AM, Dmitry Safonov wrote: > Kernel erases R8..R11 registers prior returning to userspace > from int80: https://lkml.org/lkml/2009/10/1/164 > > GCC can reuse this registers and doesn't expect them to change > during syscall invocation. I met this kind of bug in CRIU onc

Re: [PATCH v4 net-next 5/8] sunvnet: straighten up message event handling logic

2017-02-13 Thread Joe Perches
On Mon, 2017-02-13 at 10:57 -0800, Shannon Nelson wrote: > The use of gotos for handling the incoming events made this code > harder to read and support than it should be. This patch straightens > out and clears up the logic. > > Signed-off-by: Shannon Nelson > --- > drivers/net/ethernet/sun/su

Re: [PATCH 2/2] x86/vdso: Add VCLOCK_HVCLOCK vDSO clock read method

2017-02-13 Thread Andy Lutomirski
On Sun, Feb 12, 2017 at 11:49 PM, Dexuan Cui wrote: >> From: Thomas Gleixner [mailto:t...@linutronix.de] >> Sent: Saturday, February 11, 2017 02:02 >> ... >> That's important if the stuff happens cross CPU. If the update happens on >> the same CPU then this is a different story and as there are V

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Will Deacon
On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > can real DEC Alpha hardware end up with both instances of "r1" > > having the value 1? > > I thought this question reminded me of something, so I found this: > > https://www.kernel.org/doc/

[PATCH v4 0/4] Fixes for colorspace logic in exynos-gsc and s5p-mfc drivers

2017-02-13 Thread Thibault Saunier
Hello, This patchset fixes a few issues on the colorspace logic for the exynos-gsc and s5p-mfc drivers. We now handle the colorspace in those drivers, and make sure to respect user setting if possible. We also now set the 'v4l2_pix_format:field' if userspace passed ANY, avoiding GStreamer spam

[PATCH v4 1/4] [media] exynos-gsc: Use 576p instead 720p as a threshold for colorspaces

2017-02-13 Thread Thibault Saunier
From: Javier Martinez Canillas The media documentation says that the V4L2_COLORSPACE_SMPTE170M colorspace should be used for SDTV and V4L2_COLORSPACE_REC709 for HDTV. But drivers don't agree on the display resolution that should be used as a threshold. >From EIA CEA 861B about colorimetry for va

[PATCH v4 2/4] [media] exynos-gsc: Respect userspace colorspace setting in try_fmt

2017-02-13 Thread Thibault Saunier
User userspace provided by the user as we are only doing scaling and color encoding conversion, we won't be able to transform the colorspace itself and the colorspace won't mater in that operation. Also always use output colorspace on the capture side. Signed-off-by: Thibault Saunier --- Chang

Re: [PATCH RFC v2 tip/core/rcu] Maintain special bits at bottom of ->dynticks counter

2017-02-13 Thread Andy Lutomirski
On Mon, Feb 13, 2017 at 9:57 AM, Peter Zijlstra wrote: > On Mon, Feb 13, 2017 at 09:01:04AM -0800, Paul E. McKenney wrote: >> > I think I've asked this before, but why does this live in the guts of >> > RCU? >> > >> > Should we lift this state tracking stuff out and make RCU and >> > NOHZ(_FULL) u

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Paul E. McKenney
On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > can real DEC Alpha hardware end up with both instances of "r1" > > having the value 1? > > I thought this question reminded me of something, so I found this: > > https://www.kernel.org/doc/

[PATCH v4 3/4] [media] s5p-mfc: Set colorspace in VIDIO_{G,TRY}_FMT if DEFAULT provided

2017-02-13 Thread Thibault Saunier
The media documentation says that the V4L2_COLORSPACE_SMPTE170M colorspace should be used for SDTV and V4L2_COLORSPACE_REC709 for HDTV but the driver didn't set the colorimetry when userspace provided V4L2_COLORSPACE_DEFAULT. Use 576p display resolution as a threshold to set this as suggested by E

[PATCH v4 4/4] [media] s5p-mfc: Check and set 'v4l2_pix_format:field' field in try_fmt

2017-02-13 Thread Thibault Saunier
It is required by the standard that the field order is set by the driver. Signed-off-by: Thibault Saunier --- Changes in v4: None Changes in v3: - Do not check values in the g_fmt functions as Andrzej explained in previous review Changes in v2: - Fix a silly build error that slipped in while

Re: [PATCH v3 2/3] xen/privcmd: Add IOCTL_PRIVCMD_DM_OP

2017-02-13 Thread Boris Ostrovsky
diff --git a/drivers/xen/privcmd.c b/drivers/xen/privcmd.c index 5e5c7ae..a33f17e 100644 --- a/drivers/xen/privcmd.c +++ b/drivers/xen/privcmd.c @@ -22,6 +22,7 @@ #include #include #include +#include #include #include @@ -32,6 +33,7 @@ #include #include #include +#include #i

[PATCH 1/2] staging: bcm2835-audio: Removed error due to trailing statement

2017-02-13 Thread Abhijit Naik
bcm2835-vchiq.c: fixing ERROR: trailing statements should be on next line Print statement that was on the same line as else statement has been enclosed within braces and moved to the next line. Signed-off-by: Abhijit Naik --- drivers/staging/bcm2835-audio/bcm2835-vchiq.c | 4 +++- 1 file change

[PATCH 2/2] staging: bcm2835-audio: Fixed checkpatch warning due to line spacing

2017-02-13 Thread Abhijit Naik
bcm2835-vchiq.c: fixing ERROR: Checkpatch warnings due to extra blank lines or absence of blank lines where needed. Signed-off-by: Abhijit Naik --- drivers/staging/bcm2835-audio/bcm2835-vchiq.c | 18 +- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/drivers/staging

Re: [PATCH v4 net-next 5/8] sunvnet: straighten up message event handling logic

2017-02-13 Thread Shannon Nelson
On 2/13/2017 11:06 AM, Joe Perches wrote: On Mon, 2017-02-13 at 10:57 -0800, Shannon Nelson wrote: The use of gotos for handling the incoming events made this code harder to read and support than it should be. This patch straightens out and clears up the logic. Signed-off-by: Shannon Nelson -

Re: [PATCH v3 3/3] xen/privcmd: add IOCTL_PRIVCMD_RESTRICT

2017-02-13 Thread Boris Ostrovsky
On 02/13/2017 12:03 PM, Paul Durrant wrote: The purpose if this ioctl is to allow a user of privcmd to restrict its operation such that it will no longer service arbitrary hypercalls via IOCTL_PRIVCMD_HYPERCALL, and will check for a matching domid when servicing IOCTL_PRIVCMD_DM_OP. and IOCTL

Re: [PATCH v4 2/2] procfs/tasks: add a simple per-task procfs hidepid= field

2017-02-13 Thread Kees Cook
On Mon, Feb 13, 2017 at 11:01 AM, Andy Lutomirski wrote: > On Fri, Feb 10, 2017 at 3:44 PM, Kees Cook wrote: >> On Wed, Jan 18, 2017 at 3:35 PM, Andy Lutomirski wrote: >>> On Wed, Jan 18, 2017 at 2:50 PM, Djalal Harouni wrote: Andy I don't follow here, no_new_privs is never cleared right ?

Re: [PATCH v8 2/2] Add support for OV5647 sensor.

2017-02-13 Thread Ramiro Oliveira
Hi Vladimir, Thank you for your feedback. On 2/13/2017 12:21 PM, Vladimir Zapolskiy wrote: > Hello Ramiro, > > On 02/13/2017 01:25 PM, Ramiro Oliveira wrote: >> Modes supported: >> - 640x480 RAW 8 >> > > It is a pretty short commit message, please consider to write a couple > of words about th

Re: [PATCH] usercopy: add testcases to check zeroing on failure of usercopy

2017-02-13 Thread Kees Cook
On Mon, Feb 13, 2017 at 10:33 AM, Kees Cook wrote: > On Sat, Feb 11, 2017 at 10:13 PM, Hoeun Ryu wrote: >> In the hardend usercopy, the destination buffer will be zeroed if >> copy_from_user/get_user fails. This patch adds testcases for it. >> The destination buffer is set with non-zero value bef

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Michael Cree
Hi Paul, On Mon, Feb 13, 2017 at 11:09:31AM -0800, Paul E. McKenney wrote: > On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > > can real DEC Alpha hardware end up with both instances of "r1" > > > having the value 1? > > > > I thought

Re: [PATCH 2/2] x86/vdso: Add VCLOCK_HVCLOCK vDSO clock read method

2017-02-13 Thread Thomas Gleixner
On Mon, 13 Feb 2017, Andy Lutomirski wrote: > On Sun, Feb 12, 2017 at 11:49 PM, Dexuan Cui wrote: > >> From: Thomas Gleixner [mailto:t...@linutronix.de] > >> Sent: Saturday, February 11, 2017 02:02 > >> ... > >> That's important if the stuff happens cross CPU. If the update happens on > >> the s

[PATCH] usercopy: Adjust tests to deal with SMAP/PAN

2017-02-13 Thread Kees Cook
Under SMAP/PAN/etc, we cannot write directly to userspace memory, so this rearranges the test bytes to get written through copy_to_user(). Additionally fixes a small memory leak on user memory allocation failure, and drops the bad copy_from_user() test that would trigger a memcpy() against userspac

Re: [PATCHv3] x86/selftests: add clobbers for int80 on x86_64

2017-02-13 Thread Ingo Molnar
* Andy Lutomirski wrote: > On Mon, Feb 13, 2017 at 2:13 AM, Dmitry Safonov > wrote: > > Kernel erases R8..R11 registers prior returning to userspace > > from int80: https://lkml.org/lkml/2009/10/1/164 > > > > GCC can reuse this registers and doesn't expect them to change > > during syscall inv

Re: [tip:locking/core] refcount_t: Introduce a special purpose refcount type

2017-02-13 Thread Ingo Molnar
* Peter Zijlstra wrote: > > > And since size then isn't an issue what so ever anymore, remove the debug > > > knob and make all WARN()s unconditional. > > > > Are you still going to land the x86 WARN_ON improvements? > > Yes, once I manage to eke some response out of the relevant arch maintai

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Tobias Klausmann
Hi! On Mon, 13 Feb 2017, Paul E. McKenney wrote: > On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > > can real DEC Alpha hardware end up with both instances of "r1" > > > having the value 1? > > > > I thought this question reminded me

Re: [PATCH v2] x86/paravirt: Don't make vcpu_is_preempted() a callee-save function

2017-02-13 Thread Waiman Long
On 02/13/2017 05:47 AM, Peter Zijlstra wrote: > On Fri, Feb 10, 2017 at 12:00:43PM -0500, Waiman Long wrote: > +asm( +".pushsection .text;" +".global __raw_callee_save___kvm_vcpu_is_preempted;" +".type __raw_callee_save___kvm_vcpu_is_preempted, @function;" +"__raw_callee_sa

Re: [PATCH v2] x86/paravirt: Don't make vcpu_is_preempted() a callee-save function

2017-02-13 Thread Waiman Long
On 02/13/2017 05:53 AM, Peter Zijlstra wrote: > On Mon, Feb 13, 2017 at 11:47:16AM +0100, Peter Zijlstra wrote: >> That way we'd end up with something like: >> >> asm(" >> push %rdi; >> movslq %edi, %rdi; >> movq __per_cpu_offset(,%rdi,8), %rax; >> cmpb $0, %[offset](%rax); >> setne %al; >> pop %rd

RE: [PATCH] checkpatch: add warning on %pk instead of %pK usage

2017-02-13 Thread Roberts, William C
> -Original Message- > From: Joe Perches [mailto:j...@perches.com] > Sent: Friday, February 10, 2017 7:24 PM > To: Roberts, William C ; linux- > ker...@vger.kernel.org; a...@canonical.com > Cc: kernel-harden...@lists.openwall.com > Subject: Re: [PATCH] checkpatch: add warning on %pk inste

Re: [PATCH RFC v2 tip/core/rcu] Maintain special bits at bottom of ->dynticks counter

2017-02-13 Thread Paul E. McKenney
On Mon, Feb 13, 2017 at 11:08:55AM -0800, Andy Lutomirski wrote: > On Mon, Feb 13, 2017 at 9:57 AM, Peter Zijlstra wrote: > > On Mon, Feb 13, 2017 at 09:01:04AM -0800, Paul E. McKenney wrote: > >> > I think I've asked this before, but why does this live in the guts of > >> > RCU? > >> > > >> > Sho

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread bob smith
On 2/13/17 1:39 PM, Paul E. McKenney wrote: > can real DEC Alpha hardware end up with both instances of "r1" > having the value 1? I thought this question reminded me of something, so I found this: > https://www.kernel.org/doc/Documentation/memory-barriers.txt and I pasted in the content - David

Re: [PATCH - REGRESSION] mwifiex: don't enable/disable IRQ 0 during suspend/resume

2017-02-13 Thread Rajat Jain
On Fri, Feb 10, 2017 at 1:55 PM, Brian Norris wrote: > If we don't have an out-of-band wakeup IRQ configured through DT (as > most platforms don't), then we fall out of this function with > 'irq_wakeup == 0'. Other code (e.g., mwifiex_disable_wake() and > mwifiex_enable_wake()) treats 'irq_wakeup

Re: [PATCH 4.9 00/60] 4.9.10-stable review

2017-02-13 Thread Guenter Roeck
On Mon, Feb 13, 2017 at 05:03:32AM -0800, Greg Kroah-Hartman wrote: > This is the start of the stable review cycle for the 4.9.10 release. > There are 60 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know.

Re: [PATCH 4.4 00/20] 4.4.49-stable review

2017-02-13 Thread Guenter Roeck
On Mon, Feb 13, 2017 at 05:04:45AM -0800, Greg Kroah-Hartman wrote: > This is the start of the stable review cycle for the 4.4.49 release. > There are 20 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know.

[PATCH] MAINTAINERS: add tree for modules

2017-02-13 Thread Jessica Yu
Add git tree url for modules. Signed-off-by: Jessica Yu --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index cfff2c9..2ad16c2 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -8304,6 +8304,7 @@ F:drivers/media/dvb-frontends/mn88473* MODULE SUP

Re: [PATCH v2 0/9] sysctl: add and fix proper unsigned int support

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > On this v2 I've taken Alexey's recommendation and looked at array users > of the proc sysctl interface which complicate the interfece to see if > we can instead just simplify the unsigned int implementation. I could > not find any clear c

Re: [PATCH v2] x86/paravirt: Don't make vcpu_is_preempted() a callee-save function

2017-02-13 Thread Waiman Long
On 02/13/2017 02:42 PM, Waiman Long wrote: > On 02/13/2017 05:53 AM, Peter Zijlstra wrote: >> On Mon, Feb 13, 2017 at 11:47:16AM +0100, Peter Zijlstra wrote: >>> That way we'd end up with something like: >>> >>> asm(" >>> push %rdi; >>> movslq %edi, %rdi; >>> movq __per_cpu_offset(,%rdi,8), %rax; >

Re: [PATCH v2] x86/paravirt: Don't make vcpu_is_preempted() a callee-save function

2017-02-13 Thread hpa
On February 13, 2017 2:53:43 AM PST, Peter Zijlstra wrote: >On Mon, Feb 13, 2017 at 11:47:16AM +0100, Peter Zijlstra wrote: >> That way we'd end up with something like: >> >> asm(" >> push %rdi; >> movslq %edi, %rdi; >> movq __per_cpu_offset(,%rdi,8), %rax; >> cmpb $0, %[offset](%rax); >> setne

Re: [PATCH v2 1/9] sysctl: fix lax sysctl_check_table() sanity check

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > Commit 7c60c48f58a7 ("sysctl: Improve the sysctl sanity checks") > improved sanity checks considerbly, however the enhancements on > sysctl_check_table() meant adding a functional change so that > only the last table entry's sanity error

Re: [tip:locking/core] refcount_t: Introduce a special purpose refcount type

2017-02-13 Thread Linus Torvalds
On Mon, Feb 13, 2017 at 10:00 AM, Peter Zijlstra wrote: > > I think Linus' email ended up being private; not much discussion other > than him saying he would like to see this. I ended up reacting to the tipbot email, so I just replied to whoever were on the cc list there, I guess.

Re: [PATCH] checkpatch: add warning on %pk instead of %pK usage

2017-02-13 Thread Joe Perches
(resending including cc's) On Mon, 2017-02-13 at 19:46 +, Roberts, William C wrote: > > -Original Message- > > From: Joe Perches [mailto:j...@perches.com] > > Sent: Friday, February 10, 2017 7:24 PM > > To: Roberts, William C ; linux- > > ker...@vger.kernel.org; a...@canonical.com > >

Re: [PATCH V5 3/4] Move stack parameters for sed_ioctl to prevent oversized stack with CONFIG_KASAN

2017-02-13 Thread Arnd Bergmann
On Mon, Feb 13, 2017 at 6:07 PM, David Laight wrote: > From: Arnd Bergmann >> Sent: 13 February 2017 17:02 > ... >> >> > + ioctl_ptr = memdup_user(arg, _IOC_SIZE(cmd)); >> >> > + if (IS_ERR_OR_NULL(ioctl_ptr)) { >> >> > + ret = PTR_ERR(ioctl_ptr); >> >> > + goto out; >> >>

RE: [PATCH] scsi: aacraid: fix information leak on hbainfo.driver_name

2017-02-13 Thread Raghava Aditya Renukunta
Hello Colin, > -Original Message- > From: Colin King [mailto:colin.k...@canonical.com] > Sent: Tuesday, February 7, 2017 5:55 AM > To: dl-esc-Aacraid Linux Driver ; James E . J . > Bottomley ; Martin K . Petersen > ; linux-s...@vger.kernel.org > Cc: kernel-janit...@vger.kernel.org; linux-

Re: [PATCH v2 2/9] sysctl: add proper unsigned int support

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > Commit e7d316a02f6838 ("sysctl: handle error writing UINT_MAX to u32 > fields") added proc_douintvec() to start help adding support for > unsigned int, this however was only half the work needed, all these > issues are present with the cu

Re: [PATCH v8 2/2] Add support for OV5647 sensor.

2017-02-13 Thread Vladimir Zapolskiy
Hi Ramiro, On 02/13/2017 09:14 PM, Ramiro Oliveira wrote: > Hi Vladimir, > > Thank you for your feedback. > > On 2/13/2017 12:21 PM, Vladimir Zapolskiy wrote: >> Hello Ramiro, >> >> On 02/13/2017 01:25 PM, Ramiro Oliveira wrote: >>> Modes supported: >>> - 640x480 RAW 8 >>> [snip] >>> +static

Re: [PATCH v2 3/9] sysctl: add unsigned int range support

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > To keep parity with regular int interfaces provide the an unsigned > int proc_douintvec_minmax() which allows you to specify a range of > allowed valid numbers. > > Adding proc_douintvec_minmax_sysadmin() is easy but we can wait for > an

Re: [PATCH 2/2] arch/x86: Fix sparse warning symbol not declared

2017-02-13 Thread Tobin Harding
On Sun, Feb 12, 2017 at 12:06:47PM +0100, Thomas Gleixner wrote: > On Sun, 12 Feb 2017, Tobin C. Harding wrote: > > > This patch adds function declaration in order to quiet sparse symbol > > not declared warning. > > Same comment vs. 'This patch' as before. Hint, we already know that this is > a

Re: [PATCH v4 0/3] Miscellaneous fixes for BPF (perf tree)

2017-02-13 Thread Arnaldo Carvalho de Melo
Em Mon, Feb 13, 2017 at 09:42:31AM +0800, Wangnan (F) escreveu: > On 2017/2/9 4:27, Mickaël Salaün wrote: > >Mickaël Salaün (3): > > samples/bpf: Ignore already processed ELF sections > > samples/bpf: Reset global variables > > samples/bpf: Add missing header > > > > samples/bpf/bpf_load.c

Re: [PATCH v2 4/9] test_sysctl: add dedicated proc sysctl test driver

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > Although we have had tools/testing/selftests/sysctl/ with two > test cases these use existing kernel sysctl interfaces. We want > to expand test coverage, we can't just be looking for random > safe production values to poke at, instead ju

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Paul E. McKenney
On Mon, Feb 13, 2017 at 08:14:23PM +0100, Tobias Klausmann wrote: > Hi! > > On Mon, 13 Feb 2017, Paul E. McKenney wrote: > > On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > > > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > > > can real DEC Alpha hardware end up with both instances

Re: [PATCH v2 5/9] test_sysctl: add generic script to expand on tests

2017-02-13 Thread Kees Cook
On Fri, Feb 10, 2017 at 4:36 PM, Luis R. Rodriguez wrote: > This adds a generic script to let us more easily add more tests > cases. Since we really have only two types of tests cases just > fold them into the one file. Each test unit is now identified > into its separate function: > > # ./sysct

Re: Question about DEC Alpha memory ordering

2017-02-13 Thread Paul E. McKenney
On Tue, Feb 14, 2017 at 08:23:34AM +1300, Michael Cree wrote: > Hi Paul, > > On Mon, Feb 13, 2017 at 11:09:31AM -0800, Paul E. McKenney wrote: > > On Mon, Feb 13, 2017 at 01:53:27PM -0500, bob smith wrote: > > > On 2/13/17 1:39 PM, Paul E. McKenney wrote: > > > > can real DEC Alpha hardware end up

<    1   2   3   4   5   6   7   8   9   10   >