Re: [PATCH V2 2/3] audit: bail ASAP on syscall entry

2018-02-14 Thread Paul Moore
On Fri, Feb 9, 2018 at 9:40 PM, Richard Guy Briggs wrote: > Since removing the audit entry filter, test for early return before > setting up any context state. > > Signed-off-by: Richard Guy Briggs > --- > kernel/auditsc.c | 18 +- > 1 file changed, 9 insertions(+), 9 deletions(-

Re: [PATCH v2 2/8] mm: Add kvmalloc_ab_c and kvzalloc_struct

2018-02-14 Thread Matthew Wilcox
On Wed, Feb 14, 2018 at 12:45:52PM -0800, Joe Perches wrote: > On Wed, 2018-02-14 at 12:11 -0800, Matthew Wilcox wrote: > > We have kvmalloc_array in order to safely allocate an array with a > > number of elements specified by userspace (avoiding arithmetic overflow > > leading to a buffer overrun)

[PATCH] drm/i915/selftests: fix inconsistent IS_ERR and PTR_ERR

2018-02-14 Thread Gustavo A. R. Silva
Fix inconsistent IS_ERR and PTR_ERR in shrink_boom. The proper pointer to use is _explode_ instead of _purge_. This issue was detected with the help of Coccinelle. Fixes: fe215c8bc426 ("drm/i915/selftests: add missing gtt shrinker test") Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/i9

fs_struct refcounting: spinlock vs atomic

2018-02-14 Thread Enrico Weigelt
Hi folks, in fork.c, a spinlock is held for fs_struct refcounting, while other places - eg. switch_task_namespaces uses atomic_dec_and_test() on the nsproxy. What's the exact difference here ? Could the atomic counting also used for fs_struct ? --mtx -- Enrico Weigelt, metux IT consult Free

Re: [PATCH v4 07/24] fpga: dfl: add feature device infrastructure

2018-02-14 Thread Alan Tull
On Wed, Feb 14, 2018 at 3:03 PM, Moritz Fischer wrote: Hi Moritz, > HI Hao, > > On Tue, Feb 13, 2018 at 05:24:36PM +0800, Wu Hao wrote: >> From: Xiao Guangrong >> >> This patch abstracts the common operations of the sub features, and defines >> the feature_ops data structure, including init, ui

[PATCH v2] powerpc/via-pmu: Fix section mismatch warning

2018-02-14 Thread Mathieu Malaterre
Make the struct via_pmu_driver const to avoid following warning: WARNING: vmlinux.o(.data+0x4739c): Section mismatch in reference from the variable via_pmu_driver to the function .init.text:pmu_init() The variable via_pmu_driver references the function __init pmu_init() If the reference is valid

Re: [PATCH 1/3] jump_label: Warn on failed jump_label patch

2018-02-14 Thread Josh Poimboeuf
On Wed, Feb 14, 2018 at 12:40:34PM -0500, Steven Rostedt wrote: > On Wed, 14 Feb 2018 11:34:07 -0600 > Josh Poimboeuf wrote: > > > > And in patch 1 the warning conditions need to be tweaked a bit to > > exclude the __init case. > > > > Hmm, I wonder if we could simply remove the references fro

Re: [PATCH] powerpc/via-pmu: Fix section mismatch warning

2018-02-14 Thread Mathieu Malaterre
On Tue, Feb 13, 2018 at 7:54 PM, Laurent Vivier wrote: > On 07/02/2018 20:44, Mathieu Malaterre wrote: >> Remove the __init annotation from pmu_init() to avoid the >> following warning. >> >> WARNING: vmlinux.o(.data+0x4739c): Section mismatch in reference from the >> variable via_pmu_driver to t

Re: [PATCH 05/15] ARM64: dts: Add R-Car Salvator-x M3-N support

2018-02-14 Thread Philippe Ombredanne
Jacopo, On Wed, Feb 14, 2018 at 2:58 PM, Geert Uytterhoeven wrote: >> --- /dev/null >> +++ b/arch/arm64/boot/dts/renesas/r8a77965-salvator-x.dts >> @@ -0,0 +1,30 @@ >> +// SPDX-License-Identifier: GPL-2. This should be GPL-2.0 >> --- /dev/null >> +++ b/arch/arm64/boot/dts/renesas/r8a77965.dt

Re: [PATCH v2 2/8] mm: Add kvmalloc_ab_c and kvzalloc_struct

2018-02-14 Thread Joe Perches
On Wed, 2018-02-14 at 13:12 -0800, Matthew Wilcox wrote: > On Wed, Feb 14, 2018 at 12:45:52PM -0800, Joe Perches wrote: > > On Wed, 2018-02-14 at 12:11 -0800, Matthew Wilcox wrote: > > > We have kvmalloc_array in order to safely allocate an array with a > > > number of elements specified by userspa

Re: [PATCH v2 2/8] mm: Add kvmalloc_ab_c and kvzalloc_struct

2018-02-14 Thread Joe Perches
On Wed, 2018-02-14 at 13:24 -0800, Joe Perches wrote: > Look at your patch 4 > > - dev_dax = kzalloc(sizeof(*dev_dax) + sizeof(*res) * count, > GFP_KERNEL); > + dev_dax = kvzalloc_struct(dev_dax, res, count, GFP_KERNEL); > > Here what is being allocated is exactly a struct > and an a

Re: [PATCH 1/3] HID: add driver for Valve Steam Controller

2018-02-14 Thread Philippe Ombredanne
Benjamin, Rodrigo, On Wed, Feb 14, 2018 at 3:45 PM, Benjamin Tissoires wrote: > On Tue, Feb 13, 2018 at 1:03 PM, Rodrigo Rivas Costa > wrote: >> --- /dev/null >> +++ b/drivers/hid/hid-steam.c >> @@ -0,0 +1,480 @@ >> +// SPDX-License-Identifier: GPL-2.0 > > Non standard header Benjamin: What

Re: [PATCH v2 2/8] mm: Add kvmalloc_ab_c and kvzalloc_struct

2018-02-14 Thread Matthew Wilcox
On Wed, Feb 14, 2018 at 01:24:09PM -0800, Joe Perches wrote: > On Wed, 2018-02-14 at 13:12 -0800, Matthew Wilcox wrote: > > On Wed, Feb 14, 2018 at 12:45:52PM -0800, Joe Perches wrote: > > > Perhaps kv[zm]alloc_buf_and_array is better naming. > > > > I think that's actively misleading. The progra

Re: [PATCH] drm/amdkfd: Use ARRAY_SIZE macro in kfd_build_sysfs_node_entry

2018-02-14 Thread Gustavo A. R. Silva
Hi all, I was just wondering about the status of this patch. Thanks -- Gustavo On 01/19/2018 04:18 PM, Felix Kuehling wrote: Looks good. This change is Reviewed-by: Felix Kuehling Regards,   Felix On 2018-01-18 07:39 PM, Gustavo A. R. Silva wrote: Use ARRAY_SIZE instead of dividing sizeo

Re: [PATCH v3 1/2] ASoC: codecs: Add support for AK4458 DAC driver

2018-02-14 Thread Philippe Ombredanne
On Wed, Feb 14, 2018 at 2:21 PM, Cosmin-Gabriel Samoila wrote: > The AK4458 is a 32-bit 8ch Premium DAC that corresponds > to a 768kHz PCM input and an 11.2MHz DSD input at maximum. > It supports I2S, DSD and TDM modes with 24 or 32 bit MSB > or 16, 24, 32 LSB formats. Its datasheet is available h

RE: [RFC PATCH] MIPS: Provide cmpxchg64 for 32-bit builds

2018-02-14 Thread Keller, Jacob E
> -Original Message- > From: Michael, Alice > Sent: Wednesday, February 14, 2018 1:03 PM > To: Guenter Roeck ; James Hogan ; > Keller, Jacob E > Cc: Ralf Baechle ; linux-m...@linux-mips.org; linux- > ker...@vger.kernel.org; Kirsher, Jeffrey T ; > Shannon > Nelson > Subject: RE: [RFC PATC

Re: [PATCH 2/2] mtd: nand: gpmi: add support for specific ECC strength

2018-02-14 Thread Stefan Agner
On 14.02.2018 20:05, Boris Brezillon wrote: > On Wed, 14 Feb 2018 16:28:36 + > Han Xu wrote: > >> On 02/06/2018 11:40 AM, Stefan Agner wrote: >> > Add support for specified ECC strength/size using device tree >> > properties nand-ecc-strength/nand-ecc-step-size. >> > >> > Signed-off-by: Stefa

[PATCH 0/2] crypto/bcm: Adjustments for do_shash()

2018-02-14 Thread SF Markus Elfring
From: Markus Elfring Date: Wed, 14 Feb 2018 22:30:07 +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 One function call less after error detection drivers/crypto/bcm/util.c | 7

[PATCH 1/2] crypto: bcm: Delete an error message for a failed memory allocation in do_shash()

2018-02-14 Thread SF Markus Elfring
From: Markus Elfring Date: Wed, 14 Feb 2018 22:05:11 +0100 Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring --- drivers/crypto/bcm/util.c | 1 - 1 file changed, 1 deletion(-) diff -

Re: [PATCH v3 4/8] MIPS: mscc: Add initial support for Microsemi MIPS SoCs

2018-02-14 Thread Philippe Ombredanne
Alexandre, On Wed, Feb 14, 2018 at 5:51 PM, James Hogan wrote: > On Tue, Jan 16, 2018 at 11:12:36AM +0100, Alexandre Belloni wrote: ... >> diff --git a/arch/mips/mscc/Platform b/arch/mips/mscc/Platform >> new file mode 100644 >> index ..9ae874c8f136 >> --- /dev/null >> +++ b/arch/mi

[PATCH 2/2] crypto: bcm: One function call less in do_shash() after error detection

2018-02-14 Thread SF Markus Elfring
From: Markus Elfring Date: Wed, 14 Feb 2018 22:22:20 +0100 The kfree() function was called in one case by the do_shash() function during error handling even if the passed variable contained a null pointer. * Reorder two function calls at the end. * Add a jump target. Signed-off-by: Markus Elfr

Re: [PATCH] audit: session ID should not set arch quick field pointer

2018-02-14 Thread Paul Moore
On Mon, Feb 12, 2018 at 5:04 AM, Richard Guy Briggs wrote: > A bug was introduced in 8fae47705685fcaa75a1fe4c8c3e18300a702979 > ("audit: add support for session ID user filter") > See: https://github.com/linux-audit/audit-kernel/issues/4 > > When setting a session ID filter, the session ID filter

Re: ERROR: "sst_context_init" [sound/soc/intel/atom/sst/snd-intel-sst-acpi.ko] undefined!

2018-02-14 Thread Pierre-Louis Bossart
On 02/14/2018 01:23 PM, kbuild test robot wrote: tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 6556677a80400ca5744340d8ff6fbed22621293e commit: 4772c16ede522d46219a59646503d2020841a6f4 ASoC: Intel: Kconfig: Simplify-clarify ACPI/PCI dependencies date

Re: [PATCH v5 10/12] drm/sun4i: Implement A83T HDMI driver

2018-02-14 Thread Philippe Ombredanne
On Wed, Feb 14, 2018 at 9:09 PM, Jernej Skrabec wrote: > A83T has DW HDMI IP block with a custom PHY similar to Synopsys gen2 > HDMI PHY. > > Only video output was tested, while HW also supports audio and CEC. > Support for them will be added later. > > Signed-off-by: Jernej Skrabec ... > --- /

Re: [PATCH] srcu: Fix incorrect condition in srcu_funnel_exp_start()

2018-02-14 Thread Paul E. McKenney
On Wed, Feb 14, 2018 at 05:59:54PM +0900, Byungchul Park wrote: > We should've kept sp->srcu_gp_seq_needed_exp the furthest. But > it probably fails because of the incorrect condition. Fix it. > > Signed-off-by: Byungchul Park Good catch, and thank you for reviewing the SRCU code, but Ildar Isma

Re: [PATCH] ipmi: kcs_bmc: mark expected switch fall-through in kcs_bmc_handle_data

2018-02-14 Thread Corey Minyard
On 02/14/2018 11:30 AM, Gustavo A. R. Silva wrote: In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Thanks, queued for next release. -corey Addresses-Coverity-ID: 1465255 ("Missing break in switch") Signed-off-by: Gustavo A. R. Silv

Re: Linux & FAT32 label

2018-02-14 Thread Pali Rohár
On Monday 27 November 2017 13:13:01 Karel Zak wrote: > On Sun, Nov 26, 2017 at 08:19:25PM +0100, Pali Rohár wrote: > > On Monday 20 November 2017 12:12:56 Karel Zak wrote: > > > Go ahead and send patch :-) (also with LABEL_FATBOOT=) > > > > Ok, I prepared patches for util-linux including LABEL_FAT

Re: Linux & FAT32 label

2018-02-14 Thread Pali Rohár
On Wednesday 14 February 2018 22:52:33 Pali Rohár wrote: > On Monday 27 November 2017 13:13:01 Karel Zak wrote: > > On Sun, Nov 26, 2017 at 08:19:25PM +0100, Pali Rohár wrote: > > > On Monday 20 November 2017 12:12:56 Karel Zak wrote: > > > > Go ahead and send patch :-) (also with LABEL_FATBOOT=) >

Re: [PATCH] video: fbdev: s3c-fb: remove dead platform code for Exynos and S5PV210 platforms

2018-02-14 Thread Jingoo Han
On Wednesday, February 14, 2018 7:01 AM wrote: > > Exynos5, Exynos4 and S5PV210 platforms have been converted to > use Device Tree and Exynos DRM driver long time ago. Remove > dead platform code for these platforms and update Kconfig > s3c-fb entry accordingly. > > Cc: Jingoo Han Acked-by: Ji

[PATCH] iio: chemical: ccs811: Corrected firmware boot/application mode transition

2018-02-14 Thread Richard Lai
CCS811 has different I2C register maps in boot and application mode. When CCS811 is in boot mode, register APP_START (0xF4) is used to transit the firmware state from boot to application mode. However, APP_START is not a valid register location when CCS811 is in application mode (refer to "CCS811 B

Re: [PATCH] ipmi: kcs_bmc: mark expected switch fall-through in kcs_bmc_handle_data

2018-02-14 Thread Gustavo A. R. Silva
On 02/14/2018 03:46 PM, Corey Minyard wrote: On 02/14/2018 11:30 AM, Gustavo A. R. Silva wrote: In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Thanks, queued for next release. Thanks, Corey. -- Gustavo

[PATCHv4 1/4] dt-bindings: sound: add motorola,cpcap-audio-codec

2018-02-14 Thread Sebastian Reichel
Motorola CPCAP is a PMIC with audio functionality, that can be found on Motorola Droid 4 and probably a few other phones from Motorola's Droid series. This adds the DT binding for the codec sub-module found inside the PMIC. Acked-by: Rob Herring Signed-off-by: Sebastian Reichel --- .../binding

[PATCHv4 3/4] ARM: dts: motorola-cpcap-mapphone: add audio-codec

2018-02-14 Thread Sebastian Reichel
Add node for audio-codec to its DT file. Signed-off-by: Sebastian Reichel --- arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi | 5 + 1 file changed, 5 insertions(+) diff --git a/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi b/arch/arm/boot/dts/motorola-cpcap-mapphone.dtsi index 4d61e5b1334

[PATCHv4 4/4] ARM: dts: omap4-droid4: add soundcard

2018-02-14 Thread Sebastian Reichel
Add sound support to Motorola Droid 4 using simple-soundcard and CPCAP's audio codec. This does not yet correctly represent the whole audio routing, since McBSP3 is also connected to Bluetooth and MDM6600 modem (and probably also 4G modem). These extra DAI links are not yet supported and have not b

[PATCHv4 2/4] ASoC: codec: cpcap: new codec

2018-02-14 Thread Sebastian Reichel
Motorola CPCAP is a PMIC with audio functionality, that can be found on Motorola Droid 4 and probably a few other phones from Motorola's Droid series. The driver has been written from scratch using Motorola's Android driver, register dumps from running Android and datasheet for NXP MC13783UG (whic

[PATCHv4 0/4] Motorola Droid 4 Audio Support

2018-02-14 Thread Sebastian Reichel
Hi, This adds audio support to Motorola Droid 4. I dropped the regulator from the DT binding as requested by Mark. Tested: - Playing via both DACs using Speaker, Earpiece, Headphone - Recording using internal Mic - Volume Controls Known not to work: - 3.5mm detection support (requires closed

Re: [PATCH net v4 02/13] net/8390: Fix msg_enable patch snafu

2018-02-14 Thread Finn Thain
On Tue, 13 Feb 2018, David Miller wrote: > > I think you have overlooked those modules which offer no way to set > > p->msg_enable, i.e. ax88796, axnet_cs, etherh, hydra, mac8390, > > mcf8390, pcnet_cs and zorro8390. > > Then that's a bug, we have a very simple easy to implement interface for

Re: [PATCH] x86/mm/kaiser: avoid 32-bit/PAE build warning

2018-02-14 Thread Arnd Bergmann
On Wed, Dec 6, 2017 at 4:08 PM, Dave Hansen wrote: > On 12/06/2017 07:03 AM, Arnd Bergmann wrote: >> On Wed, Dec 6, 2017 at 3:15 PM, Arnd Bergmann wrote: >> >>> This changes the type to u64 in the architecture-independent dummy, >>> and to pteval_t in the x86 specific portion that is used when KA

[v4.14-rt][report] arm: just another rcu_note_context_switch

2018-02-14 Thread Grygorii Strashko
Hi All, I can see below warning during boot on few TI boards am437x-idk, am335x-evm, am335x-ice All of them are non-SMP [1.229376] NET: Registered protocol family 10 [1.235443] [ cut here ] [1.235489] WARNING: CPU: 0 PID: 18 at kernel/rcu/tree_plugin.h:310 rc

Re: arm64 physmap (was Re: [kernel-hardening] [PATCH 4/6] Protectable Memory)

2018-02-14 Thread Tycho Andersen
On Wed, Feb 14, 2018 at 11:48:38AM -0800, Kees Cook wrote: > On Wed, Feb 14, 2018 at 11:06 AM, Laura Abbott wrote: > > fixed. Modules yes are not fully protected. The conclusion from past > > experience has been that we cannot safely break down larger page sizes > > at runtime like x86 does. We co

Re: [PATCH net v4 02/13] net/8390: Fix msg_enable patch snafu

2018-02-14 Thread David Miller
From: Finn Thain Date: Thu, 15 Feb 2018 09:11:13 +1100 (AEDT) > On Tue, 13 Feb 2018, David Miller wrote: > >> > I think you have overlooked those modules which offer no way to set >> > p->msg_enable, i.e. ax88796, axnet_cs, etherh, hydra, mac8390, >> > mcf8390, pcnet_cs and zorro8390. >> >> T

Re: [PATCH] srcu: Remove dead code in srcu_gp_end()

2018-02-14 Thread Paul E. McKenney
On Wed, Feb 14, 2018 at 10:00:54AM -0500, Steven Rostedt wrote: > On Wed, 14 Feb 2018 18:05:24 +0900 > Byungchul Park wrote: > > > Of course, compilers will optimize out a dead code. Anyway, remove > > any dead code for better readibility. > > > > Signed-off-by: Byungchul Park > > --- > > kern

Re: [PATCH v2] tools/memory-model: Make compat with herd7 7.47 ("-" -> "_")

2018-02-14 Thread Akira Yokosawa
On 2018/02/09 17:07:03 -0800, Paul E. McKenney wrote: > On Sat, Feb 10, 2018 at 08:46:25AM +0900, Akira Yokosawa wrote: >> >From 7c1f497a9a51e8db1a94c8a7ef0b74b235aaab88 Mon Sep 17 00:00:00 2001 >> From: Akira Yokosawa >> Date: Fri, 9 Feb 2018 04:51:05 -0800 >> Subject: [PATCH v2] tools/memory-mod

Re: objtool warnings on 4.14-stable/gcc-7.3.0

2018-02-14 Thread Josh Poimboeuf
On Wed, Feb 14, 2018 at 04:11:15PM +0100, Arnd Bergmann wrote: > Hi Josh, > > I recently did some randconfig testing with a plain 4.14-stable kernel > and gcc-7.3.0, and came across three distinct objtool warnings: > > drivers/misc/lkdtm_bugs.o: warning: objtool: > lkdtm_CORRUPT_LIST_ADD()+0x15:

Re: [PATCH] x86/entry/64: Fix CR3 restore order in paranoid_exit()

2018-02-14 Thread Ingo Molnar
* Josh Poimboeuf wrote: > Dave was right, my patch was obviously bogus. I couldn't figure out a > real reproducer, so I made an artificial one (see below) and can confirm > that your patch fixes it. > > I would resubmit the patch, but now you're the author, so I'm not sure > how that works wit

Re: arm64 physmap (was Re: [kernel-hardening] [PATCH 4/6] Protectable Memory)

2018-02-14 Thread Kees Cook
On Wed, Feb 14, 2018 at 2:13 PM, Tycho Andersen wrote: > On Wed, Feb 14, 2018 at 11:48:38AM -0800, Kees Cook wrote: >> On Wed, Feb 14, 2018 at 11:06 AM, Laura Abbott wrote: >> > fixed. Modules yes are not fully protected. The conclusion from past >> > experience has been that we cannot safely bre

[PATCH] scsi: scsi_transport_spi make two const arrays static, shrinks object size

2018-02-14 Thread Colin King
From: Colin Ian King Don't populate the const read-only arrays spi_test_unit_ready and spi_test_unit_ready on the stack but instead make them static. Makes the object code smaller by over 100 bytes: Before: textdata bss dec hex filename 40171 12832 128 53131cf8b

Re: objtool warnings on 4.14-stable/gcc-7.3.0

2018-02-14 Thread Josh Poimboeuf
On Wed, Feb 14, 2018 at 04:24:12PM -0600, Josh Poimboeuf wrote: > On Wed, Feb 14, 2018 at 04:11:15PM +0100, Arnd Bergmann wrote: > > Hi Josh, > > > > I recently did some randconfig testing with a plain 4.14-stable kernel > > and gcc-7.3.0, and came across three distinct objtool warnings: > > > >

collecting simple benchmark scripts?

2018-02-14 Thread Kees Cook
Hi, In a separate thread, some folks were looking for some simple benchmarks for evaluating various changes to kernel internals (as opposed to the much more focused things like xfstests). For me, this has been an area of lore and passed-around scripts, and it seems like maybe we should have a subd

Re: [PATCH v2] tools/memory-model: Make compat with herd7 7.47 ("-" -> "_")

2018-02-14 Thread Paul E. McKenney
On Thu, Feb 15, 2018 at 07:20:35AM +0900, Akira Yokosawa wrote: > On 2018/02/09 17:07:03 -0800, Paul E. McKenney wrote: > > On Sat, Feb 10, 2018 at 08:46:25AM +0900, Akira Yokosawa wrote: > >> >From 7c1f497a9a51e8db1a94c8a7ef0b74b235aaab88 Mon Sep 17 00:00:00 2001 > >> From: Akira Yokosawa > >> Da

[TEST for] fs: global sync to not clear error status of individual inodes

2018-02-14 Thread Luis R. Rodriguez
Junichi, curious if you ever got to adapt a test case for xfstests for your patch "fs: global sync to not clear error status of individual inodes", which got merged as of v4.4 as: aa750fd71c242dba02ee2034e15fbd7d0cdb2461 mm/filemap.c: make global sync not clear error status of individual inodes

Re: [PATCH] staging: media: reformat line to 80 chars or less

2018-02-14 Thread Steve Longerbeam
Hi Parthiban, please rename the commit title to "media: imx: capture: reformat line to 80 chars or less" Otherwise it is fine with me. Steve On 02/12/2018 04:05 AM, Parthiban Nallathambi wrote: This is a cleanup patch to fix line length issue found by checkpatch.pl script. In this patch, li

Re: DM Regression in 4.16-rc1 - read() returns data when it shouldn't

2018-02-14 Thread Mike Snitzer
On Wed, Feb 14 2018 at 3:39pm -0500, NeilBrown wrote: > On Wed, Feb 14 2018, Milan Broz wrote: > > > Hi, > > > > the commit (found by bisect) > > > > commit 18a25da84354c6bb655320de6072c00eda6eb602 > > Author: NeilBrown > > Date: Wed Sep 6 09:43:28 2017 +1000 > > > > dm: ensure bio

Re: clang asm-goto support (Was Re: [PATCH v2] x86/retpoline: Add clang support)

2018-02-14 Thread Ingo Molnar
* Ingo Molnar wrote: > To quantify it: I just performed a test build of a Linux distro kernel config > (Fedora x86-64), and counted the number of callsites that use 'asm goto' > functionality with the v4.15 kernel (including drivers). > > The results: > >

Re: collecting simple benchmark scripts?

2018-02-14 Thread Tycho Andersen
On Wed, Feb 14, 2018 at 02:50:37PM -0800, Kees Cook wrote: > I'm sure I'm not remotely the first person to bring this up, but my > attempts at searches for this have failed. > > Thoughts? There is mmtests: https://github.com/gormanm/mmtests which looks like it has kernel build and a bunch of othe

Re: [PATCH] watchdog: hpwdt: Remove spinlock acquire and BIOS calls from NMI context

2018-02-14 Thread Ingo Molnar
* Jerry Hoemann wrote: > > Ingo, > > I have a patch set under review that brings hpwdt into compliance > with the watchdog core. > > One of the changes removes the callback into firmware in hpwdt_pretimeout > and its associated spinlock. > > https://lkml.org/lkml/2018/2/12/30 drivers/watch

Re: [PATCH 1/3] auxdisplay: charlcd: fix hex literal ranges for graphics command

2018-02-14 Thread Robert Abel
On 13 Feb 2018 14:36, Andy Shevchenko wrote: > I understand that we have a huge and hopefully nice library in the > kernel, but the question still the same, what prevents a developer or > maintainer to look at it from time to time? > > For, I dare to say, ages we have hex_to_bin() and hex2bin(). >

Re: [tip:x86/pti] x86/speculation: Use IBRS if available before calling into firmware

2018-02-14 Thread Ingo Molnar
* Tim Chen wrote: > On 02/14/2018 12:56 AM, Peter Zijlstra wrote: > > > > > At the very least this must disable and re-enable preemption, such that > > we guarantee we inc/dec the same counter. ISTR some firmware calls (EFI) > > actually are preemptible so that wouldn't work. > > > > Further,

Re: [TEST for] fs: global sync to not clear error status of individual inodes

2018-02-14 Thread Junichi Nomura
Hi Luis, On 02/15/18 07:59, Luis R. Rodriguez wrote: > curious if you ever got to adapt a test case for xfstests for your patch > "fs: global sync to not clear error status of individual inodes", which > got merged as of v4.4 as: > > aa750fd71c242dba02ee2034e15fbd7d0cdb2461 mm/filemap.c: make glo

Re: samples/seccomp/ broken when cross compiling s390, ppc allyesconfig

2018-02-14 Thread Michael Ellerman
Kees Cook writes: > On Wed, Feb 14, 2018 at 1:20 AM, Michal Hocko wrote: ... >> >> OK, so let's try to nuke it. How should I route this patch? > > I'm fine if goes in via ppc (especially if it can land for 4.16). If > Michael doesn't want it, I can send it through my seccomp tree via > James Morr

[PATCH v2 0/4] Speculation control improvements

2018-02-14 Thread David Woodhouse
On CPUs which advertise IBRS_ALL, enable it and disable the retpoline as IBRS_ALL will be faster. Also use IBRS whenever it's available before calling into firmware at runtime. Revert another bikeshedding patch that was broken, and add support for retpoline builds with clang. --- v2: Remember to

[PATCH v2 2/4] x86/speculation: Support "Enhanced IBRS" on future CPUs

2018-02-14 Thread David Woodhouse
The original IBRS hack in microcode is horribly slow. For the next generation of CPUs, as a stopgap until we get a proper fix, Intel promise an "Enhanced IBRS" which will be fast. The assumption is that predictions in the BTB/RSB will be tagged with the VMX mode and ring that they were learned in,

[PATCH v2 4/4] x86/retpoline: Support retpoline build with Clang

2018-02-14 Thread David Woodhouse
Signed-off-by: David Woodhouse --- arch/x86/Makefile | 5 - include/linux/compiler-clang.h | 5 + include/linux/compiler-gcc.h | 4 include/linux/init.h | 8 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/arch/x86/Makefile b/arch/x86

Re: [PATCH 1/3] HID: add driver for Valve Steam Controller

2018-02-14 Thread Rodrigo Rivas Costa
On Wed, Feb 14, 2018 at 03:45:14PM +0100, Benjamin Tissoires wrote: > I think I had a look at this a while ago, and didn't want to interfere > with SteamOS regarding this. I think your patch should be fine in that > regard, but have you tried SteamOS on a kernel patched with your > series? Does it

[PATCH v2 1/4] x86/speculation: Use IBRS if available before calling into firmware

2018-02-14 Thread David Woodhouse
Retpoline means the kernel is safe because it has no indirect branches. But firmware isn't, so use IBRS for firmware calls if it's available. Block preemption while IBRS is set, although in practice the call sites already had to be doing that. Ignore hpwdt.c for now. It's taking spinlocks and cal

[PATCH v2 3/4] Revert "x86/retpoline: Simplify vmexit_fill_RSB()"

2018-02-14 Thread David Woodhouse
This reverts commit 1dde7415e99933bb7293d6b2843752cbdb43ec11. By putting the RSB filling out of line and calling it, we waste one RSB slot for returning from the function itself, which means one fewer actual function call we can make if we're doing the Skylake abomination of call-depth counting. I

[tip:x86/pti] x86/entry/64: Fix CR3 restore in paranoid_exit()

2018-02-14 Thread tip-bot for Ingo Molnar
Commit-ID: 48753793350974b7afe9598fd1dc46b2f1f47c2d Gitweb: https://git.kernel.org/tip/48753793350974b7afe9598fd1dc46b2f1f47c2d Author: Ingo Molnar AuthorDate: Wed, 14 Feb 2018 08:39:11 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 00:28:03 +0100 x86/entry/64: Fix CR3 resto

[PATCH] NFC: llcp: Limit size of SDP URI

2018-02-14 Thread Kees Cook
The tlv_len is u8, so we need to limit the size of the SDP URI. Enforce this both in the NLA policy and in the code that performs the allocation and copy, to avoid writing past the end of the allocated buffer. Fixes: d9b8d8e19b073 ("NFC: llcp: Service Name Lookup netlink interface") Signed-off-by:

Re: [PATCH] platform/x86: intel_turbo_max_3: Remove restriction for HWP platforms

2018-02-14 Thread Srinivas Pandruvada
On Wed, 2018-02-14 at 21:29 +0200, Andy Shevchenko wrote: > On Mon, Feb 12, 2018 at 9:50 PM, Srinivas Pandruvada > wrote: > > On systems supporting HWP (Hardware P-States) mode, we expected to > > enumerate core priority via ACPI-CPPC tables. Unfortunately > > deployment of > > TURBO 3.0 didn't us

[PATCH] ASoC: dmic: Add optional wakeup delay

2018-02-14 Thread Matthias Kaehlcke
On some systems a delay is needed after switching on the clocks, to allow the DMIC output to stabilize and avoid a popping noise at the beginning of the recording. Add the optional device tree property 'wakeup-delay-ms' and apply the specified delay in the new dmic_daiops_prepare(). Signed-off-by:

Re: [PATCH v2] IB/cxgb3: remove cxio_dbg.c

2018-02-14 Thread Jason Gunthorpe
On Tue, Feb 06, 2018 at 08:37:31PM +, Corentin Labbe wrote: > cxio_dbg.c is uncompiled since commit 2b540355cd2f ("RDMA/cxgb3: cleanups") > 10 years after, we could remove it. > > Signed-off-by: Corentin Labbe > Acked-by: Steve Wise > > Changes since v1: > - Remove also all DEBUG code as su

Re: [PATCH v2 2/8] mm: Add kvmalloc_ab_c and kvzalloc_struct

2018-02-14 Thread Andrew Morton
On Wed, 14 Feb 2018 13:12:03 -0800 Matthew Wilcox wrote: > On Wed, Feb 14, 2018 at 12:45:52PM -0800, Joe Perches wrote: > > On Wed, 2018-02-14 at 12:11 -0800, Matthew Wilcox wrote: > > > We have kvmalloc_array in order to safely allocate an array with a > > > number of elements specified by users

Re: [dm-devel] DM Regression in 4.16-rc1 - read() returns data when it shouldn't

2018-02-14 Thread NeilBrown
On Wed, Feb 14 2018, Mike Snitzer wrote: > On Wed, Feb 14 2018 at 3:39pm -0500, > NeilBrown wrote: > >> On Wed, Feb 14 2018, Milan Broz wrote: >> >> > Hi, >> > >> > the commit (found by bisect) >> > >> > commit 18a25da84354c6bb655320de6072c00eda6eb602 >> > Author: NeilBrown >> > Date:

Re: [PATCH v5 00/20][RESEND] firmware: ARM System Control and Management Interface(SCMI) support

2018-02-14 Thread Alexey Klimov
On Mon, Feb 12, 2018 at 6:45 PM, Sudeep Holla wrote: > Hi all, > > ARM System Control and Management Interface(SCMI) is more flexible and > easily extensible than any of the existing interfaces. Many vendors were > involved in the making of this formal specification and is now published[1]. > > Th

Re: [RFC PATCH 2/4] x86/entry/64: move ENTER_IRQ_STACK from interrupt macro to helper function

2018-02-14 Thread Andy Lutomirski
On Wed, Feb 14, 2018 at 6:21 PM, Dominik Brodowski wrote: > Moving the switch to IRQ stack from the interrupt macro to the helper > function requires some trickery: All ENTER_IRQ_STACK really cares about > is where the "original" stack -- meaning the GP registers etc. -- is > stored. Therefore, we

Re: [PATCH] ASoC: dmic: Add optional wakeup delay

2018-02-14 Thread Brian Norris
Hi Matthias, On Wed, Feb 14, 2018 at 03:51:56PM -0800, Matthias Kaehlcke wrote: > On some systems a delay is needed after switching on the clocks, to allow > the DMIC output to stabilize and avoid a popping noise at the beginning > of the recording. Add the optional device tree property 'wakeup-de

[tip:x86/pti] selftests/x86: Disable tests requiring 32-bit support on pure 64-bit systems

2018-02-14 Thread tip-bot for Dominik Brodowski
Commit-ID: 9279ddf23ce78ff2676e8e8e19fec0f022c26d04 Gitweb: https://git.kernel.org/tip/9279ddf23ce78ff2676e8e8e19fec0f022c26d04 Author: Dominik Brodowski AuthorDate: Tue, 13 Feb 2018 09:15:19 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:48 +0100 selftests/x86: Disabl

[tip:x86/pti] selftests/x86: Do not rely on "int $0x80" in single_step_syscall.c

2018-02-14 Thread tip-bot for Dominik Brodowski
Commit-ID: 4105c69703cdeba76f384b901712c9397b04e9c2 Gitweb: https://git.kernel.org/tip/4105c69703cdeba76f384b901712c9397b04e9c2 Author: Dominik Brodowski AuthorDate: Tue, 13 Feb 2018 09:13:21 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:48 +0100 selftests/x86: Do not

[tip:x86/pti] x86/speculation: Fix up array_index_nospec_mask() asm constraint

2018-02-14 Thread tip-bot for Dan Williams
Commit-ID: be3233fbfcb8f5acb6e3bcd0895c3ef9e100d470 Gitweb: https://git.kernel.org/tip/be3233fbfcb8f5acb6e3bcd0895c3ef9e100d470 Author: Dan Williams AuthorDate: Tue, 6 Feb 2018 18:22:40 -0800 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:50 +0100 x86/speculation: Fix up arr

[tip:x86/pti] nospec: Move array_index_nospec() parameter checking into separate macro

2018-02-14 Thread tip-bot for Will Deacon
Commit-ID: 8fa80c503b484ddc1abbd10c7cb2ab81f3824a50 Gitweb: https://git.kernel.org/tip/8fa80c503b484ddc1abbd10c7cb2ab81f3824a50 Author: Will Deacon AuthorDate: Mon, 5 Feb 2018 14:16:06 + Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:51 +0100 nospec: Move array_index_nos

[tip:x86/pti] selftests/x86/mpx: Fix incorrect bounds with old _sigfault

2018-02-14 Thread tip-bot for Rui Wang
Commit-ID: 961888b1d76d84efc66a8f5604b06ac12ac2f978 Gitweb: https://git.kernel.org/tip/961888b1d76d84efc66a8f5604b06ac12ac2f978 Author: Rui Wang AuthorDate: Mon, 18 Dec 2017 16:34:10 +0800 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:52 +0100 selftests/x86/mpx: Fix incorre

[tip:x86/pti] x86/cpu: Rename cpu_data.x86_mask to cpu_data.x86_stepping

2018-02-14 Thread tip-bot for Jia Zhang
Commit-ID: b399151cb48db30ad1e0e93dd40d68c6d007b637 Gitweb: https://git.kernel.org/tip/b399151cb48db30ad1e0e93dd40d68c6d007b637 Author: Jia Zhang AuthorDate: Mon, 1 Jan 2018 09:52:10 +0800 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:52 +0100 x86/cpu: Rename cpu_data.x86_m

[tip:x86/pti] x86/cpu: Change type of x86_cache_size variable to unsigned int

2018-02-14 Thread tip-bot for Gustavo A. R. Silva
Commit-ID: 24dbc6000f4b9b0ef5a9daecb161f1907733765a Gitweb: https://git.kernel.org/tip/24dbc6000f4b9b0ef5a9daecb161f1907733765a Author: Gustavo A. R. Silva AuthorDate: Tue, 13 Feb 2018 13:22:08 -0600 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:53 +0100 x86/cpu: Change typ

linux-next: build failure after merge of the sound-asoc tree

2018-02-14 Thread Stephen Rothwell
~~ Caused by commit a8768c52c511 ("ASoC: soc-core: remove legacy_dai_naming from snd_soc_register_dais()") I have used the sound-asoc tree from next-20180214 for today. -- Cheers, Stephen Rothwell

[tip:x86/pti] x86/spectre: Fix an error message

2018-02-14 Thread tip-bot for Dan Carpenter
Commit-ID: 9de29eac8d2189424d81c0d840cd0469aa3d41c8 Gitweb: https://git.kernel.org/tip/9de29eac8d2189424d81c0d840cd0469aa3d41c8 Author: Dan Carpenter AuthorDate: Wed, 14 Feb 2018 10:14:17 +0300 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:53 +0100 x86/spectre: Fix an error

[tip:x86/pti] objtool: Fix segfault in ignore_unreachable_insn()

2018-02-14 Thread tip-bot for Josh Poimboeuf
Commit-ID: fe24e27128252c230a34a6c628da2bf1676781ea Gitweb: https://git.kernel.org/tip/fe24e27128252c230a34a6c628da2bf1676781ea Author: Josh Poimboeuf AuthorDate: Thu, 8 Feb 2018 17:09:25 -0600 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:49 +0100 objtool: Fix segfault in

[tip:x86/pti] x86/mm: Rename flush_tlb_single() and flush_tlb_one() to __flush_tlb_one_[user|kernel]()

2018-02-14 Thread tip-bot for Andy Lutomirski
Commit-ID: 1299ef1d8870d2d9f09a5aadf2f8b2c887c2d033 Gitweb: https://git.kernel.org/tip/1299ef1d8870d2d9f09a5aadf2f8b2c887c2d033 Author: Andy Lutomirski AuthorDate: Wed, 31 Jan 2018 08:03:10 -0800 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:52 +0100 x86/mm: Rename flush_tl

[tip:x86/pti] x86/debug: Use UD2 for WARN()

2018-02-14 Thread tip-bot for Peter Zijlstra
Commit-ID: 3b3a371cc9bc980429baabe0a8e5f307f3d1f463 Gitweb: https://git.kernel.org/tip/3b3a371cc9bc980429baabe0a8e5f307f3d1f463 Author: Peter Zijlstra AuthorDate: Fri, 9 Feb 2018 13:16:59 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:50 +0100 x86/debug: Use UD2 for WA

Re: [PATCH RESENT] nvme-pci: suspend queues based on online_queues

2018-02-14 Thread jianchao.wang
Hi Keith Thanks for your kindly response and directive. And 恭喜发财 大吉大利!! On 02/14/2018 05:52 AM, Keith Busch wrote: > On Mon, Feb 12, 2018 at 09:05:13PM +0800, Jianchao Wang wrote: >> @@ -1315,9 +1315,6 @@ static int nvme_suspend_queue(struct nvme_queue *nvmeq) >> nvmeq->cq_vector = -1; >>

[GIT PULL] x86 PTI and Spectre related fixes and updates

2018-02-14 Thread Ingo Molnar
Linus, Please consider pulling the latest x86-pti-for-linus git tree from: git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git x86-pti-for-linus # HEAD: 48753793350974b7afe9598fd1dc46b2f1f47c2d x86/entry/64: Fix CR3 restore in paranoid_exit() Here's the latest set of Spectre and PT

[tip:x86/pti] x86/speculation: Add dependency

2018-02-14 Thread tip-bot for Peter Zijlstra
Commit-ID: ea00f301285ea2f07393678cd2b6057878320c9d Gitweb: https://git.kernel.org/tip/ea00f301285ea2f07393678cd2b6057878320c9d Author: Peter Zijlstra AuthorDate: Tue, 13 Feb 2018 14:28:19 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:51 +0100 x86/speculation: Add de

[tip:x86/pti] x86/debug, objtool: Annotate WARN()-related UD2 as reachable

2018-02-14 Thread tip-bot for Josh Poimboeuf
Commit-ID: 2b5db66862b95532cb6cca8165ae6eb73633cf85 Gitweb: https://git.kernel.org/tip/2b5db66862b95532cb6cca8165ae6eb73633cf85 Author: Josh Poimboeuf AuthorDate: Thu, 8 Feb 2018 17:09:26 -0600 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:49 +0100 x86/debug, objtool: Annot

[tip:x86/pti] x86/entry/64: Fix CR3 restore in paranoid_exit()

2018-02-14 Thread tip-bot for Ingo Molnar
Commit-ID: e48657573481a5dff7cfdc3d57005c80aa816500 Gitweb: https://git.kernel.org/tip/e48657573481a5dff7cfdc3d57005c80aa816500 Author: Ingo Molnar AuthorDate: Wed, 14 Feb 2018 08:39:11 +0100 Committer: Ingo Molnar CommitDate: Thu, 15 Feb 2018 01:15:54 +0100 x86/entry/64: Fix CR3 resto

[PATCH] of: add early boot allocation of of_find_node_by_phandle() cache

2018-02-14 Thread frowand . list
From: Frank Rowand The initial implementation of the of_find_node_by_phandle() cache allocates the cache using kcalloc(). Add an early boot allocation of the cache so it will be usable during early boot. Switch over to the kcalloc() based cache once normal memory allocation becomes available.

[GIT PULL] x86 fixes

2018-02-14 Thread Ingo Molnar
Linus, Please pull the latest x86-urgent-for-linus git tree from: git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git x86-urgent-for-linus # HEAD: fd0e786d9d09024f67bd71ec094b110237dc3840 x86/mm, mm/hwpoison: Don't unconditionally unmap kernel 1:1 pages Misc fixes all across the m

Re: [PATCH v2 1/4] x86/speculation: Use IBRS if available before calling into firmware

2018-02-14 Thread Jim Mattson
On Wed, Feb 14, 2018 at 3:29 PM, David Woodhouse wrote: > +#define alternative_msr_write(_msr, _val, _feature)\ > + asm volatile(ALTERNATIVE("",\ > +"movl %[msr], %%ecx\n\t" \ > +"m

[PATCH 1/6] sched: Rename init_rq_hrtick to hrtick_rq_init

2018-02-14 Thread Frederic Weisbecker
Do that rename in order to normalize the hrtick namespace. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Rik van Riel Cc: Thomas Gleixner Cc: Wanpeng Li Cc: Ingo Molnar --- k

[PATCH 2/6] nohz: Allow to check if remote CPU tick is stopped

2018-02-14 Thread Frederic Weisbecker
This check is racy but provides a good heuristic to determine whether a CPU may need a remote tick or not. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Rik van Riel Cc: Thomas G

[PATCH 0/6] isolation: 1Hz residual tick offloading v6

2018-02-14 Thread Frederic Weisbecker
The version addresses the reviews from Ingo on v5: * Start changelog titles with verbs. * Improve/reword several comments. * Improve/reword documentation. * Various cosmetic changes. * Use BUG_ON() on boot allocation failure. git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.g

Re: [RFC PATCH 2/4] x86/entry/64: move ENTER_IRQ_STACK from interrupt macro to helper function

2018-02-14 Thread Brian Gerst
On Wed, Feb 14, 2018 at 7:17 PM, Andy Lutomirski wrote: > On Wed, Feb 14, 2018 at 6:21 PM, Dominik Brodowski > wrote: >> Moving the switch to IRQ stack from the interrupt macro to the helper >> function requires some trickery: All ENTER_IRQ_STACK really cares about >> is where the "original" stac

<    4   5   6   7   8   9   10   >