[PATCH] mfd: cros_ec: register shutdown function for debugfs

2017-12-16 Thread Benson Leung
From: Daniel Hung-yu Wu Reboot or shutdown during delayed works could corrupt communication with EC and certain I2C controller may not be able to recover from the error state. This patch registers a shutdown callback used to cancel the debugfs log worker thread. Signed-off-by: Daniel Hung-yu Wu

Re: [PATCH] drivers: base: power: Fix GFP_KERNEL in spinlock context

2017-12-16 Thread shrikant
On Tuesday 12 December 2017 08:28 PM, Geert Uytterhoeven wrote: > Hi Shrikant, > > On Tue, Dec 12, 2017 at 2:45 PM, wrote: >> From: Shrikant Maurya >> >> As reported by Jia-Ju Bai (https://lkml.org/lkml/2017/12/11/872): >> API's are using GFP_KERNEL to allocate memory which may sleep. >> >> To

Re: [PATCH] drivers: base: power: Fix GFP_KERNEL in spinlock context

2017-12-16 Thread shrikant
On Friday 15 December 2017 02:15 PM, Pavel Machek wrote: > On Tue 2017-12-12 15:58:00, Geert Uytterhoeven wrote: >> Hi Shrikant, >> >> On Tue, Dec 12, 2017 at 2:45 PM, wrote: >>> From: Shrikant Maurya >>> >>> As reported by Jia-Ju Bai (https://lkml.org/lkml/2017/12/11/872): >>> API's are using

Re: [PATCH] drivers: base: power: Fix GFP_KERNEL in spinlock context

2017-12-16 Thread shrikant
On Tuesday 12 December 2017 10:25 PM, Rafael J. Wysocki wrote: > On Tue, Dec 12, 2017 at 2:45 PM, wrote: >> From: Shrikant Maurya >> >> As reported by Jia-Ju Bai (https://lkml.org/lkml/2017/12/11/872): >> API's are using GFP_KERNEL to allocate memory which may sleep. >> >> To ensure atomicity

[PATCH] mfd: cros_ec_dev - Use devm_mfd_add_devices

2017-12-16 Thread Benson Leung
From: Jeffy Chen Currently we are calling mfd_add_devices to add devices without matched mfd_remove_devices to remove them. That would cause warning when re-binding cros_ec_dev: [ 123.536192] sysfs: cannot create duplicate filename '/bus/platform/devices/cros- ec-accel.0' [ 123.536210] -

Re: [PATCH 4.14 00/52] 4.14.7-stable review

2017-12-16 Thread Greg Kroah-Hartman
On Sat, Dec 16, 2017 at 10:58:26AM +0530, Naresh Kamboju wrote: > On 15 December 2017 at 15:21, Greg Kroah-Hartman > wrote: > > This is the start of the stable review cycle for the 4.14.7 release. > > There are 52 patches in this series, all will be posted as a response > > to this one. If anyone

Re: [PATCH 2/8] ARM: dts: keystone*: Use a single soc0 instance

2017-12-16 Thread santosh.shilim...@oracle.com
On 12/15/17 5:38 AM, Nishanth Menon wrote: Crap.. couple of typos crept in. Apologies - Santosh, if you dont want to manualy change, I can rebase and repost if you like to any branch of your choice. Just post it against for_4.16/keystone-dts

Re: Re: KASAN: use-after-free Write in irq_bypass_register_consumer

2017-12-16 Thread Lan, Tianyu
The root cause is that kvm_irqfd_assign() and kvm_irqfd_deassign() can't be run in parallel. Some data structure(e.g, irqfd->consumer) will be crashed because irqfd may be freed in deassign path before they are used in assign path. The other data maybe used in deassign path before initialization.

Re: [PATCH 07/25] arm: keystone: dts: Remove leading 0x and 0s from bindings notation

2017-12-16 Thread santosh.shilim...@oracle.com
On 12/15/17 4:46 AM, Mathieu Malaterre wrote: Improve the DTS files by removing all the leading "0x" and zeros to fix the following dtc warnings: Warning (unit_address_format): Node /XXX unit name should not have leading "0x" and Warning (unit_address_format): Node /XXX unit name should not ha

Re: [B.A.T.M.A.N.] [RFC v3 0/4] flow_dissector: Provide basic batman-adv unicast handling

2017-12-16 Thread Sven Eckelmann
On Freitag, 15. Dezember 2017 17:51:19 CET Willem de Bruijn wrote: [] > Thanks for making these changes. The flow dissection looks good to me. > > One possible issue is that this exposes kernel fixed width types u8/u16/.. > to userspace. For posix compatibility reasons, uapi headers use the >

Re: [PATCH 0/3] thunderbolt fixes for v4.15-rc2

2017-12-16 Thread Mika Westerberg
On Tue, Dec 05, 2017 at 09:52:50AM +0100, Greg Kroah-Hartman wrote: > On Tue, Dec 05, 2017 at 10:49:13AM +0200, Mika Westerberg wrote: > > On Fri, Dec 01, 2017 at 03:08:02PM +0300, Mika Westerberg wrote: > > > Hi Greg, > > > > > > Here are two Thunderbolt fixes and one related MAINTAINERS update f

Re: [patch v2 1/2] mm, mmu_notifier: annotate mmu notifiers with blockable invalidate callbacks

2017-12-16 Thread Michal Hocko
On Fri 15-12-17 15:04:29, Andrew Morton wrote: > On Thu, 14 Dec 2017 13:30:56 -0800 (PST) David Rientjes > wrote: > > > Commit 4d4bbd8526a8 ("mm, oom_reaper: skip mm structs with mmu notifiers") > > prevented the oom reaper from unmapping private anonymous memory with the > > oom reaper when the

Re: BUG: unable to handle kernel NULL pointer dereference in fdb_find_rcu

2017-12-16 Thread Nikolay Aleksandrov
On 16/12/17 02:37, Andrei Vagin wrote: > Hi, > > We run criu tests for linux-next and today we get this bug: > > The kernel version is 4.15.0-rc3-next-20171215 > > [ 235.397328] BUG: unable to handle kernel NULL pointer dereference > at 000c > [ 235.398624] IP: fdb_find_rcu+0x3c/0x

Re: [PATCH 6/8] drm/sun4i: sun4i_layer: Wire in the frontend

2017-12-16 Thread kbuild test robot
Hi Maxime, I love your patch! Yet something to improve: [auto build test ERROR on ] url: https://github.com/0day-ci/linux/commits/Maxime-Ripard/drm-sun4i-Support-the-Display-Engine-frontend/20171216-122702 base: config: arm-allmodconfig (attached as .config) compiler: arm-linux-gnueabi

Re: [RFC 1/5] [media] rc: update sunxi-ir driver to get base frequency from devicetree

2017-12-16 Thread Mauro Carvalho Chehab
Em Sat, 16 Dec 2017 03:49:10 +0100 Philipp Rossak escreveu: Hi Phillip, This is not a full review of this patchset. I just want to point you that you should keep supporting existing DT files. > This patch updates the sunxi-ir driver to set the ir base clock from > devicetree. > > This is necce

Re: BUG: unable to handle kernel NULL pointer dereference in fdb_find_rcu

2017-12-16 Thread Nikolay Aleksandrov
On 16/12/17 11:17, Nikolay Aleksandrov wrote: > On 16/12/17 02:37, Andrei Vagin wrote: >> Hi, >> >> We run criu tests for linux-next and today we get this bug: >> >> The kernel version is 4.15.0-rc3-next-20171215 >> >> [ 235.397328] BUG: unable to handle kernel NULL pointer dereference >> at 0

[PATCH net-next 2/2] geneve: speedup geneve tunnels dismantle

2017-12-16 Thread Haishuang Yan
Since we now hold RTNL lock in geneve_exit_net, it's better batch them to speedup geneve tunnel dismantle. Signed-off-by: Haishuang Yan --- drivers/net/geneve.c | 24 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/drivers/net/geneve.c b/drivers/net/geneve

[PATCH net-next 0/2] net: speedup geneve/vxlan tunnels dismantle

2017-12-16 Thread Haishuang Yan
This patch series add batching to vxlan/geneve tunnels so that netns dismantles are less costly. Haishuang Yan (2): vxlan: speedup vxlan tunnels dismantle geneve: speedup geneve tunnels dismantle drivers/net/geneve.c | 24 drivers/net/vxlan.c | 26 +-

[PATCH net-next 1/2] vxlan: speedup vxlan tunnels dismantle

2017-12-16 Thread Haishuang Yan
Since we now hold RTNL lock in vxlan_exit_net, it's better to batch them to speedup vxlan tunnels dismantle. Signed-off-by: Haishuang Yan --- drivers/net/vxlan.c | 26 +- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/drivers/net/vxlan.c b/drivers/net/vxla

Re: [PATCH v19 1/7] xbitmap: Introduce xbitmap

2017-12-16 Thread Wei Wang
On 12/15/2017 09:24 PM, Matthew Wilcox wrote: On Fri, Dec 15, 2017 at 07:05:07PM +0800, kbuild test robot wrote: 21 struct radix_tree_node *node; 22 void **slot; ^^^ missing __rcu annotation here. Wei, could you fold that change into your

[PATCH,v2] hyperv: make HYPERV a menuconfig to ease disabling it al

2017-12-16 Thread Vincent Legoll
Hello, The following patch add a "default y" to the menuconfig to avoid breaking existing configs. Please advise if this is better, and sufficient. Tell me if these kind of changes are not welcome in the kernel, so that I won't continue with other similar work. I am an actual user of menuconfig

[PATCH] hyperv: make HYPERV a menuconfig to ease disabling it all

2017-12-16 Thread Vincent Legoll
No need to get into the submenu to disable all HYPERV-related config entries. This makes it easier to disable all HYPERV config options without entering the submenu. It will also enable one to see that en/dis-abled state from the outside menu. This is only intended to change menuconfig UI, not ch

Re: [PATCH v19 3/7] xbitmap: add more operations

2017-12-16 Thread Wei Wang
On 12/16/2017 02:42 AM, Matthew Wilcox wrote: On Tue, Dec 12, 2017 at 07:55:55PM +0800, Wei Wang wrote: +int xb_preload_and_set_bit(struct xb *xb, unsigned long bit, gfp_t gfp); I'm struggling to understand when one would use this. The xb_ API requires you to handle your own locking. But spec

Re: [PATCH v19 3/7] xbitmap: add more operations

2017-12-16 Thread Wei Wang
On 12/15/2017 12:29 AM, Tetsuo Handa wrote: Wei Wang wrote: I used the example of xb_clear_bit_range(), and xb_find_next_bit() is the same fundamentally. Please let me know if anywhere still looks fuzzy. I don't think it is the same for xb_find_next_bit() with set == 0. + if (rad

答复: [BUG]kernel softlockup due to sidtab_search_context run for long time because of too many sidtab context node

2017-12-16 Thread yangjihong
>On 12/15/2017 08:56 AM, Stephen Smalley wrote: >> On Fri, 2017-12-15 at 03:09 +, yangjihong wrote: >>> On 12/15/2017 10:31 PM, yangjihong wrote: On 12/14/2017 12:42 PM, Casey Schaufler wrote: > On 12/14/2017 9:15 AM, Stephen Smalley wrote: >> On Thu, 2017-12-14 at 09:00 -0800, Cas

Re: [PATCH] ACPI, APEI, Fix use resource_size

2017-12-16 Thread Rafael J. Wysocki
On Thu, Dec 14, 2017 at 10:37 AM, Borislav Petkov wrote: > On Thu, Dec 14, 2017 at 12:07:30AM +0100, Rafael J. Wysocki wrote: >> Which is exactly why you've got this question at all. ;-) > > So you're saying, you've got your minions to do review for you - you can > lay back and play all managerial

Re: BUG: unable to handle kernel NULL pointer dereference in fdb_find_rcu

2017-12-16 Thread Nikolay Aleksandrov
On 16/12/17 11:29, Nikolay Aleksandrov wrote: > On 16/12/17 11:17, Nikolay Aleksandrov wrote: >> On 16/12/17 02:37, Andrei Vagin wrote: >>> Hi, >>> >>> We run criu tests for linux-next and today we get this bug: >>> >>> The kernel version is 4.15.0-rc3-next-20171215 >>> >>> [ 235.397328] BUG: unab

Re: [PATCH] ACPI, APEI, Fix use resource_size

2017-12-16 Thread Rafael J. Wysocki
On Sat, Dec 16, 2017 at 11:34 AM, Rafael J. Wysocki wrote: > On Thu, Dec 14, 2017 at 10:37 AM, Borislav Petkov wrote: >> On Thu, Dec 14, 2017 at 12:07:30AM +0100, Rafael J. Wysocki wrote: >>> Which is exactly why you've got this question at all. ;-) >> >> So you're saying, you've got your minions

[PATCH,v2] efi: make EFI a menuconfig to ease disabling it all

2017-12-16 Thread Vincent Legoll
The following v2 patch adds the "default y" to avoid breaking existing configs. I don't know if using the CONFIG_EFI symbol would be better, it is spread in multiple arch/*/Kconfig files, and would make the changes more invasive. Please advise the way forward Thanks

[PATCH] efi: make EFI a menuconfig to ease disabling it all

2017-12-16 Thread Vincent Legoll
No need to get into the submenu to disable all related config entries. This makes it easier to disable all EFI config options without entering the submenu. It will also enable one to see that en/dis-abled state from the outside menu. This is only intended to change menuconfig UI, not change the c

Re: [PATCH v5 77/78] irqdomain: Convert to XArray

2017-12-16 Thread Marc Zyngier
On Fri, 15 Dec 2017 22:04:49 +, Matthew Wilcox wrote: > > From: Matthew Wilcox > > In a non-critical path, irqdomain wants to know how many entries are > stored in the xarray, so add xa_count(). This is a pretty straightforward > conversion; mostly just removing now-redundant locking. The

Re: BUG: unable to handle kernel NULL pointer dereference in fdb_find_rcu

2017-12-16 Thread Nikolay Aleksandrov
On 16/12/17 12:40, Nikolay Aleksandrov wrote: > On 16/12/17 11:29, Nikolay Aleksandrov wrote: >> On 16/12/17 11:17, Nikolay Aleksandrov wrote: >>> On 16/12/17 02:37, Andrei Vagin wrote: Hi, We run criu tests for linux-next and today we get this bug: The kernel version is 4.

Re: [PATCH v19 3/7] xbitmap: add more operations

2017-12-16 Thread Tetsuo Handa
Wei Wang wrote: > On 12/16/2017 02:42 AM, Matthew Wilcox wrote: > > On Tue, Dec 12, 2017 at 07:55:55PM +0800, Wei Wang wrote: > >> +int xb_preload_and_set_bit(struct xb *xb, unsigned long bit, gfp_t gfp); > > I'm struggling to understand when one would use this. The xb_ API > > requires you to han

[PATCH 38/45] arch/powerpc: remove duplicate includes

2017-12-16 Thread Pravin Shedge
These duplicate includes have been found with scripts/checkincludes.pl but they have been removed manually to avoid removing false positives. Signed-off-by: Pravin Shedge --- arch/powerpc/kernel/time.c | 2 -- arch/powerpc/lib/code-patching.c | 1 - arch/powerpc/mm/numa.c

Re: [patch v2 1/2] mm, mmu_notifier: annotate mmu notifiers with blockable invalidate callbacks

2017-12-16 Thread Michal Hocko
On Sat 16-12-17 15:21:51, Tetsuo Handa wrote: > On 2017/12/16 1:25, Michal Hocko wrote: > >> struct mmu_notifier_ops { > >> + /* > >> + * Flags to specify behavior of callbacks for this MMU notifier. > >> + * Used to determine which context an operation may be called. > >> + * > >> + * MM

Re: [patch v2 1/2] mm, mmu_notifier: annotate mmu notifiers with blockable invalidate callbacks

2017-12-16 Thread Michal Hocko
On Sat 16-12-17 16:14:07, Tetsuo Handa wrote: > On 2017/12/16 8:04, Andrew Morton wrote: > >> The implementation is steered toward an expensive slowpath, such as after > >> the oom reaper has grabbed mm->mmap_sem of a still alive oom victim. > > > > some tweakage, please review. > > > > From: And

Re: [PATCH v2 2/3] backlight: tdo24m: add the reset line gpio

2017-12-16 Thread Robert Jarzmik
Daniel Thompson writes: > On Fri, Oct 13, 2017 at 09:42:48PM +0200, Robert Jarzmik wrote: >> The Toppoly panels have a global reset line. Add an optional gpio >> control for this line, for platforms which have the ability to drive it. >> >> Signed-off-by: Robert Jarzmik >> --- >> drivers/video

Re: [PATCH v2 3/3] backlight: tdo24m: add model and status sysfs entries

2017-12-16 Thread Robert Jarzmik
Daniel Thompson writes: > On Fri, Oct 13, 2017 at 09:42:49PM +0200, Robert Jarzmik wrote: >> Add entries to query the panel ASIC to acquire the model number and the >> status field. This comes in handy to check that the SPI connection is >> functional and that the panel's firmware is alive. >> >

[PATCH 33/45] arch/arm: remove duplicate includes

2017-12-16 Thread Pravin Shedge
These duplicate includes have been found with scripts/checkincludes.pl but they have been removed manually to avoid removing false positives. Signed-off-by: Pravin Shedge --- arch/arm/crypto/aes-ce-glue.c| 1 - arch/arm/mach-sa1100/hackkit.c | 1 - arch/arm/mm/mmu.c

Re: [PATCH v2 1/3] backlight: tdo24m: fix the spi cs between transfers

2017-12-16 Thread Robert Jarzmik
Daniel Thompson writes: > On Fri, Oct 13, 2017 at 09:42:47PM +0200, Robert Jarzmik wrote: >> Currently the LCD display (TD035S) on the cm-x300 platform is broken and >> remains blank. > Didn't I already ack this one? Ah yes, I forgot to report the Ack, sorry, I'll add it in the v3. Cheers. -- R

Re: [PATCH] mm: thp: use down_read_trylock in khugepaged to avoid long block

2017-12-16 Thread Michal Hocko
On Sat 16-12-17 04:04:10, Yang Shi wrote: > Hi Kirill & Michal, > > Since both of you raised the same question about who holds the semaphore for > that long time, I just reply here to both of you. > > The backtrace shows vm-scalability is running with 300G memory and it is > doing munmap as below

Re: [PATCH v4 2/4] kaslr: calculate the memory region in immovable node

2017-12-16 Thread kbuild test robot
Hi Chao, Thank you for the patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v4.15-rc3 next-20171215] [cannot apply to tip/x86/core] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https

[PATCH V2 1/2] bdisp: Fix a possible sleep-in-atomic bug in bdisp_hw_reset

2017-12-16 Thread Jia-Ju Bai
The driver may sleep under a spinlock. The function call path is: bdisp_device_run (acquire the spinlock) bdisp_hw_reset msleep --> may sleep To fix it, readl_poll_timeout_atomic is used to replace msleep. This bug is found by my static analysis tool(DSAC) and checked by my code review. S

Re: [PATCH resend] mm/page_alloc: fix comment is __get_free_pages

2017-12-16 Thread Michal Hocko
On Fri 15-12-17 12:57:35, Andrew Morton wrote: > On Fri, 15 Dec 2017 10:36:18 +0100 Michal Hocko wrote: > > > > > > > > > So do we care and I will resend the patch in that case or I just drop > > > > this from my patch queue? > > > > > > Well.. I still think that silently accepting bad input w

Re: [PATCH 1/2] bdisp: Fix a possible sleep-in-atomic bug in bdisp_hw_reset

2017-12-16 Thread Jia-Ju Bai
Hi, On 2017/12/15 22:51, Fabien DESSENNE wrote: Hi On 12/12/17 14:47, Jia-Ju Bai wrote: The driver may sleep under a spinlock. The function call path is: bdisp_device_run (acquire the spinlock) bdisp_hw_reset msleep --> may sleep To fix it, msleep is replaced with mdelay. May I sug

[PATCH 04/45] gpu: drm: remove duplicate includes

2017-12-16 Thread Pravin Shedge
These duplicate includes have been found with scripts/checkincludes.pl but they have been removed manually to avoid removing false positives. Signed-off-by: Pravin Shedge --- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c | 1 - drivers/gpu/drm/amd/amdgpu/mxgpu_vi.c

Re: [PATCH] ACPI, APEI, Fix use resource_size

2017-12-16 Thread Borislav Petkov
On Sat, Dec 16, 2017 at 11:43:27AM +0100, Rafael J. Wysocki wrote: > The argument of resource_size() is (const struct resource *) and res > is of type (struct apei_res *). > > I'm dropping this one. Yeah, us reviewing this one was one big FAIL. And I tell myself everytime - build those patches f

[PATCH 7/7] blk-mq: rename blk_mq_hw_ctx->queue_rq_srcu to ->srcu

2017-12-16 Thread Tejun Heo
The RCU protection has been expanded to cover both queueing and completion paths making ->queue_rq_srcu a misnomer. Rename it to ->srcu as suggested by Bart. Signed-off-by: Tejun Heo Cc: Bart Van Assche --- block/blk-mq.c | 22 +++--- include/linux/blk-mq.h | 2 +- 2 f

[PATCHSET v3] blk-mq: reimplement timeout handling

2017-12-16 Thread Tejun Heo
Hello, Changes from [v2] - Possible extended looping around seqcount and u64_stat_sync fixed. - Misplaced MQ_RQ_IDLE state setting fixed. - RQF_MQ_TIMEOUT_EXPIRED added to prevent firing the same timeout multiple times. - s/queue_rq_src/srcu/ patch added. - Other misc changes. Changes from

[PATCH 6/7] blk-mq: remove REQ_ATOM_STARTED

2017-12-16 Thread Tejun Heo
After the recent updates to use generation number and state based synchronization, we can easily replace REQ_ATOM_STARTED usages by adding an extra state to distinguish completed but not yet freed state. Add MQ_RQ_COMPLETE and replace REQ_ATOM_STARTED usages with blk_mq_rq_state() tests. REQ_ATOM

[PATCH 1/7] blk-mq: protect completion path with RCU

2017-12-16 Thread Tejun Heo
Currently, blk-mq protects only the issue path with RCU. This patch puts the completion path under the same RCU protection. This will be used to synchronize issue/completion against timeout by later patches, which will also add the comments. Signed-off-by: Tejun Heo --- block/blk-mq.c | 16 +++

[PATCH 5/7] blk-mq: remove REQ_ATOM_COMPLETE usages from blk-mq

2017-12-16 Thread Tejun Heo
After the recent updates to use generation number and state based synchronization, blk-mq no longer depends on REQ_ATOM_COMPLETE except to avoid firing the same timeout multiple times. Remove all REQ_ATOM_COMPLETE usages and use a new rq_flags flag RQF_MQ_TIMEOUT_EXPIRED to avoid firing the same t

[PATCH 3/7] blk-mq: use blk_mq_rq_state() instead of testing REQ_ATOM_COMPLETE

2017-12-16 Thread Tejun Heo
blk_mq_check_inflight() and blk_mq_poll_hybrid_sleep() test REQ_ATOM_COMPLETE to determine the request state. Both uses are speculative and we can test REQ_ATOM_STARTED and blk_mq_rq_state() for equivalent results. Replace the tests. This will allow removing REQ_ATOM_COMPLETE usages from blk-mq.

[PATCH 4/7] blk-mq: make blk_abort_request() trigger timeout path

2017-12-16 Thread Tejun Heo
With issue/complete and timeout paths now using the generation number and state based synchronization, blk_abort_request() is the only one which depends on REQ_ATOM_COMPLETE for arbitrating completion. There's no reason for blk_abort_request() to be a completely separate path. This patch makes bl

[PATCH 2/7] blk-mq: replace timeout synchronization with a RCU and generation based scheme

2017-12-16 Thread Tejun Heo
Currently, blk-mq timeout path synchronizes against the usual issue/completion path using a complex scheme involving atomic bitflags, REQ_ATOM_*, memory barriers and subtle memory coherence rules. Unfortunately, it contains quite a few holes. There's a complex dancing around REQ_ATOM_STARTED and

Re: [PATCHv2] ipv6: ip6mr: Recalc UDP checksum before forwarding

2017-12-16 Thread Brendan McGrath
The network diagram is very simple. It is just: VM <--* MR > PH Where: MR = Multicast Router VM = Virtual Machine (connected by a Virtual Interface using the 'virtio_net' driver) PH = Physical Host (connected by a physical Ethernet connection) * = The interface where the packet orig

Re: [PATCH] mm: thp: avoid uninitialized variable use

2017-12-16 Thread Arnd Bergmann
On Fri, Dec 15, 2017 at 7:01 PM, Yang Shi wrote: > > > On 12/15/17 4:51 AM, Arnd Bergmann wrote: >> >> When the down_read_trylock() fails, 'vma' has not been initialized >> yet, which gcc now warns about: >> >> mm/khugepaged.c: In function 'khugepaged': >> mm/khugepaged.c:1659:25: error: 'vma' may

[PATCH] drivers: gpio: remove duplicate includes

2017-12-16 Thread Pravin Shedge
These duplicate includes have been found with scripts/checkincludes.pl but they have been removed manually to avoid removing false positives. Signed-off-by: Pravin Shedge --- drivers/gpio/gpio-brcmstb.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpio/gpio-brcmstb.c b/drivers/gpio

[PATCH v2 00/19] fs: rework and optimize i_version handling in filesystems

2017-12-16 Thread Jeff Layton
From: Jeff Layton v2: - xfs should use inode_peek_iversion instead of inode_peek_iversion_raw - rework file_update_time patch - don't dirty inode when only S_ATIME is set and SB_LAZYTIME is enabled - better comments and documentation tl;dr: I think we can greatly reduce the cost of the inode->i_

[PATCH v2 05/19] afs: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton For AFS, it's generally treated as an opaque value, so we use the *_raw variants of the API here. Note that AFS has quite a different definition for this counter. AFS only increments it on changes to the data, not for the metadata. We'll need to reconcile that somehow if we eve

[PATCH v2 08/19] ext2: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/ext2/dir.c | 8 fs/ext2/super.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/ext2/dir.c b/fs/ext2/dir.c index 987647986f47..c99f14fec3f3 100644 --- a/fs/ext2/dir.c +++ b/fs/ext2/dir.c @@ -92,7 +92,7 @@

[PATCH v2 18/19] btrfs: only dirty the inode in btrfs_update_time if something was changed

2017-12-16 Thread Jeff Layton
From: Jeff Layton At this point, we know that "now" and the file times may differ, and we suspect that the i_version has been flagged to be bumped. Attempt to bump the i_version, and only mark the inode dirty if that actually occurred or if one of the times was updated. Signed-off-by: Jeff Layto

[PATCH v2 17/19] xfs: avoid setting XFS_ILOG_CORE if i_version doesn't need incrementing

2017-12-16 Thread Jeff Layton
From: Jeff Layton If XFS_ILOG_CORE is already set then go ahead and increment it. Signed-off-by: Jeff Layton --- fs/xfs/xfs_trans_inode.c | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/fs/xfs/xfs_trans_inode.c b/fs/xfs/xfs_trans_inode.c index b41a92d18140..1

[PATCH v2 19/19] fs: handle inode->i_version more efficiently

2017-12-16 Thread Jeff Layton
From: Jeff Layton Since i_version is mostly treated as an opaque value, we can exploit that fact to avoid incrementing it when no one is watching. With that change, we can avoid incrementing the counter on writes, unless someone has queried for it since it was last incremented. If the a/c/mtime d

[PATCH v2 12/19] ocfs2: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/ocfs2/dir.c | 14 +++--- fs/ocfs2/inode.c| 2 +- fs/ocfs2/namei.c| 2 +- fs/ocfs2/quota_global.c | 2 +- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/fs/ocfs2/dir.c b/fs/ocfs2/dir.c index

[PATCH v2 16/19] fs: only set S_VERSION when updating times if necessary

2017-12-16 Thread Jeff Layton
From: Jeff Layton We only really need to update i_version if someone has queried for it since we last incremented it. By doing that, we can avoid having to update the inode if the times haven't changed. If the times have changed, then we go ahead and forcibly increment the counter, under the ass

[PATCH v2 15/19] IMA: switch IMA over to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- security/integrity/ima/ima_api.c | 2 +- security/integrity/ima/ima_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/security/integrity/ima/ima_api.c b/security/integrity/ima/ima_api.c index c7e8db0ea4c0..588d4c05eb1

[PATCH v2 11/19] nfsd: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Mostly just making sure we use the "get" wrappers so we know when it is being fetched for later use. Signed-off-by: Jeff Layton --- fs/nfsd/nfsfh.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/nfsd/nfsfh.h b/fs/nfsd/nfsfh.h index 43f31cf49bae..7dedda

[PATCH v2 14/19] xfs: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/xfs/libxfs/xfs_inode_buf.c | 5 +++-- fs/xfs/xfs_icache.c | 4 ++-- fs/xfs/xfs_inode.c| 2 +- fs/xfs/xfs_inode_item.c | 2 +- fs/xfs/xfs_trans_inode.c | 2 +- 5 files changed, 8 insertions(+), 7 deletions(-) d

Re: [PATCH v2 05/19] afs: convert to new i_version API

2017-12-16 Thread Jeff Layton
On Sat, 2017-12-16 at 08:46 -0500, Jeff Layton wrote: > From: Jeff Layton > > For AFS, it's generally treated as an opaque value, so we use the > *_raw variants of the API here. > > Note that AFS has quite a different definition for this counter. AFS > only increments it on changes to the data,

[PATCH v2 13/19] ufs: use new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/ufs/dir.c | 8 fs/ufs/inode.c | 2 +- fs/ufs/super.c | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/ufs/dir.c b/fs/ufs/dir.c index 2edc1755b7c5..547c4d4c4db8 100644 --- a/fs/ufs/dir.c +++ b/fs/ufs/dir.c @@

[PATCH 0/2] PS3: Adjustments for six function implementations

2017-12-16 Thread SF Markus Elfring
From: Markus Elfring Date: Sat, 16 Dec 2017 14:42:24 +0100 Two update suggestions were taken into account from static source code analysis. Markus Elfring (2): Delete an error message for a failed memory allocation in two functions Improve a size determination in five functions drivers/ps3

[PATCH v2 10/19] nfs: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton For NFS, we just use the "raw" API since the i_version is mostly managed by the server. The exception there is when the client holds a write delegation, but we only need to bump it once there anyway to handle CB_GETATTR. Signed-off-by: Jeff Layton --- fs/nfs/delegation.c|

[PATCH v2 07/19] exofs: switch to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/exofs/dir.c | 8 fs/exofs/super.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/exofs/dir.c b/fs/exofs/dir.c index 98233a97b7b8..36e314083b80 100644 --- a/fs/exofs/dir.c +++ b/fs/exofs/dir.c @@ -60,7 +60,

[PATCH v2 09/19] ext4: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton Acked-by: Theodore Ts'o --- fs/ext4/dir.c| 8 fs/ext4/inline.c | 6 +++--- fs/ext4/inode.c | 12 fs/ext4/ioctl.c | 2 +- fs/ext4/namei.c | 4 ++-- fs/ext4/super.c | 2 +- fs/ext4/xattr.c | 4 ++-- 7 files changed

[PATCH 1/2] ps3: Delete an error message for a failed memory allocation in two functions

2017-12-16 Thread SF Markus Elfring
From: Markus Elfring Date: Sat, 16 Dec 2017 12:32:42 +0100 Omit an extra message for a memory allocation failure in these functions. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring --- drivers/ps3/ps3-lpm.c | 2 -- drivers/ps3/ps3-vuart.c | 1 - 2 fil

[PATCH v2 06/19] btrfs: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/btrfs/delayed-inode.c | 6 -- fs/btrfs/inode.c | 6 -- fs/btrfs/tree-log.c | 3 ++- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/fs/btrfs/delayed-inode.c b/fs/btrfs/delayed-inode.c index 5d73f79ded8b..1f

[PATCH v2 04/19] affs: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/affs/amigaffs.c | 4 ++-- fs/affs/dir.c | 4 ++-- fs/affs/super.c| 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/affs/amigaffs.c b/fs/affs/amigaffs.c index 0f0e6925e97d..085a93bea1e2 100644 --- a/fs/affs/amig

[PATCH v2 02/19] fs: don't take the i_lock in inode_inc_iversion

2017-12-16 Thread Jeff Layton
From: Jeff Layton The rationale for taking the i_lock when incrementing this value is lost in antiquity. The readers of the field don't take it (at least not universally), so my assumption is that it was only done here to serialize incrementors. If that is indeed the case, then we can drop the i

[PATCH v2 03/19] fat: convert to new i_version API

2017-12-16 Thread Jeff Layton
From: Jeff Layton Signed-off-by: Jeff Layton --- fs/fat/dir.c | 2 +- fs/fat/inode.c | 8 fs/fat/namei_msdos.c | 6 +++--- fs/fat/namei_vfat.c | 20 ++-- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/fs/fat/dir.c b/fs/fat/dir.c index

[PATCH 2/2] ps3: Improve a size determination in five functions

2017-12-16 Thread SF Markus Elfring
From: Markus Elfring Date: Sat, 16 Dec 2017 14:21:04 +0100 Replace the specification of data structures by variable references as the parameter for the operator "sizeof" to make the corresponding size determination a bit safer according to the Linux coding style convention. Signed-off-by: Markus

[PATCH v2 01/19] fs: new API for handling inode->i_version

2017-12-16 Thread Jeff Layton
From: Jeff Layton Add a documentation blob that explains what the i_version field is, how it is expected to work, and how it is currently implemented by various filesystems. We already have inode_inc_iversion. Add several other functions for manipulating and accessing the i_version counter. For

Re: [PATCH 5/9] ARM: dts: imx7-colibri: specify cpu-supply

2017-12-16 Thread Fabio Estevam
Hi Stefan, On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > Specify CPU supply using the "cpu-supply" property instead of > the invalid "arm-supply" property. > > Signed-off-by: Stefan Agner > --- > arch/arm/boot/dts/imx7-colibri.dtsi | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-)

Re: [PATCH 1/9] ARM: dts: imx7-colibri: move and rename USB Host power regulator

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:29 PM, Stefan Agner wrote: > The Colibri default which enables USB Host power is not necessarily > tied to the OTG2 controller, some carrier board use the pin to > control USB power for both controllers. Hence name the pinctrl > group more generic. > > Also move the regula

Re: [PATCH 2/9] ARM: dts: imx7-colibri: make sure multiplexed pins are not active

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:29 PM, Stefan Agner wrote: > The Colibri pins PWM and are multiplexed on the module, make > sure the secondary SoC pin is not active. > > Signed-off-by: Stefan Agner I haven't really understood the commit message, but this is probably because I don't have access to the

Re: [PATCH 3/9] ARM: dts: imx7-colibri: mux pull-ups where appropriate

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:29 PM, Stefan Agner wrote: > Use pull-ups instead of pull-downs for the pins which are already > pulled-up externally. > > Signed-off-by: Stefan Agner Reviewed-by: Fabio Estevam

Re: [PATCH 4/9] ARM: dts: imx7-colibri: use NAND_CE1 as GPIO

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > All Colibri iMX7 SKUs use either single-die NAND or eMMC, hence > NAND_CE1 is not used on the module and can be used as a GPIO by > carrier boards. > > Signed-off-by: Stefan Agner Reviewed-by: Fabio Estevam

Re: [PATCH 6/9] ARM: dts: imx7-colibri: specify usdhc1 supplies

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > The usdhc1 controller instance is used to provide the default > SD/MMC capabilities of the Colibri standard. The IO pins are > supplied to the SoC on the module whereas the SD-card is powered > by the Carrier Board supply. > > Signed-off-by: St

Re: [PATCH] x86: move parse_early_param to earlier code for add_efi_memmap

2017-12-16 Thread Ingo Molnar
* Dave Young wrote: > Another way is move "efi_memblock_x86_reserve_range" to later code > Maybe below is better? Yeah, that's much lower risk, if the affected EFI code does not mind being called later. We had trouble from trying to move early param parsing wholesale. I've applied your v2 pa

Re: [PATCH 7/9] ARM: dts: imx7-colibri: specify backlight GPIO

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > The Colibri standard defines SODIMM 71 as backlight enable > GPIO. Assign the GPIO to the backlight node in the module > level device tree. > > Signed-off-by: Stefan Agner Reviewed-by: Fabio Estevam

Re: [PATCH 8/9] ARM: dts: imx7-colibri: add MCP2515 CAN controller

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > +&ecspi3 { > + pinctrl-names = "default"; > + pinctrl-0 = <&pinctrl_ecspi3 &pinctrl_ecspi3_cs>; > + num-cs = <1>; num-cs can be dropped.

Re: [PATCH] x86: move parse_early_param to earlier code for add_efi_memmap

2017-12-16 Thread Ingo Molnar
* Matt Fleming wrote: > > x86_init.oem.arch_setup(); > > @@ -962,6 +959,8 @@ void __init setup_arch(char **cmdline_p) > > > > parse_early_param(); > > > > + if (efi_enabled(EFI_BOOT)) > > + efi_memblock_x86_reserve_range(); > > #ifdef CONFIG_MEMORY_HOTPLUG > > /* > >

Re: [PATCH 9/9] ARM: dts: imx7: add Toradex Colibri iMX7D 1GB (eMMC) support

2017-12-16 Thread Fabio Estevam
On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > diff --git a/arch/arm/boot/dts/imx7d-colibri-emmc-eval-v3.dts > b/arch/arm/boot/dts/imx7d-colibri-emmc-eval-v3.dts > new file mode 100644 > index ..5d5bb4c2843f > --- /dev/null > +++ b/arch/arm/boot/dts/imx7d-colibri-emmc-eval-v3.

Re: [PATCH 1/2] bdisp: Fix a possible sleep-in-atomic bug in bdisp_hw_reset

2017-12-16 Thread Mauro Carvalho Chehab
Em Sat, 16 Dec 2017 19:53:55 +0800 Jia-Ju Bai escreveu: > Hi, > > On 2017/12/15 22:51, Fabien DESSENNE wrote: > > Hi > > > > On 12/12/17 14:47, Jia-Ju Bai wrote: > >> The driver may sleep under a spinlock. > >> The function call path is: > >> bdisp_device_run (acquire the spinlock) > >> bd

Re: [PATCH 9/9] ARM: dts: imx7: add Toradex Colibri iMX7D 1GB (eMMC) support

2017-12-16 Thread Philippe Ombredanne
Dear Stefan, On Sat, Dec 16, 2017 at 3:09 PM, Fabio Estevam wrote: > On Wed, Dec 6, 2017 at 1:30 PM, Stefan Agner wrote: > >> diff --git a/arch/arm/boot/dts/imx7d-colibri-emmc-eval-v3.dts >> b/arch/arm/boot/dts/imx7d-colibri-emmc-eval-v3.dts >> new file mode 100644 >> index ..5d5bb4

[PATCH v2 1/5] runchecks: Generalize make C={1,2} to support multiple checkers

2017-12-16 Thread Knut Omang
Add scripts/runchecks which has generic support for running checker tools in a convenient and user friendly way that the author hopes can contribute to rein in issues detected by these tools in a manageable and convenient way. scripts/runchecks provides the following basic functionality: * Makes

[PATCH v2 0/5] Support for generalized use of make C={1,2} via a wrapper program

2017-12-16 Thread Knut Omang
This patch series implements features to make it easier to run checkers on the entire kernel as part of automatic and developer testing. This is done by replacing the sparse specific setup for the C={1,2} variable in the makefiles with setup for running scripts/runchecks, a new program that can ru

[PATCH v2 5/5] RDMA/core: Add runchecks.cfg for drivers/infiniband/core

2017-12-16 Thread Knut Omang
Add a runchecks.cfg to drivers/infiniband/core to start "reining in" future checker errors, and making it easier to selectively clean up existing issues. This runchecks.cfg lets make C=2 M=drivers/infiniband/core pass with all errors/warnings suppressed See Documentation/dev-tools/runchecks.rst f

[PATCH v2 4/5] rds: Add runchecks.cfg for net/rds

2017-12-16 Thread Knut Omang
Add a runchecks.cfg to net/rds to start "reining in" future checker errors, and making it easier to selectively clean up existing issues. This runchecks.cfg lets make C=2 M=net/rds pass with all errors/warnings suppressed See Documentation/dev-tools/runchecks.rst for motivation and details. Sign

[PATCH v2 3/5] checkpatch: Improve --fix-inplace for TABSTOP

2017-12-16 Thread Knut Omang
If the --fix-inplace option for TABSTOP encounters a sitation with several spaces (but less than 8) at the end of an indentation, it will assume that there are extra indentation and align back to the nearest tabstop instead of the next. This might go undetected in a "full" checkpatch --fix-inplace

  1   2   3   4   >