[PATCH] kprobes: avoid the kprobe being re-registered

2017-10-26 Thread Zhou Chengming
Old code use check_kprobe_rereg() to check if the kprobe has been registered already, but check_kprobe_rereg() will release the kprobe_mutex then, so maybe two paths will pass the check and register the same kprobe. This patch put the check inside the mutex. Signed-off-by: Zhou Chengming --- ker

[PATCH net] tuntap: properly align skb->head before building skb

2017-10-26 Thread Jason Wang
An unaligned alloc_frag->offset caused by previous allocation will result an unaligned skb->head. This will lead unaligned skb_shared_info and then unaligned dataref which requires to be aligned for accessing on some architecture. Fix this by aligning alloc_frag->offset before the frag refilling.

Re: [PATCH v2] lib: optimize cpumask_next_and()

2017-10-26 Thread kbuild test robot
-cpumask_next_and/20171026-184850 config: i386-randconfig-x001-201743 (attached as .config) compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901 reproduce: # save the attached .config to linux build tree make ARCH=i386 All error/warnings (new ones prefixed by >>): lib/find_bit.c: In fu

Re: [PATCH] MIPS: Boston: Fix earlycon baud rate selection

2017-10-26 Thread Matt Redfearn
Hi Paul, On 25/10/17 23:09, Paul Burton wrote: Hi Matt, On Tuesday, October 17, 2017 at 6:28 AM Matt Redfearn wrote: During set up of the early console, the earlycon driver will attempt to configure a baud rate, if one is set in the earlycon structure. Previously, of_setup_earlycon left this

Re: [PATCH 1/4] usb: xhci: remove unused variable last_freed_endpoint

2017-10-26 Thread LABBE Corentin
On Thu, Oct 26, 2017 at 12:01:54PM +, Corentin Labbe wrote: > This patch fix the following build warnings: > drivers/usb/host/xhci.c:3378:6: warning: variable 'last_freed_endpoint' set > but not used [-Wunused-but-set-variable] > > Signed-off-by: Corentin Labbe > --- > drivers/usb/host/xhci

[PATCH] net: bcmgenet: Use BUG_ON instead of if condition followed by BUG

2017-10-26 Thread Gustavo A. R. Silva
Use BUG_ON instead of if condition followed by BUG. Something to notice in this particular case is that unlikely() is already being called inside BUG_ON macro. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- drivers/net/ethernet/broadcom/genet/bcmgen

[PATCH] iio/light/opt3001: Use common error handling code in opt3001_get_lux()

2017-10-26 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 26 Oct 2017 14:06:49 +0200 * Add jump targets so that two error messages are stored only once at the end of this function implementation. * Adjust condition checks. * Replace string literals by references to two global constant variables in eight functions.

[PATCH v3] lib: optimize cpumask_next_and()

2017-10-26 Thread Clement Courbet
We've measured that we spend ~0.6% of sys cpu time in cpumask_next_and(). It's essentially a joined iteration in search for a non-zero bit, which is currently implemented as a lookup join (find a nonzero bit on the lhs, lookup the rhs to see if it's set there). Implement a direct join (find a nonz

Re: [PATCH v2] lib: optimize cpumask_next_and()

2017-10-26 Thread kbuild test robot
-cpumask_next_and/20171026-184850 config: m68k-allyesconfig (attached as .config) compiler: m68k-linux-gcc (GCC) 4.9.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to

Re: [PATCH] VFS: use synchronize_rcu_expedited() in namespace_unlock()

2017-10-26 Thread Paul E. McKenney
On Thu, Oct 26, 2017 at 01:26:37PM +1100, NeilBrown wrote: > > The synchronize_rcu() in namespace_unlock() is called every time > a filesystem is unmounted. If a great many filesystems are mounted, > this can cause a noticable slow-down in, for example, system shutdown. > > The sequence: > mkd

[PATCH] net: faraday: ftmac100: Use BUG_ON instead of if condition followed by BUG.

2017-10-26 Thread Gustavo A. R. Silva
Notice that in this particular case unlikely() is already being called inside BUG_ON macro. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- drivers/net/ethernet/faraday/ftmac100.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git

Re: [PATCH] virtio/ringtest: fix up need_event math

2017-10-26 Thread Jason Wang
On 2017年10月26日 09:48, Michael S. Tsirkin wrote: last kicked event index must be updated unconditionally: even if we don't need to kick, we do not want to re-check the same entry for events. Signed-off-by: Michael S. Tsirkin --- tools/virtio/ringtest/ring.c | 24 +++- 1

Re: [PATCH] f2fs: fix to keep backward compatibility of flexible inline xattr feature

2017-10-26 Thread Chao Yu
On 2017/10/26 19:52, Jaegeuk Kim wrote: > On 10/26, Chao Yu wrote: >> Hi Jaegeuk, >> >> On 2017/10/26 18:02, Jaegeuk Kim wrote: >>> Hi Chao, >>> >>> On 10/26, Jaegeuk Kim wrote: On 10/26, Chao Yu wrote: > Hi Jaegeuk, > > On 2017/10/26 16:42, Jaegeuk Kim wrote: >> Hi Chao, >

Re: [PATCH 1/2] drm/rcar-du: Use common error handling code in rcar_du_encoders_init()

2017-10-26 Thread kbuild test robot
-tuning-for-some-function-implementations/20171026-160928 base: git://people.freedesktop.org/~airlied/linux.git drm-next config: arm64-defconfig (attached as .config) compiler: aarch64-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705 reproduce: wget https://raw.githubusercontent.com/intel/lkp

Re: [PATCH] sound: Convert timers to use timer_setup()

2017-10-26 Thread Takashi Iwai
On Thu, 26 Oct 2017 09:09:17 +0200, Mark Brown wrote: > > On Wed, Oct 25, 2017 at 08:09:27AM -0700, Kees Cook wrote: > > In preparation for unconditionally passing the struct timer_list > > pointer to all timer callbacks, switch to using the new timer_setup() > > and from_timer() to pass the timer

Re: [PATCH] fs, mm: account filp and names caches to kmemcg

2017-10-26 Thread Tetsuo Handa
On 2017/10/26 16:49, Michal Hocko wrote: > On Wed 25-10-17 15:49:21, Greg Thelen wrote: >> Johannes Weiner wrote: >> >>> On Wed, Oct 25, 2017 at 09:00:57PM +0200, Michal Hocko wrote: > [...] So just to make it clear you would be OK with the retry on successful OOM killer invocation and f

[PATCH 0/2] backlight: pwm_bl: prevent backlight flicker when switching PWM on

2017-10-26 Thread Lothar Waßmann
These patches implement some measures to prevent backlight flicker when the backlight is being switched on for a display with an active low brightness control pin.

[PATCH 0/2] backlight: pwm_bl: prevent backlight flicker when switching PWM on

2017-10-26 Thread Lothar Waßmann
These patches implement some measures to prevent backlight flicker when the backlight is being switched on for a display with an active low brightness control pin. GIT: [PATCH 1/2] backlight: pwm_bl: Enable PWM before switching regulator GIT: [PATCH 2/2] backlight: pwm_bl: add configurable delay be

[PATCH 1/2] backlight: pwm_bl: Enable PWM before switching regulator on

2017-10-26 Thread Lothar Waßmann
When the PWM is re-enabled after being switched off, the backlight may flicker due to the backlight power being switched on while the PWM is still unconfigured. This is especially true if the PWM output is active low (assuming that the PWM output is low when the PWM is not enabled). Configure the P

[PATCH 2/2] backlight: pwm_bl: add configurable delay between re-enabling PWM and switching backlight power on

2017-10-26 Thread Lothar Waßmann
When switching the backlight on, the LCD may need some time to adjust to the configured PWM duty cycle. Add a configurable delay between configuring the PWM and enabling the backlight regulator to account for this. Signed-off-by: Lothar Waßmann --- .../bindings/leds/backlight/pwm-backlight.txt

[PATCH 2/3] phy: phy-mtk-tphy: use of_device_get_match_data()

2017-10-26 Thread Chunfeng Yun
reduce the boilerplate code to get the specific data Signed-off-by: Chunfeng Yun --- drivers/phy/mediatek/phy-mtk-tphy.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/phy/mediatek/phy-mtk-tphy.c b/drivers/phy/mediatek/phy-mtk-tphy.c index 54cc44b..cdd

[PATCH 3/3] phy: phy-mtk-tphy: fix alignment warning

2017-10-26 Thread Chunfeng Yun
Fix alignment warning by checkpatch.pl with --strict Signed-off-by: Chunfeng Yun --- drivers/phy/mediatek/Kconfig|8 drivers/phy/mediatek/phy-mtk-tphy.c | 24 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/drivers/phy/mediatek/Kco

[PATCH 1/3] phy: phy-mtk-tphy: use auto instead of force to bypass utmi signals

2017-10-26 Thread Chunfeng Yun
When system is running, if usb2 phy is forced to bypass utmi signals, all PLL will be turned off, and it can't detect device connection anymore, so replace force mode with auto mode which can bypass utmi signals automatically if no device attached for normal flow. But keep the force mode to fix RX

[PATCH v2] ipv6: esp6: use BUG_ON instead of if condition followed by BUG

2017-10-26 Thread Gustavo A. R. Silva
Use BUG_ON instead of if condition followed by BUG in esp_remove_trailer. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- Changes in v2: Update the code as suggested by Herbert Xu: ret = foo(); BUG_ON(ret); net/ipv6/esp6.c | 4 ++-- 1 file change

Re: [PATCH v9 02/29] x86/boot: Relocate definition of the initial state of CR0

2017-10-26 Thread Borislav Petkov
On Thu, Oct 26, 2017 at 02:02:02AM -0700, Andy Lutomirski wrote: > I'm assuming that UMIP_REPORTED_CR0 will never change. If CR0 gets a > new field that we set some day, then I assume that CR0_STATE would add > that bit but UMIP_REPORTED_CR0 would not. Yeah, let's do that when it is actually need

Re: [PATCH v3] lib: optimize cpumask_next_and()

2017-10-26 Thread Alexey Dobriyan
> - Refactored _find_next_common_bit into _find_next_bit., as suggested >by Yury Norov. This has no adverse effects on the performance side, >as the compiler successfully inlines the code. 1) Gentoo ships 5.4.0 which doesn't inline this code on x86_64 defconfig (which has OPTIMIZE_INLININ

Re: Query regarding __hrtimer_get_next_event()

2017-10-26 Thread Thomas Gleixner
On Thu, 26 Oct 2017, Neeraj Upadhyay wrote: > We have one query regarding the __hrtimer_get_next_event(). > The expires_next.tv64 is set to 0 if it is < 0. We observed > an hrtimer interrupt storm for one of the hrtimers with > below properties: > > * Expires for the hrtimer was set to KTIME_MAX.

Re: Fixing CVE-2017-15361

2017-10-26 Thread Michal Suchánek
On Thu, 26 Oct 2017 13:16:32 +0200 Jarkko Sakkinen wrote: > On Thu, Oct 26, 2017 at 12:26:10AM +0200, Peter Huewe wrote: > > > > > > Am 25. Oktober 2017 20:53:49 MESZ schrieb Jarkko Sakkinen > > : > > >On Wed, Oct 25, 2017 at 07:17:17AM -0700, Matthew Garrett wrote: > > >> On Wed, Oct 25, 2

Re: [PATCH 0/2] livepatch: Additional fixes for callbacks feature

2017-10-26 Thread Jiri Kosina
On Fri, 20 Oct 2017, Petr Mladek wrote: > I have found few small problems when reviewing the patch adding > (un)patch callback, see > https://lkml.kernel.org/r/1507921723-1996-2-git-send-email-joe.lawre...@redhat.com > Feel free to merge them with the original patch if still possible. > > Petr Ml

Re: [PATCH v5 1/2] Add new elements for per-event-dump option

2017-10-26 Thread Arnaldo Carvalho de Melo
Em Wed, Oct 25, 2017 at 04:53:18PM +0800, yuzhoujian escreveu: > This patch will add two elements for perf_tool struct: per_event_dump > is used to mark the per-event-dump option, last_evsel_name is used > to save last evsel's name. Add a new struct perf_script_evsel to > save evsel's specific data

Re: [v2,04/16] iommu/vt-d: support flushing more TLB types

2017-10-26 Thread Lukoshkov, Maksim
On 10/6/2017 00:03, Jacob Pan wrote: Signed-off-by: Jacob Pan --- drivers/iommu/dmar.c| 53 ++--- drivers/iommu/intel-iommu.c | 3 ++- include/linux/intel-iommu.h | 10 +++-- 3 files changed, 60 insertions(+), 6 deletions(-) diff --git a

Re: [PATCH 1/2] mm: drop migrate type checks from has_unmovable_pages

2017-10-26 Thread Vlastimil Babka
On 10/19/2017 02:21 PM, Michal Hocko wrote: > On Thu 19-10-17 10:20:41, Michal Hocko wrote: >> On Thu 19-10-17 16:33:56, Joonsoo Kim wrote: >>> On Thu, Oct 19, 2017 at 09:15:03AM +0200, Michal Hocko wrote: On Thu 19-10-17 11:51:11, Joonsoo Kim wrote: >> [...] > Hello, > > This patc

Re: [tip:x86/mm] x86/mm: Add support for early encryption/decryption of memory

2017-10-26 Thread Tom Lendacky
On 10/25/2017 12:34 PM, Dave Hansen wrote: On 07/18/2017 03:51 AM, tip-bot for Tom Lendacky wrote: +/* + * This routine does not change the underlying encryption setting of the + * page(s) that map this memory. It assumes that eventually the memory is + * meant to be accessed as either encrypted

[PATCH] pids: introduce find_get_task_by_vpid helper

2017-10-26 Thread Mike Rapoport
There are several functions that do find_task_by_vpid() followed by get_task_struct(). We can use a helper function instead. Signed-off-by: Mike Rapoport --- include/linux/sched.h | 5 + kernel/futex.c | 7 +-- kernel/pid.c | 13 + kernel/ptrace.c

LTP cases covered by 0day kernel test robot

2017-10-26 Thread Fengguang Wu
Hi Ben, Here you can find the LTP cases that we run or ignore. The ignored ones are mostly problematic or too time consuming for us. https://github.com/intel/lkp-tests/blob/master/jobs/ltp.yaml https://github.com/intel/lkp-tests/blob/master/jobs/ltp-1hdd.yaml https://github.com/intel/lkp-tests/b

Re: Enabling peer to peer device transactions for PCIe devices

2017-10-26 Thread Petrosyan, Ludwig
- Original Message - > From: "David Laight" > To: "Petrosyan, Ludwig" , "Logan Gunthorpe" > > Cc: "Alexander Deucher" , "linux-kernel" > , "linux-rdma" > , "linux-nvdimm" , > "Linux-media" , > "dri-devel" , "linux-pci" > , "John Bridgman" > , "Felix Kuehling" , "Serguei > Sagalovit

Re: [PATCH 1/3] usb: host: remove ehci-msm.c

2017-10-26 Thread Alex Elder
On 10/26/2017 12:10 AM, Manu Gautam wrote: > Hi, I'll re-send with the kconfig updates pointed out by you and Felipe Balbi. Sorry about that. -Alex > > On 10/26/2017 3:31 AM, Alex Elder wrote: >> No Qualcomm SoC requires the "ehci-msm.c" code any more.

[RFC PATCH v8 1/7] dt-bindings: PCI: Add definition of PCIe WAKE# irq and PCI irq

2017-10-26 Thread Jeffy Chen
Add optional interrupts for PCIe WAKE# pin and PCI interrupt pin. Signed-off-by: Jeffy Chen --- Changes in v8: Add optional "pci", and rewrite commit message. Changes in v7: None Changes in v6: None Changes in v5: Move to pci.txt Changes in v3: None Changes in v2: None Documentation/devicetr

[RFC PATCH v8 2/7] mwifiex: Disable wakeup irq handling for pcie

2017-10-26 Thread Jeffy Chen
We are going to handle the wakeup irq in the pci core. Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7: None Changes in v6: None Changes in v5: None Changes in v3: None Changes in v2: None drivers/net/wireless/marvell/mwifiex/main.c | 4 1 file changed, 4 insertions(+) di

[RFC PATCH v8 0/7] PCI: rockchip: Move PCIe WAKE# handling into pci core

2017-10-26 Thread Jeffy Chen
Currently we are handling wake irq in mrvl wifi driver. Move it into pci core. Tested on my chromebook bob(with cros 4.4 kernel and mrvl wifi). Changes in v8: Add optional "pci", and rewrite commit message. Rewrite the commit message. Add pci-of.c and use platform_pm_ops to handle the PCIe WAKE

[RFC PATCH v8 4/7] of/irq: Adjust of pci irq parsing for multiple interrupts

2017-10-26 Thread Jeffy Chen
Currently we are considering the first irq as the PCI interrupt pin, but a pci device may have multiple interrupts(e.g. PCIe WAKE# pin). Only parse the PCI interrupt pin when the irq is unnamed or named as "pci". Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7: None Changes in v

[RFC PATCH v8 7/7] PCI / PM: Add support for the PCIe WAKE# signal for OF

2017-10-26 Thread Jeffy Chen
Add pci-of.c to handle the PCIe WAKE# interrupt. Also use the dedicated wakeirq infrastructure to simplify it. Signed-off-by: Jeffy Chen --- Changes in v8: Add pci-of.c and use platform_pm_ops to handle the PCIe WAKE# signal. Changes in v7: Move PCIE_WAKE handling into pci core. Changes in v6

[RFC PATCH v8 6/7] PCI / PM: Move acpi wakeup code to pci core

2017-10-26 Thread Jeffy Chen
Move acpi wakeup code to pci core as pci_set_wakeup(), so that other platform could reuse it. Also add .setup_dev() / .setup_host_bridge() / .cleanup() platform pm ops's callbacks to setup and cleanup pci devices and host bridge for wakeup. Signed-off-by: Jeffy Chen --- Changes in v8: None Chan

[RFC PATCH v8 5/7] PCI: Make pci_platform_pm_ops's callbacks optional

2017-10-26 Thread Jeffy Chen
Allow platforms not to provide some of the pci_platform_pm_ops's callbacks. Also change the return value -ENOSYS to -ENODEV for: warning: drivers/pci/pci.c,594: ENOSYS means 'invalid syscall nr' and nothing else Signed-off-by: Jeffy Chen --- Changes in v8: None Changes in v7: None Changes in v

[RFC PATCH v8 3/7] arm64: dts: rockchip: Handle PCIe WAKE# signal in pcie driver for Gru

2017-10-26 Thread Jeffy Chen
Currently we are handling PCIe WAKE# signal in mrvl wifi driver. Move it to rockchip pcie driver for Gru boards. Also avoid this irq been considered as the PCI interrupt pin in the of_irq_parse_pci(). Signed-off-by: Jeffy Chen --- Changes in v8: Rewrite the commit message. Changes in v7: None

Re: [PATCH V12 0/5] mmc: Add Command Queue support

2017-10-26 Thread Linus Walleij
On Tue, Oct 24, 2017 at 10:40 AM, Adrian Hunter wrote: > Here is V12 of the hardware command queue patches without the software > command queue patches, now using blk-mq and now with blk-mq support for > non-CQE I/O. Since I had my test setup going I gave this a spin with the same set of tests t

Re: [tip:sched/core] sched/idle: Micro-optimize the idle loop

2017-10-26 Thread Peter Zijlstra
On Thu, Oct 26, 2017 at 02:31:34AM -0700, tip-bot for Cheng Jian wrote: > After patch (execution in loop): > 872: 0f ae e8lfence > ARM64: > After patch (execution in loop): > c84: d5033d9fdsb ld > @@ -225,7 +226,7 @@ static void do_idle(void) >

[PATCH] hw_random: Include device.h instead of declaring struct device

2017-10-26 Thread PrasannaKumar Muralidharan
Include linux/device.h instead of declaring struct device. Signed-off-by: PrasannaKumar Muralidharan --- include/linux/hw_random.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/linux/hw_random.h b/include/linux/hw_random.h index bee0827..2ec9af7 100644 --- a/inclu

Re: [PATCH] PREEMPT_RT: sched/rr, sched/fair: defer CFS scheduler put_prev_task()

2017-10-26 Thread Peter Zijlstra
On Wed, Oct 25, 2017 at 03:26:43PM -0700, Allen Martin wrote: This is a _really_ ugly patch.

Re: 4.14-rc2 on thinkpad x220: out of memory when inserting mmc card

2017-10-26 Thread Linus Walleij
On Mon, Oct 23, 2017 at 11:27 PM, Pavel Machek wrote: > On Mon 2017-10-23 14:16:40, Linus Walleij wrote: >> On Mon, Oct 23, 2017 at 11:31 AM, Pavel Machek wrote: >> >> >> > Thinkpad X220... how do I tell if I was using them? I believe so, >> >> > because I uncovered bug in them before. >> >> >> >

Re: [PATCH 1/2] hwmon: (jc42) optionally try to disable the SMBUS timeout

2017-10-26 Thread Guenter Roeck
On 10/25/2017 11:44 PM, Peter Rosin wrote: On 2017-10-18 04:38, Guenter Roeck wrote: On 10/17/2017 03:16 PM, Rob Herring wrote: On Fri, Oct 13, 2017 at 01:35:27PM -0700, Guenter Roeck wrote: On Fri, Oct 13, 2017 at 04:26:57PM +0200, Peter Rosin wrote: On 2017-10-13 15:50, Guenter Roeck wrote:

[PATCH v2 0/2] KVM: fixes for the kernel-hardening tree

2017-10-26 Thread Paolo Bonzini
Four KVM ioctls (KVM_GET/SET_CPUID2 on x86, KVM_GET/SET_ONE_REG on ARM and s390) directly access the kvm_vcpu_arch struct. Therefore, the new usercopy hardening work in linux-next, which forbids copies from and to slab objects unless they are from kmalloc or explicitly whitelisted, breaks KVM on t

[PATCH 2/2] kvm: x86: fix KVM_XEN_HVM_CONFIG ioctl

2017-10-26 Thread Paolo Bonzini
This ioctl is obsolete (it was used by Xenner as far as I know) but still let's not break it gratuitously... Its handler is copying directly into struct kvm. Go through a bounce buffer instead, with the added benefit that we can actually do something useful with the flags argument---the previous

[PATCH] iio/pressure/hp206c: Use common error handling code in hp206c_conv_and_read()

2017-10-26 Thread SF Markus Elfring
From: Markus Elfring Date: Thu, 26 Oct 2017 15:34:46 +0200 Add a jump target so that a specific error message is stored only once at the end of this function implementation. Replace two calls of the function "dev_err" by goto statements. This issue was detected by using the Coccinelle software.

Re: [PATCH v5 1/2] Add new elements for per-event-dump option

2017-10-26 Thread Arnaldo Carvalho de Melo
Em Thu, Oct 26, 2017 at 10:01:43AM -0300, Arnaldo Carvalho de Melo escreveu: > Em Wed, Oct 25, 2017 at 04:53:18PM +0800, yuzhoujian escreveu: > > + boolper_event_dump; > > + const char *last_evsel_name; > > enum show_feature_header show_feat_hdr; > Ditto, this should be i

[PATCH 1/2] kvm: whitelist struct kvm_vcpu_arch

2017-10-26 Thread Paolo Bonzini
On x86, ARM and s390, struct kvm_vcpu_arch has a usercopy region taht is read and written by the KVM_GET/SET_CPUID2 ioctls (x86) or KVM_GET/SET_ONE_REG (ARM/s390). Without whitelisting the area, KVM is completely broken on those architectures with usercopy hardening enabled. For now, allow writin

[PATCH v2 2/3] usb: phy: remove phy-msm-usb.c

2017-10-26 Thread Alex Elder
No Qualcomm SoC requires the "phy-msm-usb.c" USB phy driver support any more, so remove the code. Suggested-by: Stephen Boyd Signed-off-by: Alex Elder Acked-by: Bjorn Andersson Acked-by: Andy Gross --- v2: Update the Kconfig file so it no longer offers to build this code, as suggested by M

Re: [PATCH] iio/light/opt3001: Use common error handling code in opt3001_get_lux()

2017-10-26 Thread Alexandre Belloni
On 26/10/2017 at 14:17:30 +0200, SF Markus Elfring wrote: > From: Markus Elfring > Date: Thu, 26 Oct 2017 14:06:49 +0200 > > * Add jump targets so that two error messages are stored only once > at the end of this function implementation. > > * Adjust condition checks. > > * Replace string lit

[PATCH v2 0/3] usb: remove some unused code

2017-10-26 Thread Alex Elder
This series deletes some Qualcomm USB code is no longer needed by any Qualcomm hardware. This version properly deletes the sections of Kconfig files that control whether the deleted code gets built. (This time I'm also sending to linux-arm-msm and linux-arm-kernel.)

[PATCH v2 3/3] usb: phy: remove phy-qcom-8x16-usb.c

2017-10-26 Thread Alex Elder
No Qualcomm SoC requires the "phy-qcom-8x16-usb.c" USB phy driver support any more, so remove the code. Suggested-by: Stephen Boyd Signed-off-by: Alex Elder Acked-by: Bjorn Andersson Acked-by: Andy Gross --- v2: Update the Kconfig file so it no longer offers to build this code, as suggeste

[PATCH v2 1/3] usb: host: remove ehci-msm.c

2017-10-26 Thread Alex Elder
No Qualcomm SoC requires the "ehci-msm.c" code any more. So remove it. Suggested-by: Stephen Boyd Signed-off-by: Alex Elder Acked-by: Bjorn Andersson Acked-by: Andy Gross --- v2: Update the Kconfig file so it no longer offers to build this code, as suggested by Manu Gautam. drivers/usb/

Re: [PATCH 2/2] kvm: x86: fix KVM_XEN_HVM_CONFIG ioctl

2017-10-26 Thread Kees Cook
On Thu, Oct 26, 2017 at 3:45 PM, Paolo Bonzini wrote: > This ioctl is obsolete (it was used by Xenner as far as I know) but > still let's not break it gratuitously... Its handler is copying > directly into struct kvm. Go through a bounce buffer instead, with > the added benefit that we can actua

Re: [PATCH] ARM64: dts: meson-gxl: Add alternate ARM Trusted Firmware reserved memory zone

2017-10-26 Thread Will Deacon
On Wed, Oct 11, 2017 at 05:23:12PM +0200, Neil Armstrong wrote: > This year, Amlogic updated the ARM Trusted Firmware reserved memory mapping > for Meson GXL SoCs and products sold since May 2017 uses this alternate > reserved memory mapping. > But products had been sold using the previous mapping.

Re: [PATCH] VFS: use synchronize_rcu_expedited() in namespace_unlock()

2017-10-26 Thread Paul E. McKenney
On Thu, Oct 26, 2017 at 05:27:43AM -0700, Paul E. McKenney wrote: > On Thu, Oct 26, 2017 at 01:26:37PM +1100, NeilBrown wrote: > > > > The synchronize_rcu() in namespace_unlock() is called every time > > a filesystem is unmounted. If a great many filesystems are mounted, > > this can cause a noti

Re: [PATCH 03/18] x86/asm/64: Move SWAPGS into the common iret-to-usermode path

2017-10-26 Thread Brian Gerst
On Thu, Oct 26, 2017 at 4:26 AM, Andy Lutomirski wrote: > All of the code paths that ended up doing IRET to usermode did > SWAPGS immediately beforehand. Move the SWAPGS into the common > code. > > Signed-off-by: Andy Lutomirski > +GLOBAL(swapgs_restore_regs_and_return_to_usermode) Is adding s

Re: [PATCH] drivers/crypto: Convert timers to use timer_setup()

2017-10-26 Thread Jamie Iles
On Wed, Oct 25, 2017 at 03:18:42AM -0700, Kees Cook wrote: > In preparation for unconditionally passing the struct timer_list pointer to > all timer callbacks, switch to using the new timer_setup() and from_timer() > to pass the timer pointer explicitly. > > Cc: Herbert Xu > Cc: Jesper Nilsson >

[PATCH v3] tpm: use struct tpm_chip for tpm_chip_find_get()

2017-10-26 Thread Jarkko Sakkinen
Device number (the character device index) is not a stable identifier for a TPM chip. That is the reason why every call site passes TPM_ANY_NUM to tpm_chip_find_get(). This commit changes the API in a way that instead a struct tpm_chip instance is given and NULL means the default chip. In addition

Re: [PATCH V12 0/5] mmc: Add Command Queue support

2017-10-26 Thread Adrian Hunter
On 26/10/17 16:32, Linus Walleij wrote: > On Tue, Oct 24, 2017 at 10:40 AM, Adrian Hunter > wrote: > >> Here is V12 of the hardware command queue patches without the software >> command queue patches, now using blk-mq and now with blk-mq support for >> non-CQE I/O. > > Since I had my test setup

bpf.h drift due to bpf_sk_redirect_map()

2017-10-26 Thread Arnaldo Carvalho de Melo
Hi John, Recently the tools/perf/ build system noticed drift in tools/include/uapi/linux/bpf.h from its master copy include/uapi/linux/bpf.h, which comes from changes from you, can you please check this? [acme@jouet linux]$ diff -u tools/include/uapi/linux/bpf.h include/uapi/linux/bpf.h

Re: [Part2 PATCH v6 13/38] crypto: ccp: Add Secure Encrypted Virtualization (SEV) command support

2017-10-26 Thread Borislav Petkov
On Mon, Oct 23, 2017 at 02:57:04PM -0500, Brijesh Singh wrote: > Calling PLATFORM_GET_STATUS is not required, we can manage the state through > a simple ref count variable. Issuing PSP commands will always be much more > expensive compare to accessing a protected global variable. What does "protec

Re: [PATCH] pids: introduce find_get_task_by_vpid helper

2017-10-26 Thread Oleg Nesterov
On 10/26, Mike Rapoport wrote: > > There are several functions that do find_task_by_vpid() followed by > get_task_struct(). We can use a helper function instead. Yes, agreed, I was going to do this many times. > --- a/kernel/futex.c > +++ b/kernel/futex.c > @@ -870,12 +870,7 @@ static struct task

Re: [PATCH 1/2] mm: drop migrate type checks from has_unmovable_pages

2017-10-26 Thread Michal Hocko
On Thu 19-10-17 14:21:18, Michal Hocko wrote: [...] > From 8cbd811d741f5dd93d1b21bb3ef94482a4d0bd32 Mon Sep 17 00:00:00 2001 > From: Michal Hocko > Date: Thu, 19 Oct 2017 14:14:02 +0200 > Subject: [PATCH] mm: distinguish CMA and MOVABLE isolation in > has_unmovable_pages > > Joonsoo has noticed

Re: [PATCH v4] Add /proc/PID/smaps support for DAX

2017-10-26 Thread Dave Hansen
I'm honestly not understanding what problem this solves. Could you, perhaps, do a before and after of smaps with and without this patch? > +/* page structure behind DAX mappings is NOT compound page > + * when it's a huge page mappings, so introduce new API to > + * account for both PMD and PUD m

Re: [PATCH] iscsi-target: Convert timers to use timer_setup()

2017-10-26 Thread Bart Van Assche
On Thu, 2017-10-26 at 10:24 +0200, Kees Cook wrote: > On Wed, Oct 25, 2017 at 5:03 PM, Bart Van Assche > wrote: > > On Wed, 2017-10-25 at 16:10 +0200, Kees Cook wrote: > > > However, maintainers: sorry to send this one -- it can't be merged > > > yet, this uses timer_setup_on_stack() which is onl

Re: [PATCH] f2fs: fix to keep backward compatibility of flexible inline xattr feature

2017-10-26 Thread Jaegeuk Kim
On 10/26, Chao Yu wrote: > On 2017/10/26 19:52, Jaegeuk Kim wrote: > > On 10/26, Chao Yu wrote: > >> Hi Jaegeuk, > >> > >> On 2017/10/26 18:02, Jaegeuk Kim wrote: > >>> Hi Chao, > >>> > >>> On 10/26, Jaegeuk Kim wrote: > On 10/26, Chao Yu wrote: > > Hi Jaegeuk, > > > > On 2017/10/2

Re: [PATCH] cgroup/cpuset: remove circular dependency deadlock

2017-10-26 Thread Waiman Long
On 10/26/2017 07:52 AM, Prateek Sood wrote: > Remove circular dependency deadlock in a scenario where hotplug of CPU is > being done while there is updation in cgroup and cpuset triggered from > userspace. > > Process A => kthreadd => Process B => Process C => Process A > > Process A > cpu_subsys_o

Re: Fixing CVE-2017-15361

2017-10-26 Thread Jarkko Sakkinen
On Thu, Oct 26, 2017 at 02:59:02PM +0200, Michal Suchánek wrote: > It does not really matter. People ignore the messages unless looking > for something specific as you already noticed. Warn seems adequate > because the cipher is weaker than expected but not known to > be compromised. People who car

[PATCH v3 0/6] ANDROID: binder: RT priority inheritance

2017-10-26 Thread Martijn Coenen
Changes since v2 [1]: - All patches in v2 not related to priority inheritance were merged, and hence removed from this series - Fixed using the wrong mask in node scheduler policy calculation, originally reported by Ganesh Mahendran - Fixed using an uninitialized value for desired_prio, orig

[PATCH v3 1/6] ANDROID: binder: add support for RT prio inheritance.

2017-10-26 Thread Martijn Coenen
Adds support for SCHED_BATCH/SCHED_FIFO/SCHED_RR priority inheritance to the binder driver. The desired behavior is as follows: Each thread in the binder threadpool runs at a default priority, which is typically nice 0. Binder nodes (endpoints that can receive binder transactions) can have a mini

[PATCH v3 6/6] ANDROID: binder: Add tracing for binder priority inheritance.

2017-10-26 Thread Martijn Coenen
This allows to easily trace and visualize priority inheritance in the binder driver. Signed-off-by: Martijn Coenen --- drivers/android/binder.c | 4 drivers/android/binder_trace.h | 24 2 files changed, 28 insertions(+) diff --git a/drivers/android/binder.c

[PATCH v3 5/6] ANDROID: binder: don't check prio permissions on restore.

2017-10-26 Thread Martijn Coenen
Because we have disabled RT priority inheritance for the regular binder domain, the following can happen: 1) thread A (prio 98) calls into thread B 2) because RT prio inheritance is disabled, thread B runs at the lowest nice (prio 100) instead 3) thread B calls back into A; A will run at prio 1

Re: [tip:x86/mm] x86/mm: Add support for early encryption/decryption of memory

2017-10-26 Thread Dave Hansen
On 10/26/2017 06:05 AM, Tom Lendacky wrote: >>> >>> +static void __init __sme_early_enc_dec(resource_size_t paddr, >>> +   unsigned long size, bool enc) >>> +{ >>> +    void *src, *dst; >>> +    size_t len; >>> + >>> +    if (!sme_me_mask) >>> +    return; >>> + >>> +    loc

Re: [PATCH] iio/light/opt3001: Use common error handling code in opt3001_get_lux()

2017-10-26 Thread Dan Carpenter
On Thu, Oct 26, 2017 at 03:48:52PM +0200, Alexandre Belloni wrote: > On 26/10/2017 at 14:17:30 +0200, SF Markus Elfring wrote: > > From: Markus Elfring > > Date: Thu, 26 Oct 2017 14:06:49 +0200 > > > > * Add jump targets so that two error messages are stored only once > > at the end of this fun

Re: [PATCH v3] tpm: use struct tpm_chip for tpm_chip_find_get()

2017-10-26 Thread Jarkko Sakkinen
On Thu, Oct 26, 2017 at 03:54:50PM +0200, Jarkko Sakkinen wrote: > Device number (the character device index) is not a stable identifier > for a TPM chip. That is the reason why every call site passes > TPM_ANY_NUM to tpm_chip_find_get(). > > This commit changes the API in a way that instead a str

[PATCH v3 4/6] ANDROID: binder: add RT inheritance flag to node.

2017-10-26 Thread Martijn Coenen
Allows a binder node to specify whether it wants to inherit real-time scheduling policy from a caller. This inheritance may not always be desirable, for example in cases where the binder call runs untrusted and therefore potentially unbounded code. Signed-off-by: Martijn Coenen --- drivers/andro

[PATCH v3 2/6] ANDROID: binder: add min sched_policy to node.

2017-10-26 Thread Martijn Coenen
This change adds flags to flat_binder_object.flags to allow indicating a minimum scheduling policy for the node. It also clarifies the valid value range for the priority bits in the flags. Internally, we use the priority map that the kernel uses, e.g. [0..99] for real-time policies and [100..139]

[PATCH v3 3/6] ANDROID: binder: improve priority inheritance.

2017-10-26 Thread Martijn Coenen
By raising the priority of a thread selected for a transaction *before* we wake it up. Delay restoring the priority when doing a reply until after we wake-up the process receiving the reply. Signed-off-by: Martijn Coenen --- drivers/android/binder.c | 74 ++--

Re: [PATCH v6 12/13] xen/pvcalls: implement release command

2017-10-26 Thread Boris Ostrovsky
On 10/25/2017 07:00 PM, Stefano Stabellini wrote: > On Wed, 25 Oct 2017, Boris Ostrovsky wrote: >> On 10/24/2017 01:33 PM, Stefano Stabellini wrote: >>> Send PVCALLS_RELEASE to the backend and wait for a reply. Take both >>> in_mutex and out_mutex to avoid concurrent accesses. Then, free the >>> so

Re: [PATCH v3] tpm: use struct tpm_chip for tpm_chip_find_get()

2017-10-26 Thread PrasannaKumar Muralidharan
Hi Jarkko, On 26 October 2017 at 19:24, Jarkko Sakkinen wrote: > Device number (the character device index) is not a stable identifier > for a TPM chip. That is the reason why every call site passes > TPM_ANY_NUM to tpm_chip_find_get(). > > This commit changes the API in a way that instead a stru

Re: [PATCH v2] xen: fix booting ballooned down hvm guest

2017-10-26 Thread Boris Ostrovsky
On 10/26/2017 05:50 AM, Juergen Gross wrote: > Commit 96edd61dcf44362d3ef0bed1a5361e0ac7886a63 ("xen/balloon: don't > online new memory initially") introduced a regression when booting a > HVM domain with memory less than mem-max: instead of ballooning down > immediately the system would try to use

Re: [PATCH net] tuntap: properly align skb->head before building skb

2017-10-26 Thread Eric Dumazet
On Thu, Oct 26, 2017 at 5:15 AM, Jason Wang wrote: > An unaligned alloc_frag->offset caused by previous allocation will > result an unaligned skb->head. This will lead unaligned > skb_shared_info and then unaligned dataref which requires to be > aligned for accessing on some architecture. Fix this

[PATCH] MAINTAINERS: Mark hw_random as being maintained

2017-10-26 Thread PrasannaKumar Muralidharan
get_maintainer.pl shows Herbert as 'odd fixer' and does not show any maintainer at all. Herbert is maintaining hw_random so mark hw_random as maintained. This shows a maintainer for hw_random subsystem. Signed-off-by: PrasannaKumar Muralidharan --- MAINTAINERS | 2 +- 1 file changed, 1 insertion

Re: [PATCH 1/2] kvm: whitelist struct kvm_vcpu_arch

2017-10-26 Thread Cornelia Huck
On Thu, 26 Oct 2017 15:45:46 +0200 Paolo Bonzini wrote: > On x86, ARM and s390, struct kvm_vcpu_arch has a usercopy region > taht is read and written by the KVM_GET/SET_CPUID2 ioctls (x86) > or KVM_GET/SET_ONE_REG (ARM/s390). Without whitelisting the area, > KVM is completely broken on those arc

Re: [PATCH 03/18] x86/asm/64: Move SWAPGS into the common iret-to-usermode path

2017-10-26 Thread Dave Hansen
On 10/26/2017 06:52 AM, Brian Gerst wrote: > On Thu, Oct 26, 2017 at 4:26 AM, Andy Lutomirski wrote: >> All of the code paths that ended up doing IRET to usermode did >> SWAPGS immediately beforehand. Move the SWAPGS into the common >> code. >> >> Signed-off-by: Andy Lutomirski > >> +GLOBAL(swa

Re: Proposal: rename tpm1_eventlog.c and tpm2_eventlog.c

2017-10-26 Thread Jarkko Sakkinen
On Wed, Oct 25, 2017 at 03:18:48PM +0200, Jarkko Sakkinen wrote: > > Since this may conflict with the last patch set I sent, are you happy > > for me to base this new set on tpmdd/master? > > What about this: you do an updated version of your patch set that > includes these clean ups? > > PS. Sor

Re: [PATCH 2/2] Add /proc/PID/{smaps, numa_maps} support for DAX

2017-10-26 Thread Michal Hocko
On Wed 25-10-17 10:14:34, Dave Hansen wrote: > On 10/25/2017 02:30 AM, Michal Hocko wrote: > >> > >> 7f6c1780-7f6c17e0 rw-s 00:06 20559 /dev/dax12.0 > >> Size: 6144 kB > >> . > >> . > >> . > >> Ptes@2MB: 6144 kB > > This says how but it doesn't tell

Re: n900 in next-20170901

2017-10-26 Thread Tony Lindgren
* Joonsoo Kim [171025 21:45]: > On Wed, Oct 25, 2017 at 10:31:38AM -0700, Tony Lindgren wrote: > > Great, this branch boots on n900! Early parts of the dmesg attached > > below. > > Sound good. Perhaps, problem is due to the cache management. With my > patchset, direct mapping for CMA area is cle

Applied "ASoC: rt5651: Enable JD1_1 quirk for KIANO laptopt" to the asoc tree

2017-10-26 Thread Mark Brown
The patch ASoC: rt5651: Enable JD1_1 quirk for KIANO laptopt has been applied to the asoc tree at https://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 se

Applied "ASoC: intel: byt: Enable IN2 map quirk for a KIANO laptop" to the asoc tree

2017-10-26 Thread Mark Brown
The patch ASoC: intel: byt: Enable IN2 map quirk for a KIANO laptop has been applied to the asoc tree at https://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)

Applied "ASoC: rt5651: Rework quirk logic" to the asoc tree

2017-10-26 Thread Mark Brown
The patch ASoC: rt5651: Rework quirk logic has been applied to the asoc tree at https://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 Linus during

<    1   2   3   4   5   6   7   8   >