[-mm PATCH] docs/vm: Update ZONE_DEVICE memory model documentation

2019-06-20 Thread Dan Williams
Mike notes that Sphinx needs a newline before the start of a bulleted list, and v10 of the subsection patch set changed the subsection size from an arch-variable 'PMD_SIZE' to a constant 2MB. Cc: Jonathan Corbet Reported-by: Mike Rapoport Signed-off-by: Dan Williams --- Hi Andrew, Another

linux-next: manual merge of the kvms390 tree with Linus' tree

2019-06-20 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the kvms390 tree got a conflict in: tools/testing/selftests/kvm/Makefile between commit: 61cfcd545e42 ("kvm: tests: Sort tests in the Makefile alphabetically") from Linus' tree and commits: ee1563f42856 ("KVM: selftests: Add the sync_regs test for

Re: [PATCH 3/6] usb: bdc: driver may fail to get USB PHY

2019-06-20 Thread Chunfeng Yun
On Thu, 2019-06-20 at 17:09 -0400, Al Cooper wrote: > Initialization order is important for the USB PHY and the PHY clients. > The init order is based on the build order of the drivers in the > makefiles and the PHY drivers are built early to help with > dependencies, but the new SCMI based clock

[PATCH] powerpc/powernv: Rename pe_level_printk to pe_printk and embed KERN_LEVEL in format

2019-06-20 Thread Joe Perches
Remove the separate KERN_ from each pe_level_printk and instead add the KERN_ to the format. pfix in pe_level_printk could also be used uninitialized so add a new else and set pfx to the hex value of pe->flags. Rename pe_level_printk to pe_printk and update the pe_ macros. Signed-off-by: Joe

Re: Kirkwood PCI Express and bridges

2019-06-20 Thread Thomas Petazzoni
Hello Chris, On Fri, 21 Jun 2019 04:03:27 + Chris Packham wrote: > I'm in the process of updating the kernel version used on our products > from 4.4 -> 5.1. > > We have one product that uses a Kirkwood CPU, IDT PCI bridge and Marvell > Switch ASIC. The Switch ASIC presents as multiple

Re: [PATCH V4 1/2] PCI: dwc: Add API support to de-initialize host

2019-06-20 Thread Vidya Sagar
On 6/20/2019 10:22 PM, Lorenzo Pieralisi wrote: On Wed, Jun 19, 2019 at 10:41:26AM +0530, Kishon Vijay Abraham I wrote: Hi Lorenzo, On 18/06/19 7:58 PM, Lorenzo Pieralisi wrote: On Tue, Jun 18, 2019 at 04:21:17PM +0530, Vidya Sagar wrote: [...] 2) It is not related to this patch but I fail

Re: [PATCH 2/6] usb: bdc: Cleanup clock support

2019-06-20 Thread Chunfeng Yun
On Thu, 2019-06-20 at 17:09 -0400, Al Cooper wrote: > - Fix driver to defer on clk_get defer > > Signed-off-by: Al Cooper > --- > drivers/usb/gadget/udc/bdc/bdc_core.c | 15 +-- > 1 file changed, 9 insertions(+), 6 deletions(-) > > diff --git a/drivers/usb/gadget/udc/bdc/bdc_core.c

Re: [PATCH V33 01/30] security: Support early LSMs

2019-06-20 Thread Andy Lutomirski
On Thu, Jun 20, 2019 at 6:22 PM Matthew Garrett wrote: > > The lockdown module is intended to allow for kernels to be locked down > early in boot - sufficiently early that we don't have the ability to > kmalloc() yet. Add support for early initialisation of some LSMs, and > then add them to the

Re: [PATCH V33 24/30] bpf: Restrict bpf when kernel lockdown is in confidentiality mode

2019-06-20 Thread Andy Lutomirski
On Thu, Jun 20, 2019 at 6:21 PM Matthew Garrett wrote: > > From: David Howells > > There are some bpf functions can be used to read kernel memory: > bpf_probe_read, bpf_probe_write_user and bpf_trace_printk. These allow > private keys in kernel memory (e.g. the hibernation image signing key) to

Re: selftests: bpf: test_libbpf.sh failed at file test_l4lb.o

2019-06-20 Thread Andrii Nakryiko
On Thu, Jun 20, 2019 at 1:08 AM Naresh Kamboju wrote: > > selftests: bpf test_libbpf.sh failed running Linux -next kernel > 20190618 and 20190619. > > Here is the log from x86_64, > # selftests bpf test_libbpf.sh > bpf: test_libbpf.sh_ # > # [0] libbpf BTF is required, but is missing or

Re: [PATCH][next] libbpf: fix spelling mistake "conflictling" -> "conflicting"

2019-06-20 Thread Andrii Nakryiko
On Wed, Jun 19, 2019 at 9:28 AM Colin King wrote: > > From: Colin Ian King > > There are several spelling mistakes in pr_warning messages. Fix these. > > Signed-off-by: Colin Ian King > --- Oh, the beauty of copy/pasting same typo 4 times :) Thanks for fixing! Can you please re-submit with

[PATCH] arm64: defconfig: Enable CONFIG_KEYBOARD_SNVS_PWRKEY as module

2019-06-20 Thread Anson . Huang
From: Anson Huang Enable CONFIG_KEYBOARD_SNVS_PWRKEY as module to support i.MX8M series SoCs' power key. Signed-off-by: Anson Huang --- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index

Re: [PATCH 1/2] pinctrl: mediatek: Ignore interrupts that are wake only during resume

2019-06-20 Thread Sean Wang
Hi Nicolas, On Sun, Apr 28, 2019 at 8:55 PM Nicolas Boichat wrote: > > Before suspending, mtk-eint would set the interrupt mask to the > one in wake_mask. However, some of these interrupts may not have a > corresponding interrupt handler, or the interrupt may be disabled. > > On resume, the eint

Re: [PATCH 1/5] usb: xhci: add firmware loader for uPD720201 and uPD720202 w/o ROM

2019-06-20 Thread Vinod Koul
On 20-06-19, 21:12, Christian Lamparter wrote: > On Thursday, June 20, 2019 7:03:58 PM CEST Vinod Koul wrote: > > On 20-06-19, 14:19, Greg Kroah-Hartman wrote: > > > On Thu, Jun 20, 2019 at 03:51:50PM +0530, Vinod Koul wrote: > > > > From: Christian Lamparter > > > > > > > > This patch adds a

Re: [PATCH v7 1/5] Input: elan_i2c: Export the device id whitelist

2019-06-20 Thread Dmitry Torokhov
Hi Jeffrey, On Thu, Jun 20, 2019 at 7:33 AM Jeffrey Hugo wrote: > #ifdef CONFIG_OF > -static const struct of_device_id elan_of_match[] = { > - { .compatible = "elan,ekth3000" }, > - { /* sentinel */ } > -}; I think OF IDs should stay in this file since we agreed HID will not be

[PATCH v2 1/1] staging: media: fix style problem

2019-06-20 Thread Aliasgar Surti
From: Aliasgar Surti checkpatch reported "WARNING: line over 80 characters". This patch fixes the warning for file davinci_vpfe/dm365_isif.c Signed-off-by: Aliasgar Surti --- Changes in v2: - Fixed styling as per suggestion in comments drivers/staging/media/davinci_vpfe/dm365_isif.c

Hi Dear,

2019-06-20 Thread Mrs felicia william
Hello, Compliment of the day to you. I am Mrs felicia william; I am sending this brief letter to solicit your partnership to transfer $19.5 million US Dollars. I shall send you more information and procedures when I receive positive response from you. please send me a message in my Email box and

Re: [PATCH 2/2] pinctrl: mediatek: Update cur_mask in mask/mask ops

2019-06-20 Thread Sean Wang
Hi, Nicolas On Sun, Apr 28, 2019 at 8:55 PM Nicolas Boichat wrote: > > During suspend/resume, mtk_eint_mask may be called while > wake_mask is active. For example, this happens if a wake-source > with an active interrupt handler wakes the system: > irq/pm.c:irq_pm_check_wakeup would disable the

Benötigen Sie einen dringenden Kredit?

2019-06-20 Thread Ocean Finance
-- Schönen Tag. Benötigen Sie einen dringenden Kredit? Wir bieten Unternehmen Darlehensdienstleistungen für Geschäftserweiterungen, Investitionen und Projekte an. Darüber hinaus bieten wir Privatkredite mit einem Zinssatz von 1,3% an. Wenn Sie sich jetzt bewerben, können Sie Ihre

Re: [PATCH V33 27/30] lockdown: Print current->comm in restriction messages

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:19:38PM -0700, Matthew Garrett wrote: > Print the content of current->comm in messages generated by lockdown to > indicate a restriction that was hit. This makes it a bit easier to find > out what caused the message. > > The message now patterned something like: > >

Kirkwood PCI Express and bridges

2019-06-20 Thread Chris Packham
Hi All, I'm in the process of updating the kernel version used on our products from 4.4 -> 5.1. We have one product that uses a Kirkwood CPU, IDT PCI bridge and Marvell Switch ASIC. The Switch ASIC presents as multiple PCI devices. The hardware setup looks like this

Re: [PATCH 4.4 00/84] 4.4.183-stable review

2019-06-20 Thread Naresh Kamboju
- kernel: 4.4.183-rc1 git repo: https://git.linaro.org/lkft/arm64-stable-rc.git git branch: 4.4.183-rc1-hikey-20190620-466 git commit: 3e8bd9046c869be462eabbeff74037861c7b2c22 git describe: 4.4.183-rc1-hikey-20190620-466 Test details: https://qa-reports.linaro.org/lkft

linux-next: build failure after merge of the block tree

2019-06-20 Thread Stephen Rothwell
") I have used the block tree from next-20190620 for today. -- Cheers, Stephen Rothwell pgp1Pqmsac90w.pgp Description: OpenPGP digital signature

Re: [PATCH 5.1 00/98] 5.1.13-stable review

2019-06-20 Thread Naresh Kamboju
On Thu, 20 Jun 2019 at 23:44, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 5.1.13 release. > There are 98 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > >

Re: [PATCH 4.19 00/61] 4.19.54-stable review

2019-06-20 Thread Naresh Kamboju
On Thu, 20 Jun 2019 at 23:40, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 4.19.54 release. > There are 61 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > >

Re: [PATCH] net: fddi: skfp: remove generic PCI defines from skfbi.h

2019-06-20 Thread kbuild test robot
Hi Puranjay, Thank you for the patch! Yet something to improve: [auto build test ERROR on net/master] [also build test ERROR on v5.2-rc5 next-20190620] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux

[PATCH] dt-binding: mmc: rename tmio_mmc.txt to renesas_sdhi.txt

2019-06-20 Thread Masahiro Yamada
As commit b6147490e6aa ("mmc: tmio: split core functionality, DMA and MFD glue") said, these MMC controllers use the IP from Panasonic. TMIO (Toshiba Mobile IO) MMC was the first upstreamed user of this IP. The common driver code was split and expanded as 'tmio-mmc-core', then it become

Re: [PATCH 4.14 00/45] 4.14.129-stable review

2019-06-20 Thread Naresh Kamboju
On Thu, 20 Jun 2019 at 23:39, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 4.14.129 release. > There are 45 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > >

Re: [PATCH V33 04/30] Enforce module signatures if the kernel is locked down

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:19:15PM -0700, Matthew Garrett wrote: > From: David Howells > > If the kernel is locked down, require that all modules have valid > signatures that we can verify. > > I have adjusted the errors generated: > > (1) If there's no signature (ENODATA) or we can't check

Re: [PATCH V33 03/30] security: Add a static lockdown policy LSM

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:19:14PM -0700, Matthew Garrett wrote: > While existing LSMs can be extended to handle lockdown policy, > distributions generally want to be able to apply a straightforward > static policy. This patch adds a simple LSM that can be configured to > reject either integrity

Re: [PATCH] net: fddi: skfp: remove generic PCI defines from skfbi.h

2019-06-20 Thread Puranjay Mohan
On Fri, Jun 21, 2019 at 10:35:04AM +0800, kbuild test robot wrote: > Hi Puranjay, > > Thank you for the patch! Yet something to improve: > > [auto build test ERROR on net/master] > [also build test ERROR on v5.2-rc5 next-20190620] > [if your patch is applied to the wrong git

[PATCH] staging: ks7010: Fix build error

2019-06-20 Thread YueHaibing
when CRYPTO is m and KS7010 is y, building fails: drivers/staging/ks7010/ks_hostif.o: In function `michael_mic.constprop.13': ks_hostif.c:(.text+0x560): undefined reference to `crypto_alloc_shash' ks_hostif.c:(.text+0x580): undefined reference to `crypto_shash_setkey' ks_hostif.c:(.text+0x5e0):

Re: [PATCH -next] ASoC: SOF: Intel: hda: remove duplicated include from hda.c

2019-06-20 Thread Pierre-Louis Bossart
On 6/20/19 4:57 PM, YueHaibing wrote: Remove duplicated include. Signed-off-by: YueHaibing Acked-by: Pierre-Louis Bossart --- sound/soc/sof/intel/hda.c | 1 - 1 file changed, 1 deletion(-) diff --git a/sound/soc/sof/intel/hda.c b/sound/soc/sof/intel/hda.c index

Re: [PATCH V33 02/30] security: Add a "locked down" LSM hook

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:19:13PM -0700, Matthew Garrett wrote: > Add a mechanism to allow LSMs to make a policy decision around whether > kernel functionality that would allow tampering with or examining the > runtime state of the kernel should be permitted. > > Signed-off-by: Matthew Garrett

Re: [PATCH V33 01/30] security: Support early LSMs

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:19:12PM -0700, Matthew Garrett wrote: > The lockdown module is intended to allow for kernels to be locked down > early in boot - sufficiently early that we don't have the ability to > kmalloc() yet. Add support for early initialisation of some LSMs, and > then add them

Re: [PATCH] dmaengine: tegra210-adma: fix transfer failure

2019-06-20 Thread Sameer Pujar
On 6/20/2019 10:13 PM, Jon Hunter wrote: On 20/06/2019 17:15, Sameer Pujar wrote: From Tegra186 onwards OUTSTANDING_REQUESTS field is added in channel configuration register (bits 7:4). ADMA allows a maximum of 8 reads to source and that many writes to target memory be outstanding at any

Re: [PATCH] dmaengine: tegra210-adma: fix transfer failure

2019-06-20 Thread Sameer Pujar
On 6/20/2019 10:07 PM, Jon Hunter wrote: On 20/06/2019 17:15, Sameer Pujar wrote: From Tegra186 onwards OUTSTANDING_REQUESTS field is added in channel configuration register (bits 7:4). ADMA allows a maximum of 8 reads to source and that many writes to target memory be outstanding at any

[PATCH v2 1/2] iio: cros_ec: Add sign vector in core for backward compatibility

2019-06-20 Thread Gwendal Grignou
To allow cros_ec iio core library to be used with legacy device, add a vector to rotate sensor data if necessary: legacy devices are not reporting data in HTML5/Android sensor referential. On veyron minnie, check chrome detect tablet mode and rotate screen in tablet mode. Signed-off-by: Gwendal

[PATCH v2 2/2] iio: cros_ec : Extend legacy support to ARM device

2019-06-20 Thread Gwendal Grignou
Add support to ARM based devices, that lack LPC access code. Allow cros-ec-accel-legacy to use cros-ec-sensors-core, add specific command to capture sensor data. On veyron minnie, check chrome detect tablet mode and rotate screen in tablet mode. Check only a subset of the attributes are

[PATCH 0/2] Support accelerometers for veyron_minnie

2019-06-20 Thread Gwendal Grignou
veyron_minnie - ASUS Chromebook Flip C100PA - embedded controller controls two accelerometers, one in the lid, one in the base. However, the EC firmware does not follow the new interface that cros_ec_accel driver use. Extend the legacy driver used on glimmer - Lenovo ThinkPad 11e Chromebook - to

Re: [PATCH] net: fddi: skfp: remove generic PCI defines from skfbi.h

2019-06-20 Thread kbuild test robot
Hi Puranjay, Thank you for the patch! Yet something to improve: [auto build test ERROR on net/master] [also build test ERROR on v5.2-rc5 next-20190620] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux

Re: [PATCH v2] mm: memcg/slab: properly handle kmem_caches reparented to root_mem_cgroup

2019-06-20 Thread Shakeel Butt
On Thu, Jun 20, 2019 at 2:35 PM Roman Gushchin wrote: > > As a result of reparenting a kmem_cache might belong to the root > memory cgroup. It happens when a top-level memory cgroup is removed, > and all associated kmem_caches are reparented to the root memory > cgroup. > > The root memory cgroup

Re: [PATCH 1/2] iio: cros_ec: Add sign vector in core for backward compatibility

2019-06-20 Thread Gwendal Grignou
On Thu, Jun 20, 2019 at 2:46 PM Doug Anderson wrote: > > Hi, > > On Thu, Jun 20, 2019 at 11:53 AM Gwendal Grignou wrote: > > > > To allow cros_ec iio core library to be used with legacy device, add a > > vector to rotate sensor data if necessary: legacy devices are not > > reporting data in

Re: [PATCH 4.9 000/117] 4.9.183-stable review

2019-06-20 Thread Naresh Kamboju
On Thu, 20 Jun 2019 at 23:33, Greg Kroah-Hartman wrote: > > This is the start of the stable review cycle for the 4.9.183 release. > There are 117 patches in this series, all will be posted as a response > to this one. If anyone has any issues with these being applied, please > let me know. > >

Re: [PATCH] FDDI: defza: Include linux/io-64-nonatomic-lo-hi.h

2019-06-20 Thread Maciej W. Rozycki
On Thu, 20 Jun 2019, Paul Burton wrote: > Maciej, David, if you'd be happy to provide an Ack so that I can take > this through the mips-next branch that would be great; that'll let me > apply it prior to the asm/io.h change. Acked-by: Maciej W. Rozycki Sure, thanks for doing this work.

[PATCH] rtc: Don't state that the RTC holds UTC in case it doesn't

2019-06-20 Thread Finn Thain
Some machines store local time in the Real Time Clock. The hard-coded "UTC" string is wrong on those machines so just omit that string. Update the log parser so it doesn't require the string "UTC". Signed-off-by: Finn Thain --- drivers/rtc/hctosys.c | 2 +-

[GIT PULL] SMB3 Fixes

2019-06-20 Thread Steve French
Please pull the following changes since commit d1fdb6d8f6a4109a4263176c84b899076a5f8008: Linux 5.2-rc4 (2019-06-08 20:24:46 -0700) are available in the Git repository at: git://git.samba.org/sfrench/cifs-2.6.git tags/5.2-rc5-smb3-fixes for you to fetch changes up to

Re: [PATCH] soc: aspeed: lpc-ctrl: Fix probe error handling

2019-06-20 Thread Andrew Jeffery
On Thu, 20 Jun 2019, at 18:47, Joel Stanley wrote: > gcc warns that a mising "flash" phandle node leads to undefined > behavior later: > > drivers/soc/aspeed/aspeed-lpc-ctrl.c: In function > 'aspeed_lpc_ctrl_probe': > drivers/soc/aspeed/aspeed-lpc-ctrl.c:201:18: error: '*((void > *)+8)' may

Re: [PATCH v2] RISC-V: Break load reservations during switch_to

2019-06-20 Thread Palmer Dabbelt
On Wed, 19 Jun 2019 00:36:01 PDT (-0700), mark.rutl...@arm.com wrote: On Fri, Jun 07, 2019 at 03:22:22PM -0700, Palmer Dabbelt wrote: The comment describes why in detail. This was found because QEMU never gives up load reservations, the issue is unlikely to manifest on real hardware. Thanks

Re: [PATCH 2/4] powerpc/powernv: remove the unused tunneling exports

2019-06-20 Thread Oliver O'Halloran
On Thu, May 23, 2019 at 5:51 PM Christoph Hellwig wrote: > > These have been unused ever since they've been added to the kernel. > > Signed-off-by: Christoph Hellwig > --- > arch/powerpc/include/asm/pnv-pci.h| 4 -- > arch/powerpc/platforms/powernv/pci-ioda.c | 4 +- >

[PATCH] perf-script: assume native_arch for pipe mode

2019-06-20 Thread Song Liu
In pipe mode, session->header.env.arch is not populated until the events are processed. Therefore, the following command crashes: perf record -o - | perf script (gdb) bt It fails when we try to compare env.arch against uts.machine: if (!strcmp(uts.machine, session->header.env.arch)

[PATCH v2] sched/isolation: Prefer housekeeping cpu in local node

2019-06-20 Thread Wanpeng Li
From: Wanpeng Li In real product setup, there will be houseeking cpus in each nodes, it is prefer to do housekeeping from local node, fallback to global online cpumask if failed to find houseeking cpu from local node. Cc: Ingo Molnar Cc: Peter Zijlstra Cc: Frederic Weisbecker

Re: [PATCH v4 2/5] KVM: LAPIC: inject lapic timer interrupt by posted interrupt

2019-06-20 Thread Wanpeng Li
On Thu, 20 Jun 2019 at 05:04, Marcelo Tosatti wrote: > > Hi Li, > > On Wed, Jun 19, 2019 at 08:36:06AM +0800, Wanpeng Li wrote: > > On Tue, 18 Jun 2019 at 21:36, Marcelo Tosatti wrote: > > > > > > On Mon, Jun 17, 2019 at 07:24:44PM +0800, Wanpeng Li wrote: > > > > From: Wanpeng Li > > > > > > >

Re: [PATCH] sched/isolation: Prefer housekeeping cpu in local node

2019-06-20 Thread Wanpeng Li
On Thu, 20 Jun 2019 at 20:38, Peter Zijlstra wrote: > > On Thu, Jun 20, 2019 at 07:36:54PM +0800, Wanpeng Li wrote: > > From: Wanpeng Li > > > > In real product setup, there will be houseeking cpus in each nodes, it > > is prefer to do housekeeping from local node, fallback to global online > >

Re: [PATCH 4/4] powerpc/powernv: remove the unused vas_win_paste_addr and vas_win_id functions

2019-06-20 Thread Oliver O'Halloran
On Thu, May 23, 2019 at 5:56 PM Christoph Hellwig wrote: > > These two function have never been used since they were added to the > kernel. > > Signed-off-by: Christoph Hellwig > --- > arch/powerpc/include/asm/vas.h | 10 -- > arch/powerpc/platforms/powernv/vas-window.c |

[PATCH V33 01/30] security: Support early LSMs

2019-06-20 Thread Matthew Garrett
The lockdown module is intended to allow for kernels to be locked down early in boot - sufficiently early that we don't have the ability to kmalloc() yet. Add support for early initialisation of some LSMs, and then add them to the list of names when we do full initialisation later. Signed-off-by:

[PATCH V33 05/30] Restrict /dev/{mem,kmem,port} when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett Allowing users to read and write to core kernel memory makes it possible for the kernel to be subverted, avoiding module loading restrictions, and also to steal cryptographic information. Disallow /dev/mem and /dev/kmem from being opened this when the kernel has been

[PATCH V33 04/30] Enforce module signatures if the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: David Howells If the kernel is locked down, require that all modules have valid signatures that we can verify. I have adjusted the errors generated: (1) If there's no signature (ENODATA) or we can't check it (ENOPKG, ENOKEY), then: (a) If signatures are enforced then

[PATCH V33 09/30] kexec_file: Restrict at runtime if the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Jiri Bohac When KEXEC_SIG is not enabled, kernel should not load images through kexec_file systemcall if the kernel is locked down. [Modified by David Howells to fit with modifications to the previous patch and to return -EPERM if the kernel is locked down for consistency with other

[PATCH V33 15/30] ACPI: Limit access to custom_method when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett custom_method effectively allows arbitrary access to system memory, making it possible for an attacker to circumvent restrictions on module loading. Disable it if the kernel is locked down. Signed-off-by: Matthew Garrett Signed-off-by: David Howells cc:

[PATCH V33 17/30] acpi: Disable ACPI table override if the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Linn Crosetto >From the kernel documentation (initrd_table_override.txt): If the ACPI_INITRD_TABLE_OVERRIDE compile option is true, it is possible to override nearly any ACPI table provided by the BIOS with an instrumented, modified one. When lockdown is enabled, the kernel should

[PATCH V33 22/30] Lock down /proc/kcore

2019-06-20 Thread Matthew Garrett
From: David Howells Disallow access to /proc/kcore when the kernel is locked down to prevent access to cryptographic data. This is limited to lockdown confidentiality mode and is still permitted in integrity mode. Signed-off-by: David Howells Signed-off-by: Matthew Garrett ---

[PATCH V33 20/30] Lock down module params that specify hardware parameters (eg. ioport)

2019-06-20 Thread Matthew Garrett
From: David Howells Provided an annotation for module parameters that specify hardware parameters (such as io ports, iomem addresses, irqs, dma channels, fixed dma buffers and other types). Suggested-by: Alan Cox Signed-off-by: David Howells Signed-off-by: Matthew Garrett ---

[PATCH V33 18/30] Prohibit PCMCIA CIS storage when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: David Howells Prohibit replacement of the PCMCIA Card Information Structure when the kernel is locked down. Suggested-by: Dominik Brodowski Signed-off-by: David Howells Signed-off-by: Matthew Garrett --- drivers/pcmcia/cistpl.c | 4 include/linux/security.h | 1 +

[PATCH V33 21/30] x86/mmiotrace: Lock down the testmmiotrace module

2019-06-20 Thread Matthew Garrett
From: David Howells The testmmiotrace module shouldn't be permitted when the kernel is locked down as it can be used to arbitrarily read and write MMIO space. This is a runtime check rather than buildtime in order to allow configurations where the same kernel may be run in both locked down or

[PATCH V33 25/30] Lock down perf when in confidentiality mode

2019-06-20 Thread Matthew Garrett
From: David Howells Disallow the use of certain perf facilities that might allow userspace to access kernel data. Signed-off-by: David Howells Signed-off-by: Matthew Garrett Cc: Peter Zijlstra Cc: Ingo Molnar Cc: Arnaldo Carvalho de Melo --- include/linux/security.h | 1 +

[PATCH V33 26/30] kexec: Allow kexec_file() with appropriate IMA policy when locked down

2019-06-20 Thread Matthew Garrett
Systems in lockdown mode should block the kexec of untrusted kernels. For x86 and ARM we can ensure that a kernel is trustworthy by validating a PE signature, but this isn't possible on other architectures. On those platforms we can use IMA digital signatures instead. Add a function to determine

[PATCH V33 23/30] Lock down tracing and perf kprobes when in confidentiality mode

2019-06-20 Thread Matthew Garrett
From: David Howells Disallow the creation of perf and ftrace kprobes when the kernel is locked down in confidentiality mode by preventing their registration. This prevents kprobes from being used to access kernel memory to steal crypto data, but continues to allow the use of kprobes from signed

[PATCH V33 12/30] PCI: Lock down BAR access when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett Any hardware that can potentially generate DMA has to be locked down in order to avoid it being possible for an attacker to modify kernel code, allowing them to circumvent disabled module loading or module signing. Default to paranoid - in future we can potentially relax

[PATCH V33 28/30] debugfs: Restrict debugfs when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: David Howells Disallow opening of debugfs files that might be used to muck around when the kernel is locked down as various drivers give raw access to hardware through debugfs. Given the effort of auditing all 2000 or so files and manually fixing each one as necessary, I've chosen to

[PATCH V33 30/30] efi: Restrict efivar_ssdt_load when the kernel is locked down

2019-06-20 Thread Matthew Garrett
efivar_ssdt_load allows the kernel to import arbitrary ACPI code from an EFI variable, which gives arbitrary code execution in ring 0. Prevent that when the kernel is locked down. Signed-off-by: Matthew Garrett Cc: Ard Biesheuvel Cc: linux-...@vger.kernel.org --- drivers/firmware/efi/efi.c | 4

[PATCH V33 29/30] tracefs: Restrict tracefs when the kernel is locked down

2019-06-20 Thread Matthew Garrett
Tracefs may release more information about the kernel than desirable, so restrict it when the kernel is locked down in confidentiality mode by preventing open(). Signed-off-by: Matthew Garrett Cc: Steven Rostedt --- fs/tracefs/inode.c | 41 +++-

[PATCH V33 27/30] lockdown: Print current->comm in restriction messages

2019-06-20 Thread Matthew Garrett
Print the content of current->comm in messages generated by lockdown to indicate a restriction that was hit. This makes it a bit easier to find out what caused the message. The message now patterned something like: Lockdown: : is restricted; see man kernel_lockdown.7 Signed-off-by:

[PATCH V33 24/30] bpf: Restrict bpf when kernel lockdown is in confidentiality mode

2019-06-20 Thread Matthew Garrett
From: David Howells There are some bpf functions can be used to read kernel memory: bpf_probe_read, bpf_probe_write_user and bpf_trace_printk. These allow private keys in kernel memory (e.g. the hibernation image signing key) to be read by an eBPF program and kernel memory to be altered without

[PATCH V33 14/30] x86/msr: Restrict MSR access when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett Writing to MSRs should not be allowed if the kernel is locked down, since it could lead to execution of arbitrary code in kernel mode. Based on a patch by Kees Cook. Signed-off-by: Matthew Garrett Signed-off-by: David Howells Acked-by: Kees Cook Reviewed-by: Thomas

[PATCH V33 19/30] Lock down TIOCSSERIAL

2019-06-20 Thread Matthew Garrett
From: David Howells Lock down TIOCSSERIAL as that can be used to change the ioport and irq settings on a serial port. This only appears to be an issue for the serial drivers that use the core serial code. All other drivers seem to either ignore attempts to change port/irq or give an error.

[PATCH V33 11/30] uswsusp: Disable when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett uswsusp allows a user process to dump and then restore kernel state, which makes it possible to modify the running kernel. Disable this if the kernel is locked down. Signed-off-by: David Howells Signed-off-by: Matthew Garrett cc: linux...@vger.kernel.org Cc:

[PATCH V33 16/30] acpi: Ignore acpi_rsdp kernel param when the kernel has been locked down

2019-06-20 Thread Matthew Garrett
From: Josh Boyer This option allows userspace to pass the RSDP address to the kernel, which makes it possible for a user to modify the workings of hardware . Reject the option when the kernel is locked down. Signed-off-by: Josh Boyer Signed-off-by: David Howells Signed-off-by: Matthew

[PATCH V33 13/30] x86: Lock down IO port access when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett IO port access would permit users to gain access to PCI configuration registers, which in turn (on a lot of hardware) give access to MMIO register space. This would potentially permit root to trigger arbitrary DMA, so lock it down by default. This also implicitly locks

[PATCH V33 10/30] hibernate: Disable when the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Josh Boyer There is currently no way to verify the resume image when returning from hibernate. This might compromise the signed modules trust model, so until we can work with signed hibernate images we disable it when the kernel is locked down. Signed-off-by: Josh Boyer Signed-off-by:

[PATCH V33 07/30] Copy secure_boot flag in boot params across kexec reboot

2019-06-20 Thread Matthew Garrett
From: Dave Young Kexec reboot in case secure boot being enabled does not keep the secure boot mode in new kernel, so later one can load unsigned kernel via legacy kexec_load. In this state, the system is missing the protections provided by secure boot. Adding a patch to fix this by retain the

[PATCH V33 03/30] security: Add a static lockdown policy LSM

2019-06-20 Thread Matthew Garrett
While existing LSMs can be extended to handle lockdown policy, distributions generally want to be able to apply a straightforward static policy. This patch adds a simple LSM that can be configured to reject either integrity or all lockdown queries, and can be configured at runtime (through

[PATCH V33 06/30] kexec_load: Disable at runtime if the kernel is locked down

2019-06-20 Thread Matthew Garrett
From: Matthew Garrett The kexec_load() syscall permits the loading and execution of arbitrary code in ring 0, which is something that lock-down is meant to prevent. It makes sense to disable kexec_load() in this situation. This does not affect kexec_file_load() syscall which can check for a

Re: [PATCH -next] slub: play init_on_free=1 well with SLAB_RED_ZONE

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 06:14:33PM -0700, Kees Cook wrote: > On Thu, Jun 20, 2019 at 03:28:01PM -0400, Qian Cai wrote: > > diff --git a/mm/slub.c b/mm/slub.c > > index a384228ff6d3..787971d4fa36 100644 > > --- a/mm/slub.c > > +++ b/mm/slub.c > > @@ -1437,7 +1437,7 @@ static inline bool

[PATCH V33 00/30] Lockdown as an LSM

2019-06-20 Thread Matthew Garrett
Hi James, Let's see how this one goes. I've moved the lockdown code into an LSM hook and provided an internal enum of lockdown reasons that LSMs can either group or expose at whatever level of granularity is appropriate. I've also included a static LSM that mimics the behaviour of the existing

[PATCH V33 02/30] security: Add a "locked down" LSM hook

2019-06-20 Thread Matthew Garrett
Add a mechanism to allow LSMs to make a policy decision around whether kernel functionality that would allow tampering with or examining the runtime state of the kernel should be permitted. Signed-off-by: Matthew Garrett --- include/linux/lsm_hooks.h | 2 ++ include/linux/security.h | 11

Re: [PATCH -next] slub: play init_on_free=1 well with SLAB_RED_ZONE

2019-06-20 Thread Kees Cook
... > Redzone (ptrval): 00 00 00 00 00 00 00 00 > > Padding (ptrval____): 00 00 00 00 00 00 00 00 > > CPU: 0 PID: 1 Comm: swapper/0 Tainted: GB > 5.2.0-rc5-next-20190620+ #2 > Call Trace: > [c0002b72f4b0] [c089ce5c

Re: linux-next: manual merge of the scsi tree with Linus' tree

2019-06-20 Thread Martin K. Petersen
James, > There's two problems. One is simple terminology: the > Documentation/process/licence-rules.rst say: > > GPL-2.0 means GPL 2 only > GPL-2.0+ means GPL 2 or later > > I believe RMS made a fuss about this and he finally agreed to > > GPL-2.0-only > GPL-2.0-or-later Looks like there are

RE: [PATCH] rapidio/mport_cdev: NUL terminate some strings

2019-06-20 Thread alex.bou9
Acked-by: Alexandre Bounine -Original Message- From: Dan Carpenter Sent: Wednesday, May 29, 2019 7:06 AM To: Matt Porter Cc: Alexandre Bounine ; Andrew Morton ; Ira Weiny ; linux-kernel@vger.kernel.org; kernel-janit...@vger.kernel.org Subject: [PATCH] rapidio/mport_cdev: NUL

Re: [PATCH -next v2] mm/page_alloc: fix a false memory corruption

2019-06-20 Thread Kees Cook
On Thu, Jun 20, 2019 at 04:46:06PM -0400, Qian Cai wrote: > The linux-next commit "mm: security: introduce init_on_alloc=1 and > init_on_free=1 boot options" [1] introduced a false positive when > init_on_free=1 and page_poison=on, due to the page_poison expects the > pattern 0xaa when allocating

Re: [PATCH 3/6] libnvdimm/region: Register badblocks before namespaces

2019-06-20 Thread Verma, Vishal L
On Tue, 2019-06-11 at 16:25 -0700, Dan Williams wrote: > Namespace activation expects to be able to reference region badblocks. > The following warning sometimes triggers when asynchronous namespace > activation races in front of the completion of namespace probing. Move > all possible namespace

Re: [PATCH v5 6/6] mm,thp: avoid writes to file with THP in pagecache

2019-06-20 Thread Rik van Riel
On Thu, 2019-06-20 at 13:53 -0700, Song Liu wrote: > In previous patch, an application could put part of its text section > in > THP via madvise(). These THPs will be protected from writes when the > application is still running (TXTBSY). However, after the application > exits, the file is

Re: [PATCH] device-dax: Add a 'resource' attribute

2019-06-20 Thread Dan Williams
On Thu, Jun 20, 2019 at 5:41 PM Vishal Verma wrote: > > device-dax based devices were missing a 'resource' attribute to indicate > the physical address range contributed by the device in question. This > information is desirable to userspace tooling that may want to use the > dax device as

Re: [LKP] [btrfs] c8eaeac7b7: aim7.jobs-per-min -11.7% regression

2019-06-20 Thread Huang, Ying
"Huang, Ying" writes: > "Huang, Ying" writes: > >> Hi, Josef, >> >> kernel test robot writes: >> >>> Greeting, >>> >>> FYI, we noticed a -11.7% regression of aim7.jobs-per-min due to commit: >>> >>> >>> commit: c8eaeac7b734347c3afba7008b7af62f37b9c140 ("btrfs: reserve >>> delalloc metadata

Re: linux-next: manual merge of the scsi tree with Linus' tree

2019-06-20 Thread Linus Torvalds
On Thu, Jun 20, 2019 at 5:35 PM James Bottomley wrote: > > * This file is licensed under GPLv2. > > In all the libsas files, but then muddied the water by quoting GPLv2 > verbatim (which includes the or later than language). Ok, thanks for the explanation. And yes, that would have likely

[PATCH] device-dax: Add a 'resource' attribute

2019-06-20 Thread Vishal Verma
device-dax based devices were missing a 'resource' attribute to indicate the physical address range contributed by the device in question. This information is desirable to userspace tooling that may want to use the dax device as system-ram, and wants to selectively hotplug and online the memory

Re: linux-next: manual merge of the scsi tree with Linus' tree

2019-06-20 Thread Martin K. Petersen
Linus, > That said, I would tend to trust the due diligence that Thomas, Greg & > co have done, and am wondering why the scsi tree ends up having > different SPDX results in the first place.. I left Christoph's patches in my 5.3 queue after Stephen let me know about the treewide series

Re: linux-next: manual merge of the scsi tree with Linus' tree

2019-06-20 Thread James Bottomley
On Thu, 2019-06-20 at 17:07 -0700, Linus Torvalds wrote: > On Thu, Jun 20, 2019 at 4:59 PM Stephen Rothwell u> wrote: > > > > At what point does it become worth while to do a back merge of > > v5.2-rc4 (I think the last of the SPDX changes went into there) to > > take care of all these (rather

Re: [PATCH] flow_dissector: Fix vlan header offset in __skb_flow_dissect

2019-06-20 Thread Stanislav Fomichev
On 06/20, Yuehaibing wrote: > On 2019/6/20 2:39, Stanislav Fomichev wrote: > > On 06/20, YueHaibing wrote: > >> We build vlan on top of bonding interface, which vlan offload > >> is off, bond mode is 802.3ad (LACP) and xmit_hash_policy is > >> BOND_XMIT_POLICY_ENCAP34. > >> > >>

Re: [PATCH v2] ocxl: Allow contexts to be attached with a NULL mm

2019-06-20 Thread Andrew Donnellan
On 20/6/19 2:12 pm, Alastair D'Silva wrote: From: Alastair D'Silva If an OpenCAPI context is to be used directly by a kernel driver, there may not be a suitable mm to use. The patch makes the mm parameter to ocxl_context_attach optional. Signed-off-by: Alastair D'Silva Acked-by: Andrew

  1   2   3   4   5   6   7   8   9   10   >