[PATCH v4 6/9] usb: musb: tusb6010_omap: Allocate DMA channels upfront

2017-05-18 Thread Peter Ujfalusi
Instead of requesting the DMA channel in tusb_omap_dma_allocate() do it when the controller is created and in runtime work from the DMA channel pool. This change is needed for the DMAengine conversion of the driver since the tusb_omap_dma_allocate() is called in interrupt context which might lead

[PATCH v4 5/9] usb: musb: tusb6010_omap: Create new struct for DMA data/parameters

2017-05-18 Thread Peter Ujfalusi
For the DMA we have ch (channel), dmareq and sync_dev parameters both within the tusb_omap_dma_ch and tusb_omap_dma struct. By creating a common struct the code can be simplified when selecting between the shared or multichannel DMA parameters. Signed-off-by: Peter Ujfalusi Tested-by: Tony Lindgr

[PATCH v4 8/9] ARM: OMAP2+: DMA: Add slave map entries for 24xx external request lines

2017-05-18 Thread Peter Ujfalusi
The external request lines are used by tusb6010 on OMAP24xx platforms. Update the map so the driver can use dmaengine API to request the DMA channel. At the same time add temporary map containing only the external DMA request numbers for DT booted case on omap24xx since the tusb6010 stack is not ye

Re: [PATCH] net: ieee802154: fix net_device reference release too early

2017-05-18 Thread Stefan Schmidt
Hello. On Thu, 2017-05-18 at 15:50, linzhang wrote: > This patch fixes the kernel oops when release net_device reference in > advance. In function raw_sendmsg(i think the dgram_sendmsg has the same > problem), there is a race condition between dev_put and dev_queue_xmit > when the device is gong

Re: [PATCH-stable] serial: samsung: Bring back removed variable to fix compilation

2017-05-18 Thread Greg Kroah-Hartman
On Thu, May 18, 2017 at 02:59:32PM +0200, Krzysztof Kozlowski wrote: > On Thu, May 18, 2017 at 2:31 PM, Krzysztof Kozlowski > wrote: > > I need to fixup the from field. It should be k...@kernel.org. I've merged this with the original patch so nothing breaks... thanks, greg k-h

Re: [PATCH 3/3] livepatch: force transition process to finish

2017-05-18 Thread Libor Pechacek
On Thu 18-05-17 14:00:43, Miroslav Benes wrote: [...] > Admin can do that now by writing 2 to force sysfs attribute in livepatch > sysfs directory. TIF_PATCH_PENDING is then cleared for all tasks and the > transition can finish successfully. [...] > --- a/include/linux/livepatch.h > +++ b/include/l

Re: [PATCH-stable] serial: samsung: Bring back removed variable to fix compilation

2017-05-18 Thread Krzysztof Kozlowski
On Thu, May 18, 2017 at 3:14 PM, Greg Kroah-Hartman wrote: > On Thu, May 18, 2017 at 02:59:32PM +0200, Krzysztof Kozlowski wrote: >> On Thu, May 18, 2017 at 2:31 PM, Krzysztof Kozlowski >> wrote: >> >> I need to fixup the from field. It should be k...@kernel.org. > > I've merged this with the ori

WARNING: possible recursive locking detected on linux-next

2017-05-18 Thread Corentin Labbe
Hello Since linux-next-20170516 I got the following warning trace: [4.310450] nf_tables: (c) 2007-2009 Patrick McHardy [4.321211] [4.326516] WARNING: possible recursive locking detected [4.331823] 4.12.0-rc1-next-20170518+ #274 Not

[PATCH 3.18 10/49] usb: misc: add missing continue in switch

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Gustavo A. R. Silva commit 2c930e3d0aed1505e86e0928d323df5027817740 upstream. Add missing continue in switch. Addresses-Coverity-ID: 1248733 Signed-off-by: Gustavo A. R. Silva Acked-by: Alan

[PATCH 3.18 00/49] 3.18.54-stable review

2017-05-18 Thread Greg Kroah-Hartman
This is the start of the stable review cycle for the 3.18.54 release. There are 49 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. Responses should be made by Sat May 20 13:16:30 UTC 2017. Anything receiv

[PATCH 3.18 01/49] target/fileio: Fix zero-length READ and WRITE handling

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Bart Van Assche commit 59ac9c078141b8fd0186c0b18660a1b2c24e724e upstream. This patch fixes zero-length READ and WRITE handling in target/FILEIO, which was broken a long time back by: Since:

[PATCH 3.18 16/49] IB/IPoIB: ibX: failed to create mcg debug file

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Shamir Rabinovitch commit 771a52584096c45e4565e8aabb596eece9d73d61 upstream. When udev renames the netdev devices, ipoib debugfs entries does not get renamed. As a result, if subsequent probe

[PATCH 3.18 11/49] usb: hub: Do not attempt to autosuspend disconnected devices

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Guenter Roeck commit f5cccf49428447dfbc9edb7a04bb8fc316269781 upstream. While running a bind/unbind stress test with the dwc3 usb driver on rk3399, the following crash was observed. Unable to

[PATCH 3.18 22/49] SMB3: Work around mount failure when using SMB3 dialect to Macs

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Steve French commit 7db0a6efdc3e990cdfd4b24820d010e9eb7890ad upstream. Macs send the maximum buffer size in response on ioctl to validate negotiate security information, which causes us to fai

[PATCH 3.18 19/49] ceph: fix memory leak in __ceph_setxattr()

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Luis Henriques commit eeca958dce0a9231d1969f86196653eb50fcc9b3 upstream. The ceph_inode_xattr needs to be released when removing an xattr. Easily reproducible running the 'generic/020' test f

[PATCH 3.18 27/49] serial: omap: fix runtime-pm handling on unbind

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Johan Hovold commit 099bd73dc17ed77aa8c98323e043613b6e8f54fc upstream. An unbalanced and misplaced synchronous put was used to suspend the device on driver unbind, something which with a likew

[PATCH 3.18 29/49] Bluetooth: Fix user channel for 32bit userspace on 64bit kernel

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Szymon Janc commit ab89f0bdd63a3721f7cd3f064f39fc4ac7ca14d4 upstream. Running 32bit userspace on 64bit kernel results in MSG_CMSG_COMPAT being defined as 0x8000. This results in sendmsg fa

[PATCH 3.18 06/49] staging: vt6656: use off stack for out buffer USB transfers.

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Malcolm Priestley commit 12ecd24ef93277e4e5feaf27b0b18f2d3828bc5e upstream. Since 4.9 mandated USB buffers be heap allocated this causes the driver to fail. Since there is a wide range of buf

[PATCH 3.18 07/49] staging: gdm724x: gdm_mux: fix use-after-free on module unload

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Johan Hovold commit b58f45c8fc301fe83ee28cad3e64686c19e78f1c upstream. Make sure to deregister the USB driver before releasing the tty driver to avoid use-after-free in the USB disconnect call

[PATCH 3.18 44/49] sched: panic on corrupted stack end

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Jann Horn commit 29d6455178a09e1dc340380c582b13356227e8df upstream. Until now, hitting this BUG_ON caused a recursive oops (because oops handling involves do_exit(), which calls into the sched

[PATCH 3.18 09/49] staging: comedi: jr3_pci: cope with jiffies wraparound

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Ian Abbott commit 8ec04a491825e08068e92bed0bba7821893b6433 upstream. The timer expiry routine `jr3_pci_poll_dev()` checks for expiry by checking whether the absolute value of `jiffies` (stored

[PATCH 3.18 31/49] perf: Fix event->ctx locking

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Peter Zijlstra commit f63a8daa5812afef4f06c962351687e1ff9ccb2b upstream. There have been a few reported issues wrt. the lack of locking around changing event->ctx. This patch tries to address

[PATCH 3.18 46/49] ALSA: timer: Fix race among timer ioctls

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Takashi Iwai commit af368027a49a751d6ff4ee9e3f9961f35bb4fede upstream. ALSA timer ioctls have an open race and this may lead to a use-after-free of timer instance object. A simplistic fix is

[PATCH 3.18 41/49] ppp: defer netns reference release for ppp channel

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: WANG Cong commit 205e1e255c479f3fd77446415706463b282f94e4 upstream. Matt reported that we have a NULL pointer dereference in ppp_pernet() from ppp_connect_channel(), i.e. pch->chan_net is NULL

[PATCH 3.18 35/49] KEYS: Fix ASN.1 indefinite length object parsing

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: David Howells commit 23c8a812dc3c621009e4f0e5342aa4e2ede1ceaa upstream. This fixes CVE-2016-0758. In the ASN.1 decoder, when the length field of an ASN.1 value is extracted, it isn't validate

[PATCH 3.18 42/49] HID: core: prevent out-of-bound readings

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Benjamin Tissoires commit 50220dead1650609206efe91f0cc116132d59b3f upstream. Plugging a Logitech DJ receiver with KASAN activated raises a bunch of out-of-bound readings. The fields are alloc

[PATCH 3.18 33/49] perf: Fix race in swevent hash

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Peter Zijlstra commit 12ca6ad2e3a896256f086497a7c7406a547ee373 upstream. There's a race on CPU unplug where we free the swevent hash array while it can still have events on. This will result i

[PATCH 3.18 36/49] ext4: fix potential use after free in __ext4_journal_stop

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Lukas Czerner commit 6934da9238da947628be83635e365df41064b09b upstream. There is a use-after-free possibility in __ext4_journal_stop() in the case that we free the handle in the first jbd2_jou

Re: [PATCH 1/3] livepatch: Add force sysfs attribute

2017-05-18 Thread Miroslav Benes
On Thu, 18 May 2017, Libor Pechacek wrote: > On Thu 18-05-17 14:00:41, Miroslav Benes wrote: > > > > + pr_info("no patching in progress. Force not allowed\n"); > > proposing smoother wording and information sharing > pr_info("no patching in progress, forced action (%d) ineffective", val

[PATCH 3.18 40/49] af_unix: Guard against other == sk in unix_dgram_sendmsg

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Rainer Weikusat commit a5527dda344fff0514b7989ef7a755729769daa1 upstream. The unix_dgram_sendmsg routine use the following test if (unlikely(unix_peer(other) != sk && unix_recvq_full(other)))

Re: [PATCH] mm,oom: fix oom invocation issues

2017-05-18 Thread Roman Gushchin
On Thu, May 18, 2017 at 11:00:39AM +0200, Michal Hocko wrote: > On Thu 18-05-17 10:47:29, Michal Hocko wrote: > > > > Hmm, I guess you are right. I haven't realized that pagefault_out_of_memory > > can race and pick up another victim. For some reason I thought that the > > page fault would break o

Re: [PATCH 2/3] livepatch: send a fake signal to all blocking tasks

2017-05-18 Thread Miroslav Benes
On Thu, 18 May 2017, Libor Pechacek wrote: > On Thu 18-05-17 14:00:42, Miroslav Benes wrote: > [...] > > --- a/include/linux/livepatch.h > > +++ b/include/linux/livepatch.h > > @@ -29,6 +29,9 @@ > > > > #include > > > > +/* values for sysfs force attribute */ > > +#define KLP_FORCE_FAKE

[PATCH 3.18 37/49] sg: Fix double-free when drives detach during SG_IO

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Calvin Owens commit f3951a3709ff50990bf3e188c27d346792103432 upstream. In sg_common_write(), we free the block request and return -ENODEV if the device is detached in the middle of the SG_IO i

[PATCH 3.18 39/49] ipv6: sctp: fix lockdep splat in sctp_v6_get_dst()

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Eric Dumazet commit 69ce6487dcd364245a3d26322fc8f4ffd1e8d947 upstream. While cooking the sctp np->opt rcu fixes, I forgot to move one rcu_read_unlock() after the added rcu_dereference() in sct

[PATCH 3.18 38/49] ipv6: sctp: add rcu protection around np->opt

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Eric Dumazet commit c836a8ba93869d6a0290a6ae0047fbef09066871 upstream. This patch completes the work I did in commit 45f6fad84cc3 ("ipv6: add complete rcu protection around np->opt"), as I mis

Re: [PATCH 3/3] livepatch: force transition process to finish

2017-05-18 Thread Miroslav Benes
On Thu, 18 May 2017, Libor Pechacek wrote: > On Thu 18-05-17 14:00:43, Miroslav Benes wrote: > [...] > > Admin can do that now by writing 2 to force sysfs attribute in livepatch > > sysfs directory. TIF_PATCH_PENDING is then cleared for all tasks and the > > transition can finish successfully. > [

[PATCH 3.18 45/49] ALSA: seq: Fix race at timer setup and close

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Takashi Iwai commit 3567eb6af614dac436c4b16a8d426f9faed639b3 upstream. ALSA sequencer code has an open race between the timer setup ioctl and the close of the client. This was triggered by sy

Re: [PATCH v1 1/3] of: base: Provide of_graph_get_port_parent()

2017-05-18 Thread Laurent Pinchart
Hi Kieran, On Wednesday 17 May 2017 21:02:42 Kieran Bingham wrote: > On 17/05/17 17:36, Rob Herring wrote: > > On Wed, May 17, 2017 at 10:03 AM, Kieran Bingham wrote: > >> From: Kieran Bingham > >> > >> When handling endpoints, the v4l2 async framework needs to identify the > >> parent device of

[PATCH 3.18 34/49] ASN.1: Fix non-match detection failure on data overrun

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: David Howells commit 0d62e9dd6da45bbf0f33a8617afc5fe774c8f45f upstream. If the ASN.1 decoder is asked to parse a sequence of objects, non-optional matches get skipped if there's no more data t

[PATCH 3.18 05/49] staging: vt6656: use off stack for in buffer USB transfers.

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Malcolm Priestley commit 05c0cf88bec588a7cb34de569acd871ceef26760 upstream. Since 4.9 mandated USB buffers to be heap allocated. This causes the driver to fail. Create buffer for USB transfer

[PATCH] iommu/dma: fix function declaration

2017-05-18 Thread Arnd Bergmann
Newly added code in the ipmmu-vmsa driver showed a small mistake in a header file that can't be included by itself without CONFIG_IOMMU_DMA enabled: In file included from drivers/iommu/ipmmu-vmsa.c:13:0: include/linux/dma-iommu.h:105:94: error: 'struct device' declared inside parameter list will

[PATCH 3.18 08/49] staging: comedi: jr3_pci: fix possible null pointer dereference

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Ian Abbott commit 45292be0b3db0b7f8286683b376e2d9f949d11f9 upstream. For some reason, the driver does not consider allocation of the subdevice private data to be a fatal error when attaching t

[PATCH 3.18 30/49] arm64: make sys_call_table const

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Mark Rutland commit c623b33b4e9599c6ac5076f7db7369eb9869aa04 upstream. As with x86, mark the sys_call_table const such that it will be placed in the .rodata section. This will cause attempts t

[PATCH 3.18 32/49] arm64: perf: reject groups spanning multiple HW PMUs

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Suzuki K. Poulose commit 8fff105e13041e49b82f92eef034f363a6b1c071 upstream. The perf core implicitly rejects events spanning multiple HW PMUs, as in these cases the event->ctx will differ. How

[PATCH 3.18 04/49] USB: Proper handling of Race Condition when two USB class drivers try to call init_usb_class simultaneously

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Ajay Kaher commit 2f86a96be0ccb1302b7eee7855dbee5ce4dc5dfb upstream. There is race condition when two USB class drivers try to call init_usb_class at the same time and leads to crash. code pat

[PATCH 3.18 28/49] serial: omap: suspend device on probe errors

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Johan Hovold commit 77e6fe7fd2b7cba0bf2f2dc8cde51d7b9a35bf74 upstream. Make sure to actually suspend the device before returning after a failed (or deferred) probe. Note that autosuspend must

[PATCH 3.18 03/49] USB: serial: ftdi_sio: add device ID for Microsemi/Arrow SF2PLUS Dev Kit

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Marek Vasut commit 31c5d1922b90ddc1da6a6ddecef7cd31f17aa32b upstream. This development kit has an FT4232 on it with a custom USB VID/PID. The FT4232 provides four UARTs, but only two are used.

[PATCH 3.18 25/49] padata: free correct variable

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Jason A. Donenfeld commit 07a77929ba672d93642a56dc2255dd21e6e2290b upstream. The author meant to free the variable that was just allocated, instead of the one that failed to be allocated, but

Re: [PATCH 01/23] xfs: use uuid_copy() helper to abstract uuid_t

2017-05-18 Thread Brian Foster
On Thu, May 18, 2017 at 08:26:43AM +0200, Christoph Hellwig wrote: > From: Amir Goldstein > > uuid_t definition is about to change. > > Signed-off-by: Amir Goldstein > Signed-off-by: Christoph Hellwig > --- Reviewed-by: Brian Foster > fs/xfs/xfs_inode_item.c | 8 ++-- > 1 file changed,

[PATCH 3.18 21/49] Set unicode flag on cifs echo request to avoid Mac error

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Steve French commit 26c9cb668c7fbf9830516b75d8bee70b699ed449 upstream. Mac requires the unicode flag to be set for cifs, even for the smb echo request (which doesn't have strings). Without th

Re: [PATCH 14/23] xfs: use the common helper uuid_is_null()

2017-05-18 Thread Brian Foster
On Thu, May 18, 2017 at 08:26:56AM +0200, Christoph Hellwig wrote: > From: Amir Goldstein > > Use the common helper uuid_is_null() and remove the xfs specific > helper uuid_is_nil(). > > The common helper does not check for the NULL pointer value as > xfs helper did, but xfs code never calls the

Re: [PATCH 12/23] xfs: remove uuid_getnodeuniq and xfs_uu_t

2017-05-18 Thread Brian Foster
On Thu, May 18, 2017 at 08:26:54AM +0200, Christoph Hellwig wrote: > Directly use the v1 intepretation of uuid_t instead. > > Signed-off-by: Christoph Hellwig > --- Reviewed-by: Brian Foster > fs/xfs/uuid.c | 25 - > fs/xfs/uuid.h | 1 - > fs/xfs/xfs_mount.c

Re: [PATCH 02/23] xfs: use uuid_be to implement the uuid_t type

2017-05-18 Thread Brian Foster
On Thu, May 18, 2017 at 08:26:44AM +0200, Christoph Hellwig wrote: > Use the generic Linux definition to implement our UUID type, this will > allow using more generic infrastructure in the future. > > Signed-off-by: Christoph Hellwig > --- Reviewed-by: Brian Foster > fs/xfs/uuid.h | 4 --

[PATCH] dmaengine: bcm-sba-raid: fix Kconfig dependencies

2017-05-18 Thread Arnd Bergmann
The new driver requires both mailbox and raid support for compile testing: drivers/dma/built-in.o: In function `sba_remove': edma.c:(.text+0x4414): undefined reference to `mbox_free_channel' drivers/dma/built-in.o: In function `sba_issue_pending': edma.c:(.text+0x46cc): undefined reference to `mbo

[PATCH 3.18 17/49] IB/mlx4: Fix ib device initialization error flow

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Jack Morgenstein commit 99e68909d5aba1861897fe7afc3306c3c81b6de0 upstream. In mlx4_ib_add, procedure mlx4_ib_alloc_eqs is called to allocate EQs. However, in the mlx4_ib_add error flow, proce

[PATCH] staging: greybus: mark PM functions as __maybe_unused

2017-05-18 Thread Arnd Bergmann
Enabling the arche platform for compile testing showed a harmless warning with CONFIG_PM=n: drivers/staging/greybus/arche-platform.c:632:12: error: 'arche_platform_resume' defined but not used [-Werror=unused-function] drivers/staging/greybus/arche-platform.c:618:12: error: 'arche_platform_suspe

[PATCH 3.18 26/49] md/raid1: avoid reusing a resync bio after error handling.

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: NeilBrown commit 0c9d5b127f695818c2c5a3868c1f28ca2969e905 upstream. fix_sync_read_error() modifies a bio on a newly faulty device by setting bi_end_io to end_sync_write. This ensure that put_b

RE: [PATCH] scsi: zero per-cmd driver data for each MQ I/O

2017-05-18 Thread KY Srinivasan
> -Original Message- > From: Christoph Hellwig [mailto:h...@infradead.org] > Sent: Wednesday, May 17, 2017 11:55 PM > To: Bart Van Assche > Cc: j...@linux.vnet.ibm.com; linux-s...@vger.kernel.org; linux- > ker...@vger.kernel.org; Long Li ; > martin.peter...@oracle.com; Stephen Hemminger

[PATCH 3.18 18/49] fs/xattr.c: zero out memory copied to userspace in getxattr

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Michal Hocko commit 81be3dee96346fbe08c31be5ef74f03f6b63cf68 upstream. getxattr uses vmalloc to allocate memory if kzalloc fails. This is filled by vfs_getxattr and then copied to the userspa

[PATCH 3.18 13/49] x86/boot: Fix BSS corruption/overwrite bug in early x86 kernel startup

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Ashish Kalra commit d594aa0277e541bb997aef0bc0a55172d8138340 upstream. The minimum size for a new stack (512 bytes) setup for arch/x86/boot components when the bootloader does not setup/provid

[PATCH v2 3/4] crypto: gcm wait for crypto op not signal safe

2017-05-18 Thread Gilad Ben-Yossef
crypto_gcm_setkey() was using wait_for_completion_interruptible() to wait for completion of async crypto op but if a signal occurs it may return before DMA ops of HW crypto provider finish, thus corrupting the data buffer that is kfree'ed in this case. Resolve this by using wait_for_completion() i

[PATCH v2 4/4] crypto: Documentation: fix none signal safe sample

2017-05-18 Thread Gilad Ben-Yossef
The sample code was showing use of wait_for_completion_interruptible() for waiting for an async. crypto op to finish. However, if a signal arrived it would free the buffers used even while crypto HW might still DMA from/into the buffers. Resolve this by using wait_for_completion() instead. Report

[PATCH v2 0/4] crypto: async crypto op fixes

2017-05-18 Thread Gilad Ben-Yossef
This patch set fixes various usage and documentation errors in waiting for async crypto op to complete which can result in data corruption. Note: these were discovered in the process of working on a patch set that replaces these call sites and more with a generic implementation that will prevent t

[PATCH v2 2/4] crypto: drbg wait for crypto op not signal safe

2017-05-18 Thread Gilad Ben-Yossef
drbg_kcapi_sym_ctr() was using wait_for_completion_interruptible() to wait for completion of async crypto op but if a signal occurs it may return before DMA ops of HW crypto provider finish, thus corrupting the output buffer. Resolve this by using wait_for_completion() instead. Reported-by: Eric

[PATCH v2 1/4] crypto: handle EBUSY due to backlog correctly

2017-05-18 Thread Gilad Ben-Yossef
public_key_verify_signature() was passing the CRYPTO_TFM_REQ_MAY_BACKLOG flag to akcipher_request_set_callback() but was not handling correctly the case where a -EBUSY error could be returned from the call to crypto_akcipher_verify() if backlog was used, possibly casuing data corruption due to use-

[PATCH 3.18 02/49] usb: host: xhci: print correct command ring address

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Peter Chen commit 6fc091fb0459ade939a795bfdcaf645385b951d4 upstream. Print correct command ring address using 'val_64'. Signed-off-by: Peter Chen Signed-off-by: Mathias Nyman Signed-off-by:

Re: [PATCH v6 2/2] security: tty: make TIOCSTI ioctl require CAP_SYS_ADMIN

2017-05-18 Thread Greg KH
On Fri, May 05, 2017 at 07:20:18PM -0400, Matt Brown wrote: > This introduces the tiocsti_restrict sysctl, whose default is controlled via > CONFIG_SECURITY_TIOCSTI_RESTRICT. When activated, this control restricts > all TIOCSTI ioctl calls from non CAP_SYS_ADMIN users. > > This patch depends on pa

Re: [PATCH v3 1/3] dt-bindings: Document STM32 I2S bindings

2017-05-18 Thread Olivier MOYSAN
Hello Rob, Thanks for your comment. On 05/13/2017 02:17 AM, Rob Herring wrote: > On Thu, May 11, 2017 at 11:45:02AM +0200, olivier moysan wrote: >> Add documentation of device tree bindings for STM32 SPI/I2S. >> >> Signed-off-by: olivier moysan >> --- >> .../devicetree/bindings/sound/st,stm32-i

Re: [PATCH 0/8] clocksource: Generalize Faraday timer

2017-05-18 Thread Daniel Lezcano
m. > > > > Thanks! fttmr010 seem to work OK! > > > > I did the usual test on UC-7112-LX [1] after merging > > linux-nomadik/fttmr010 into next-20170518. > > Thanks a lot! I'll add your Tested-by tags (if I need to repost, else > I guess Daniel can add it

[PATCH 3.18 20/49] fs/block_dev: always invalidate cleancache in invalidate_bdev()

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Andrey Ryabinin commit a5f6a6a9c72eac38a7fadd1a038532bc8516337c upstream. invalidate_bdev() calls cleancache_invalidate_inode() iff ->nrpages != 0 which doen't make any sense. Make sure that

[PATCH 3.18 15/49] dm era: save spacemap metadata root after the pre-commit

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Somasundaram Krishnasamy commit 117aceb030307dcd431fdcff87ce988d3016c34a upstream. When committing era metadata to disk, it doesn't always save the latest spacemap metadata root in superblock.

[PATCH 3.18 14/49] um: Fix PTRACE_POKEUSER on x86_64

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Richard Weinberger commit 9abc74a22d85ab29cef9896a2582a530da7e79bf upstream. This is broken since ever but sadly nobody noticed. Recent versions of GDB set DR_CONTROL unconditionally and UML d

Re: [PATCH] drm/pl111: Add a debugfs node to dump our registers.

2017-05-18 Thread Linus Walleij
On Thu, May 18, 2017 at 2:56 AM, Eric Anholt wrote: > While debugging an X11 display failure, I wanted to see where we were > actually scanning out from. This is probably generally useful to > others that might be working on this device. > > Signed-off-by: Eric Anholt Looks helpful: Reviewed-b

Re: [PATCH] staging: greybus: mark PM functions as __maybe_unused

2017-05-18 Thread Johan Hovold
On Thu, May 18, 2017 at 03:28:00PM +0200, Arnd Bergmann wrote: > Enabling the arche platform for compile testing showed a harmless > warning with CONFIG_PM=n: > > drivers/staging/greybus/arche-platform.c:632:12: error: > 'arche_platform_resume' defined but not used [-Werror=unused-function] > dri

Re: [4/4] mwifiex: pcie: de-duplicate buffer allocation code

2017-05-18 Thread Kalle Valo
Brian Norris wrote: > This code was duplicated as part of the PCIe FLR code added to this > driver. Let's de-duplicate it to: > > * make things easier to read (mwifiex_pcie_free_buffers() now has a >corresponding mwifiex_pcie_alloc_buffers()) > * reduce likelihood of bugs > * make error lo

[PATCH] Btrfs: work around maybe-uninitialized warning

2017-05-18 Thread Arnd Bergmann
A rewrite of btrfs_submit_direct_hook appears to have introduced a warning: fs/btrfs/inode.c: In function 'btrfs_submit_direct_hook': fs/btrfs/inode.c:8467:14: error: 'bio' may be used uninitialized in this function [-Werror=maybe-uninitialized] Where the 'bio' variable was previously initialize

[PATCH 3.18 12/49] usb: misc: legousbtower: Fix buffers on stack

2017-05-18 Thread Greg Kroah-Hartman
3.18-stable review patch. If anyone has any objections, please let me know. -- From: Maksim Salau commit 942a48730faf149ccbf3e12ac718aee120bb3529 upstream. Allocate buffers on HEAP instead of STACK for local structures that are to be received using usb_control_msg(). Signed-o

[PATCH] ovl: fix ovl_rename error handling

2017-05-18 Thread Arnd Bergmann
We try to clean up two objects before they got initialized: fs/overlayfs/dir.c: In function 'ovl_rename': fs/overlayfs/dir.c:1060:2: error: 'newdentry' may be used uninitialized in this function [-Werror=maybe-uninitialized] fs/overlayfs/dir.c:891:17: note: 'newdentry' was declared here fs/overla

Re: [PATCH v1 2/3] device property: Add fwnode_graph_get_port_parent

2017-05-18 Thread Laurent Pinchart
Hi Kieran, Thank you for the patch. On Wednesday 17 May 2017 16:03:38 Kieran Bingham wrote: > From: Kieran Bingham > > V4L2 async notifiers can pass the endpoint fwnode rather than the device > fwnode. I'm not sure I would mention V4L2 in the commit message, as this is generic. > Provide a he

Re: [PATCH] ceph: check i_nlink while converting a file handle to dentry

2017-05-18 Thread Yan, Zheng
> On 17 May 2017, at 19:21, Luis Henriques wrote: > > Converting a file handle to a dentry can be done call after the inode > unlink. This means that __fh_to_dentry() requires an extra check to > verify the number of links is not 0. > > The issue can be easily reproduced using xfstest generic/

[PATCH 2/2] ALSA: pcm/oss: mark snd_pcm_plug_slave_format arg as const

2017-05-18 Thread Arnd Bergmann
Only one of the two declarations has the const modifier in the argument list, so we get a warning when CONFIG_SND_PCM_OSS_PLUGINS is disabled: sound/core/oss/pcm_oss.c: In function 'snd_pcm_oss_change_params': sound/core/oss/pcm_oss.c:898:47: error: passing argument 2 of 'snd_pcm_plug_slave_forma

[PATCH 1/2] ALSA: pcm: use "do {} while (0)" for empty macro

2017-05-18 Thread Arnd Bergmann
Recent compilers produce a harmless warning for the new pcm_call_notify() macro when CONFIG_SND_PCM_OSS is disabled: sound/core/pcm.c: In function 'snd_pcm_free': sound/core/pcm.c:905:37: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body] This turns the empty macro

Re: [PATCH] ATOMISP: Tidies up code warnings and errors in file

2017-05-18 Thread Greg KH
On Mon, May 08, 2017 at 11:25:55PM +0100, Mark Railton wrote: > Cleared up some errors and warnings in > drivers/staging/media/atomisp/i2c/ap1302.c > > Signed-off-by: Mark Railton > --- > drivers/staging/media/atomisp/i2c/ap1302.c | 83 > ++ > 1 file changed, 50 inse

Re: [PATCH V2 2/3] iommu: of: Ignore all errors except EPROBE_DEFER

2017-05-18 Thread Sricharan R
Hi Laurent, On 5/18/2017 6:00 PM, Laurent Pinchart wrote: > Hi Sricharan, > > On Thursday 18 May 2017 17:26:14 Sricharan R wrote: >> On 5/18/2017 4:09 PM, Laurent Pinchart wrote: >>> On Thursday 18 May 2017 15:37:09 Sricharan R wrote: While deferring the probe of IOMMU masters, xlate an

[PATCH v2] tracing: Make sure RCU is watching before calling a stack trace

2017-05-18 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" As stack tracing now requires "rcu watching", force RCU to be watching when recording a stack trace. Link: http://lkml.kernel.org/r/20170512172449.879684...@goodmis.org Cc: "Paul E. McKenney" Signed-off-by: Steven Rostedt (VMware) --- Changes since v1: My

[PATCH] drm/i915: Check C for null pointer rather than B

2017-05-18 Thread Colin King
From: Colin Ian King There are two occasions where pointer B is being check for a NULL when it should be pointer C instead. Fix these. Detected by CoverityScan, CID#1436348,1436349 ("Logically Dead Code") Fixes: 47624cc3301b60 ("drm/i915: Import the kfence selftests for i915_sw_fence") Signed-

Re: [v3,1/2] mwifiex: initiate card-specific work atomically

2017-05-18 Thread Kalle Valo
Brian Norris wrote: > The non-atomic test + set is a little awkward here, and it technically > means we might double-schedule work unnecessarily. AFAICT, this is not > really a problem, since the extra "work" will be a no-op (the flag(s) > will be cleared by then), but it's still an anti-pattern.

[PATCH v3 1/2] lib/btree.c: optimise the code by previously getpos function

2017-05-18 Thread Leno Hou
Rework the getpos() helper function and use it to remove various open-coded implemetnations of its funtionality. v2 -> v3: - getfill() returns no entry if not found the fill position v1 -> v2: - getpos() returns no entry if not found the key Reviewed-by: Andy Shevchenko Signed-off-by: Leno

[PATCH v3 1/2] lib/btree.c: optimise the code by previously getpos function

2017-05-18 Thread Leno Hou
Rework the getpos() helper function and use it to remove various open-coded implemetnations of its funtionality. v2 -> v3: - getfill() returns no entry if not found the fill position v1 -> v2: - getpos() returns no entry if not found the key Reviewed-by: Andy Shevchenko Signed-off-by: Leno

Re: wlcore: use memdup_user

2017-05-18 Thread Kalle Valo
Geliang Tang wrote: > Use memdup_user() helper instead of open-coding to simplify the code. > > Signed-off-by: Geliang Tang Patch applied to wireless-drivers-next.git, thanks. 6a01d48d47c8 wlcore: use memdup_user -- https://patchwork.kernel.org/patch/9715005/ https://wireless.wiki.kernel.or

[PATCH v3 2/2] lib/btree.c: add testcase for in-memory b+ tree

2017-05-18 Thread Leno Hou
Signed-off-by: Leno Hou --- lib/btree_test.c | 77 1 file changed, 77 insertions(+) create mode 100644 lib/btree_test.c diff --git a/lib/btree_test.c b/lib/btree_test.c new file mode 100644 index 000..90d9048 --- /dev/null +++ b/lib/b

Re: [v6 2/3] iommu/arm-smmu-v3: Add workaround for Cavium ThunderX2 erratum #74

2017-05-18 Thread Geetha Akula
On Tue, May 16, 2017 at 5:45 AM, Rob Herring wrote: > DT changes should go to DT list. > > On Fri, May 12, 2017 at 7:41 AM, Geetha sowjanya > wrote: >> From: Linu Cherian >> >> Cavium ThunderX2 SMMU implementation doesn't support page 1 register space >> and PAGE0_REGS_ONLY option is enabled as

Re: [PATCH] nvme/pci: remap BAR0 to cover admin CQ doorbell for large stride

2017-05-18 Thread Christoph Hellwig
On Thu, May 18, 2017 at 06:35:47AM +0800, Xu Yu wrote: > The existing driver initially maps 8192 bytes of BAR0 which is > intended to cover doorbells of admin SQ and CQ. However, if a > large stride, e.g. 10, is used, the doorbell of admin CQ will > be out of 8192 bytes. Consequently, a page fault

Re: [PATCH V2 2/3] iommu: of: Ignore all errors except EPROBE_DEFER

2017-05-18 Thread Laurent Pinchart
Hi Sricharan On Thursday 18 May 2017 19:08:12 Sricharan R wrote: > On 5/18/2017 6:00 PM, Laurent Pinchart wrote: > > On Thursday 18 May 2017 17:26:14 Sricharan R wrote: > >> On 5/18/2017 4:09 PM, Laurent Pinchart wrote: > >>> On Thursday 18 May 2017 15:37:09 Sricharan R wrote: > While deferri

Re: [PATCH net-next 3/6] net: bridge: break if __br_mdb_del fails

2017-05-18 Thread Nikolay Aleksandrov
On 5/18/17 12:27 AM, Vivien Didelot wrote: Be symmetric with br_mdb_add and break if __br_mdb_del returns an error. Signed-off-by: Vivien Didelot --- net/bridge/br_mdb.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/bridge/br_mdb.c b/net/bridge/br_mdb.c index d

Re: [PATCH v2] tracing: Make sure RCU is watching before calling a stack trace

2017-05-18 Thread Miroslav Benes
On Thu, 18 May 2017, Steven Rostedt wrote: > > From: "Steven Rostedt (VMware)" > > As stack tracing now requires "rcu watching", force RCU to be watching when > recording a stack trace. > > Link: http://lkml.kernel.org/r/20170512172449.879684...@goodmis.org > > Cc: "Paul E. McKenney" > Signe

Re: [PATCH v3] fscrypt: Add support for AES-128-CBC

2017-05-18 Thread David Gstir
[resend without the HTML crap - sorry about that!] Hi Eric! Thanks for the thorough review! :) > On 17 May 2017, at 20:08, Eric Biggers wrote: > > Hi David, thanks for the update! > > On Wed, May 17, 2017 at 01:21:04PM +0200, David Gstir wrote: >> From: Daniel Walter >> >> fscrypt provides

Re: [PATCH] drm/i915: Check C for null pointer rather than B

2017-05-18 Thread Chris Wilson
On Thu, May 18, 2017 at 02:39:42PM +0100, Colin King wrote: > From: Colin Ian King > > There are two occasions where pointer B is being check for a NULL > when it should be pointer C instead. Fix these. > > Detected by CoverityScan, CID#1436348,1436349 ("Logically Dead Code") > > Fixes: 47624cc

Re: [PATCH 1/2] staging: lustre: lprocfs: Use kstrtouint_from_user

2017-05-18 Thread Greg Kroah-Hartman
On Thu, May 04, 2017 at 12:13:38PM -0400, Mathias Rav wrote: > Prefer kstrtouint_from_user to copy_from_user+simple_strtoul. > > The helper function lprocfs_wr_uint() is only used to implement > "dump_granted_max" in debugfs. > > Note the slight change in semantics: The previous implementation us

Re: [PATCH v3 2/7] staging: sm750fb: unifying macro usage and definitions

2017-05-18 Thread Greg KH
On Tue, May 16, 2017 at 11:20:18AM +0200, Matej Dujava wrote: > This patch adds tabs into macro definitions so all rhs are on same column. > Move MHz macro from ddk_chip.c to ddk_chip.h. > > Signed-off-by: Matej Dujava > --- > drivers/staging/sm750fb/ddk750_chip.c| 18 > drivers/sta

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