Re: [RFC-PATCH 2/4] mm: Add __rcu_alloc_page_lockless() func.

2020-09-25 Thread Uladzislau Rezki
> > > > > > > > All good points! > > > > > > > > On the other hand, duplicating a portion of the allocator functionality > > > > within RCU increases the amount of reserved memory, and needlessly most > > > > of the time. > > > > > > > > > > But it's very similar to what mempools are for. > > >

RE: [PATCH v4] Introduce support for Systems Management Driver over WMI for Dell Systems

2020-09-25 Thread Limonciello, Mario
So I do want to preface this response by mentioning that Dell's implementation is based off the PLDM specification from the DMTF. https://www.dmtf.org/sites/default/files/standards/documents/DSP0247_1.0.0.pdf A lot of the nomenclature that has been already proposed to change followed nomenclature

Re: [PATCH v3 2/2] PCI: dwc: Use an address in the driver data for MSI address

2020-09-25 Thread Rob Herring
+Niklas On Fri, Sep 25, 2020 at 2:39 AM Jisheng Zhang wrote: > > There's no need to allocate a page for the MSI address, we could use > an address in the driver data. > > One side effect of this patch is fixing the MSI page leakage during > suspend/resume. Take the pcie-tegra194.c for example, it

Re: [PATCH 0/3] Prevent out-of-bounds access for built-in font data buffers

2020-09-25 Thread Peilin Ye
On Fri, Sep 25, 2020 at 03:25:51PM +0200, Daniel Vetter wrote: > I think the only way to make this work is that we have one place which > takes in the userspace uapi struct, and then converts it once into a > kernel_console_font. With all the error checking. Ah, I didn't think of that! When trying

[PATCH v13 05/26] x86/cet/shstk: Add Kconfig option for user-mode Shadow Stack

2020-09-25 Thread Yu-cheng Yu
Shadow Stack provides protection against function return address corruption. It is active when the processor supports it, the kernel has CONFIG_X86_SHADOW_STACK_USER, and the application is built for the feature. This is only implemented for the 64-bit kernel. When it is enabled, legacy non-shado

[PATCH v13 12/26] mm: Introduce VM_SHSTK for shadow stack memory

2020-09-25 Thread Yu-cheng Yu
A Shadow Stack PTE must be read-only and have _PAGE_DIRTY set. However, read-only and Dirty PTEs also exist for copy-on-write (COW) pages. These two cases are handled differently for page faults. Introduce VM_SHSTK to track shadow stack VMAs. Signed-off-by: Yu-cheng Yu Reviewed-by: Kees Cook

Re: Ways to deprecate /sys/devices/system/memory/memoryX/phys_device ?

2020-09-25 Thread Michal Hocko
On Fri 25-09-20 16:49:28, David Hildenbrand wrote: > >> There were once RFC patches to make use of it in ACPI, but it could be > >> solved using different interfaces [1]. > >> > >> > >> While I'd love to rip it out completely, I think it would break old > >> lsmem/chmem completely - and I assume th

Re: [PATCH] MAINTAINERS: Add me as a reviewer for PCI aardvark

2020-09-25 Thread Bjorn Helgaas
On Fri, Sep 25, 2020 at 11:21:15AM +0200, Pali Rohár wrote: > Signed-off-by: Pali Rohár > --- > I have provided more fixes to this driver, I have needed functional > specification for this PCI controller and also hardware for testing > and developing (Espressobin V5 and Turris MOX B and G modules)

Re: [RFC PATCH 0/9] Add support for Microsoft Surface System Aggregator Module

2020-09-25 Thread Maximilian Luz
On 9/25/20 4:58 PM, Andy Shevchenko wrote: On Thu, Sep 24, 2020 at 10:17 PM Maximilian Luz wrote: On 9/24/20 10:30 AM, Andy Shevchenko wrote: On Wed, Sep 23, 2020 at 6:32 PM Arnd Bergmann wrote: On Wed, Sep 23, 2020 at 5:15 PM Maximilian Luz wrote: ... I think this should go to drivers/

[PATCH v13 02/26] x86/cpufeatures: Add CET CPU feature flags for Control-flow Enforcement Technology (CET)

2020-09-25 Thread Yu-cheng Yu
Add CPU feature flags for Control-flow Enforcement Technology (CET). CPUID.(EAX=7,ECX=0):ECX[bit 7] Shadow stack CPUID.(EAX=7,ECX=0):EDX[bit 20] Indirect Branch Tracking Signed-off-by: Yu-cheng Yu Reviewed-by: Borislav Petkov Reviewed-by: Kees Cook --- arch/x86/include/asm/cpufeatures.h

Re: Ways to deprecate /sys/devices/system/memory/memoryX/phys_device ?

2020-09-25 Thread David Hildenbrand
2. Restrict it to s390x only. It always returned 0 on other architectures, I was not able to find any user. I think 2 should be safe to do (never used on other archs). I do wonder what the feelings are about 1. >>> >>> Please don't add any s390-specific workarounds here, th

[PATCH v13 08/26] x86/mm: Introduce _PAGE_COW

2020-09-25 Thread Yu-cheng Yu
There is essentially no room left in the x86 hardware PTEs on some OSes (not Linux). That left the hardware architects looking for a way to represent a new memory type (shadow stack) within the existing bits. They chose to repurpose a lightly-used state: Write=0,Dirty=1. The reason it's lightly u

Re: [PATCH v4 1/4] dt-bindings: i2c: imx-lpi2c: Add properties and use unevaluatedProperties

2020-09-25 Thread Krzysztof Kozlowski
On Thu, Sep 17, 2020 at 09:13:18PM +0200, Krzysztof Kozlowski wrote: > Additional properties actually might appear (e.g. power-domains) so > describe all typical properties, reference generic i2c schema and use > unevaluatedProperties to fix dtbs_check warnings like: > > arch/arm64/boot/dts/free

Re: [RFC-PATCH 2/4] mm: Add __rcu_alloc_page_lockless() func.

2020-09-25 Thread Michal Hocko
On Fri 25-09-20 17:31:29, Uladzislau Rezki wrote: > > > > > > > > > > All good points! > > > > > > > > > > On the other hand, duplicating a portion of the allocator > > > > > functionality > > > > > within RCU increases the amount of reserved memory, and needlessly > > > > > most > > > > > of t

Re: [PATCH v3 01/15] dt-bindings: gpio: convert bindings for NXP PCA953x family to dtschema

2020-09-25 Thread Krzysztof Kozlowski
On Wed, Sep 16, 2020 at 05:57:01PM +0200, Krzysztof Kozlowski wrote: > Convert the NXP PCA953x family of GPIO expanders bindings to device tree > schema. > > Signed-off-by: Krzysztof Kozlowski > Reviewed-by: Rob Herring > > --- > > Changes since v2: > 1. Add Rob's review tag > > Changes since

Re: [PATCH v3 1/2] PCI: dwc: Skip PCIE_MSI_INTR0* programming if MSI is disabled

2020-09-25 Thread Rob Herring
On Fri, Sep 25, 2020 at 2:39 AM Jisheng Zhang wrote: > > If MSI is disabled, there's no need to program PCIE_MSI_INTR0_MASK > and PCIE_MSI_INTR0_ENABLE registers. > > Fixes: 7c5925afbc58 ("PCI: dwc: Move MSI IRQs allocation to IRQ > domainshierarchical API") > Signed-off-by: Jisheng Zhang > Acke

Re: [patch V2 00/46] x86, PCI, XEN, genirq ...: Prepare for device MSI

2020-09-25 Thread Peter Zijlstra
wapper/0 Tainted: G I >5.9.0-rc6-next-20200925 #2 > [8.503987][T0] Hardware name: HPE ProLiant DL560 Gen10/ProLiant DL560 > Gen10, BIOS U34 11/13/2019 > [8.513238][T0] RIP: 0010:0x0 > [8.516562][T0] Code: Bad RIP v Here it looks like t

Re: [PATCH][next] drm/i915: Fix inconsistent IS_ERR and PTR_ERR

2020-09-25 Thread Gustavo A. R. Silva
Hi all, Friendly ping: who can take this? Thanks -- Gustavo On 9/10/20 05:21, Gustavo A. R. Silva wrote: > Fix inconsistent IS_ERR and PTR_ERR in i915_gem_object_copy_blt(). > > The proper pointer to be passed as argument to PTR_ERR() is vma[1]. > > This bug was detected with the help of Cocci

[RFC] mm: Allow 64-bit mmap syscalls to access higher addresses.

2020-09-25 Thread Derek Lesho
For those curious about my usecase, I'm working on running some windows 64-bit driver code in context of any given process. I accomplish this by mapping some of the fake kernel bits in the target process, and running the code in a dedicated thread. --- mm/mmap.c | 4 ++-- 1 file changed, 2 inse

Re: [PATCH v6 0/6] irqchip: dw-apb-ictl: support hierarchy irq domain

2020-09-25 Thread Marc Zyngier
On Thu, 24 Sep 2020 15:17:48 +0800, Zhen Lei wrote: > v5 --> v6: > 1. add Reviewed-by: Rob Herring for Patch 4. > 2. Some modifications are made to Patch 5: >1) add " |" for each "description:" property if its content exceeds one > line, > to tell the yaml keep the "newline" character.

Co-Operation Required

2020-09-25 Thread L A
Hello there, I am Laghouili Abdellatif. I am contacting you because I have a proposal that I think may be interested in. I represent the interest of my brother in-law who was a minister in the Syrian Government. As you probably know, there is a lot of crisis going on currently in Syria and my

Re: [PATCH 1/3] software node: Power management operations for software nodes

2020-09-25 Thread Rafael J. Wysocki
On Tue, Aug 25, 2020 at 3:59 PM Heikki Krogerus wrote: > > Adding separate PM operations vector for the software nodes. > The software node specific PM operations make it possible to > handle most PM related quirks separately in their own > functions instead of conditionally in the device driver's

Re: [PATCH 3/3] [PATCH] staging: greybus: __u8 is sufficient for snd_ctl_elem_type_t and snd_ctl_elem_iface_t

2020-09-25 Thread Alex Elder
On 9/25/20 9:07 AM, Coiby Xu wrote: On Thu, Sep 24, 2020 at 01:00:57PM +0200, Greg Kroah-Hartman wrote: On Thu, Sep 24, 2020 at 06:20:39PM +0800, Coiby Xu wrote: Use __8 to replace int and remove the unnecessary __bitwise type attribute. Found by sparse, . . . diff --git a/include/uapi/so

[PATCH v7 03/10] fs/ntfs3: Add bitmap

2020-09-25 Thread Konstantin Komarov
This adds bitmap Signed-off-by: Konstantin Komarov --- fs/ntfs3/bitfunc.c | 137 fs/ntfs3/bitmap.c | 1508 2 files changed, 1645 insertions(+) create mode 100644 fs/ntfs3/bitfunc.c create mode 100644 fs/ntfs3/bitmap.c diff --git a/fs/ntfs3/b

[PATCH v7 00/10] NTFS read-write driver GPL implementation by Paragon Software

2020-09-25 Thread Konstantin Komarov
This patch adds NTFS Read-Write driver to fs/ntfs3. Having decades of expertise in commercial file systems development and huge test coverage, we at Paragon Software GmbH want to make our contribution to the Open Source Community by providing implementation of NTFS Read-Write driver for the Linux

[PATCH v7 04/10] fs/ntfs3: Add file operations and implementation

2020-09-25 Thread Konstantin Komarov
This adds file operations and implementation Signed-off-by: Konstantin Komarov --- fs/ntfs3/dir.c | 607 +++ fs/ntfs3/file.c| 1201 ++ fs/ntfs3/frecord.c | 2399 fs/ntfs3/namei.c | 576 +++ fs/ntfs3/reco

[PATCH v7 01/10] fs/ntfs3: Add headers and misc files

2020-09-25 Thread Konstantin Komarov
This adds headers and misc files Signed-off-by: Konstantin Komarov --- fs/ntfs3/debug.h | 60 ++ fs/ntfs3/ntfs.h| 1295 fs/ntfs3/ntfs_fs.h | 1002 ++ fs/ntfs3/upcase.c | 78 +++ 4 files changed, 2435 insertio

[PATCH v7 08/10] fs/ntfs3: Add Kconfig, Makefile and doc

2020-09-25 Thread Konstantin Komarov
This adds Kconfig, Makefile and doc Signed-off-by: Konstantin Komarov --- Documentation/filesystems/ntfs3.rst | 107 fs/ntfs3/Kconfig| 23 ++ fs/ntfs3/Makefile | 11 +++ 3 files changed, 141 insertions(+) create mode 10064

[PATCH v7 05/10] fs/ntfs3: Add attrib operations

2020-09-25 Thread Konstantin Komarov
This adds attrib operations Signed-off-by: Konstantin Komarov --- fs/ntfs3/attrib.c | 1316 +++ fs/ntfs3/attrlist.c | 462 +++ fs/ntfs3/xattr.c| 1056 ++ 3 files changed, 2834 insertions(+) create mode 10

[PATCH v7 07/10] fs/ntfs3: Add NTFS journal

2020-09-25 Thread Konstantin Komarov
This adds NTFS journal Signed-off-by: Konstantin Komarov --- fs/ntfs3/fslog.c | 5222 ++ 1 file changed, 5222 insertions(+) create mode 100644 fs/ntfs3/fslog.c diff --git a/fs/ntfs3/fslog.c b/fs/ntfs3/fslog.c new file mode 100644 index ..

[PATCH v7 10/10] fs/ntfs3: Add MAINTAINERS

2020-09-25 Thread Konstantin Komarov
This adds MAINTAINERS Signed-off-by: Konstantin Komarov --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 190c7fa2ea01..48b979e11f9b 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -12375,6 +12375,13 @@ T: git git://git.kernel.org/pub/s

[PATCH v7 06/10] fs/ntfs3: Add compression

2020-09-25 Thread Konstantin Komarov
This adds compression Signed-off-by: Konstantin Komarov --- fs/ntfs3/lznt.c | 452 1 file changed, 452 insertions(+) create mode 100644 fs/ntfs3/lznt.c diff --git a/fs/ntfs3/lznt.c b/fs/ntfs3/lznt.c new file mode 100644 index ..c9bde

[PATCH v7 09/10] fs/ntfs3: Add NTFS3 in fs/Kconfig and fs/Makefile

2020-09-25 Thread Konstantin Komarov
This adds NTFS3 in fs/Kconfig and fs/Makefile Signed-off-by: Konstantin Komarov --- fs/Kconfig | 1 + fs/Makefile | 1 + 2 files changed, 2 insertions(+) diff --git a/fs/Kconfig b/fs/Kconfig index aa4c12282301..eae96d55ab67 100644 --- a/fs/Kconfig +++ b/fs/Kconfig @@ -145,6 +145,7 @@ menu "DOS

Re: [PATCH v11 5/6] iommu/uapi: Handle data and argsz filled by users

2020-09-25 Thread Jacob Pan
Hi Jean-Philippe, On Fri, 25 Sep 2020 11:46:36 +0200, Jean-Philippe Brucker wrote: > On Thu, Sep 24, 2020 at 12:24:19PM -0700, Jacob Pan wrote: > > IOMMU user APIs are responsible for processing user data. This patch > > changes the interface such that user pointers can be passed into IOMMU > >

Re: [PATCH v7 0/3] Add Actions Semi Owl family sirq support

2020-09-25 Thread Marc Zyngier
On Mon, 14 Sep 2020 23:27:16 +0300, Cristian Ciocaltea wrote: > This patch series adds support for the external interrupt controller > (SIRQ) found in the Actions Semi Owl family of SoC's (S500, S700 and > S900). The controller handles up to 3 external interrupt lines through > dedicated SIRQ pins.

Re: [greybus-dev] [PATCH 3/3] [PATCH] staging: greybus: __u8 is sufficient for snd_ctl_elem_type_t and snd_ctl_elem_iface_t

2020-09-25 Thread Alex Elder
On 9/25/20 9:11 AM, Coiby Xu wrote: On Thu, Sep 24, 2020 at 10:54:50AM +, David Laight wrote: From: Coiby Xu Sent: 24 September 2020 11:21 Use __8 to replace int and remove the unnecessary __bitwise type attribute. Found by sparse, ... diff --git a/include/uapi/sound/asound.h b/include

Re: [Intel-gfx] [PATCH 08/11] drm/i915: use vmap in i915_gem_object_map

2020-09-25 Thread Christoph Hellwig
On Fri, Sep 25, 2020 at 03:08:59PM +0100, Matthew Auld wrote: > > + i = 0; > > + for_each_sgt_page(page, iter, obj->mm.pages) > > + pages[i++] = page; > > + vaddr = vmap(pages, n_pages, 0, pgprot); > > + if (pages != stack) > > + kvfree(pages); >

RE: [PATCH v5 03/10] fs/ntfs3: Add bitmap

2020-09-25 Thread Konstantin Komarov
From: Matthew Wilcox Sent: Friday, September 18, 2020 7:55 PM > Subject: Re: [PATCH v5 03/10] fs/ntfs3: Add bitmap > > On Fri, Sep 18, 2020 at 04:35:11PM +, Konstantin Komarov wrote: > > > That was only just renamed. More concerningly, the documentation is > > > quite unambiguous: > > > > >

remove bdget() as a public API

2020-09-25 Thread Christoph Hellwig
Hi Jens, this series first cleans up the somewhat odd size handling in drbd, and then kill off bdget() as a public API.

[PATCH 1/2] drbd: remove ->this_bdev

2020-09-25 Thread Christoph Hellwig
DRBD keeps a block device open just to get and set the capacity from it. Switch to primarily using the disk capacity as intended by the block layer, and sync it to the bdev using revalidate_disk_size. Signed-off-by: Christoph Hellwig --- drivers/block/drbd/drbd_actlog.c | 2 +- drivers/block

[PATCH 2/2] block: add a bdget_part helper

2020-09-25 Thread Christoph Hellwig
All remaining callers of bdget() outside of fs/block_dev.c want to get a reference to the struct block_device for a given struct hd_struct. Add a helper just for that and then mark bdget static. Signed-off-by: Christoph Hellwig --- block/genhd.c | 2 +- block/partitions/core.c | 2 +-

Re: [PATCH v3] Bluetooth: btusb: Add Qualcomm Bluetooth SoC WCN6855 support

2020-09-25 Thread Marcel Holtmann
Hi Rocky, > This patch add support for WCN6855 i.e. patch and nvm download > support. please always include the content of /sys/kernel/debug/usb/devices for this hardware. > > Signed-off-by: Rocky Liao > --- > drivers/bluetooth/btusb.c | 66 +++ > 1 file cha

Re: [PATCH v10 2/6] x86: Support Generic Initiator only proximity domains

2020-09-25 Thread Borislav Petkov
On Fri, Sep 25, 2020 at 12:32:26PM +0100, Jonathan Cameron wrote: > I don't think we can. This is doing the same operation as > is done for memoryless cpu nodes in the init_cpu_to_node() call above > so it would make little sense from a code flow point of view, even if > it were possible. However

[PATCH 08/11, fixed] drm/i915: use vmap in i915_gem_object_map

2020-09-25 Thread Christoph Hellwig
i915_gem_object_map implements fairly low-level vmap functionality in a driver. Split it into two helpers, one for remapping kernel memory which can use vmap, and one for I/O memory that uses vmap_pfn. The only practical difference is that alloc_vm_area prefeaults the vmalloc area PTEs, which doe

[PATCH v13 21/26] x86/cet/shstk: Handle signals for shadow stack

2020-09-25 Thread Yu-cheng Yu
To deliver a signal, create a shadow stack restore token and put a restore token and the signal restorer address on the shadow stack. For sigreturn, verify the token and restore the shadow stack pointer. Introduce WRUSS, which is a kernel-mode instruction but writes directly to user shadow stack.

Re: [PATCH v1] Bluetooth: send proper config param to unknown config request

2020-09-25 Thread Marcel Holtmann
Hi Archie, > When receiving an L2CAP_CONFIGURATION_REQ with an unknown config > type, currently we will reply with L2CAP_CONFIGURATION_RSP with > a list of unknown types as the config param. However, this is not > a correct format of config param. > > As described in the bluetooth spec v5.2, Vol

KASAN: use-after-free Read in squashfs_get_id

2020-09-25 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:171d4ff7 Merge tag 'mmc-v5.9-rc4-2' of git://git.kernel.or.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=122ff48190 kernel config: https://syzkaller.appspot.com/x/.config?x=af502ec9a451c9fc das

RE: [PATCH v6 05/10] fs/ntfs3: Add attrib operations

2020-09-25 Thread Konstantin Komarov
From: Mark Harmstone On Behalf Of Mark Harmstone Sent: Friday, September 18, 2020 9:28 PM > > Could I suggest that system.ntfs_security be renamed to security.NTACL? That's > what WinBtrfs uses, and it means you'd be able to create a working Btrfs copy > of a Windows installation just by using rs

RFC: sort out get_gendisk abuses

2020-09-25 Thread Christoph Hellwig
Hi all, this series tries to remove two abuses of the get_gendisk API. The first one is fairly straigt forward and switched the blk-cgroup configuration API to properly open the block device, but I'd love to see it reviewed and tested by the cgroup maintainers, as I don't really know how this code

[PATCH 1/2] blk-cgroup: stop abusing get_gendisk

2020-09-25 Thread Christoph Hellwig
Properly open the device instead of relying on deep internals by using get_gendisk. Signed-off-by: Christoph Hellwig --- block/blk-cgroup.c | 42 +++--- block/blk-iocost.c | 36 include/linux/blk-cgroup.h | 4 ++--

[PATCH 2/2] PM/hibernate: remove the bogus call to get_gendisk in software_resume

2020-09-25 Thread Christoph Hellwig
get_gendisk grabs a reference on the disk and file operation, so this code will leak both of them while having absolutely no use for the gendisk itself. This effectively reverts commit 2df83fa4bce421f ("PM / Hibernate: Use get_gendisk to verify partition if resume_file is integer format") Signed

Re: [PATCH 1/2] iommu/iova: Flush CPU rcache for when a depot fills

2020-09-25 Thread John Garry
On 25/09/2020 15:34, John Garry wrote: Indeed, I think that the mainline code has a bug: If the initial allocation for the loaded/prev magazines fail (give NULL) in init_iova_rcaches(), then in __iova_rcache_insert(): if (!iova_magazine_full(cpu_rcache->loaded)) { can_insert = true; If

Re: linux-next: Tree for Sep 25 [kernel/bpf/preload/bpf_preload.ko]

2020-09-25 Thread Randy Dunlap
On 9/25/20 3:55 AM, Stephen Rothwell wrote: > Hi all, > > Changes since 20200924: > on x86_64: ERROR: modpost: "bpf_preload_ops" [kernel/bpf/preload/bpf_preload.ko] undefined! Full randconfig file is attached. -- ~Randy Reported-by: Randy Dunlap # # Automatically generated file; DO NOT EDI

Re: [PATCH v6 1/9] kernel: Support TIF_SYSCALL_INTERCEPT flag

2020-09-25 Thread Gabriel Krisman Bertazi
Thomas Gleixner writes: > On Wed, Sep 23 2020 at 13:49, Kees Cook wrote: >> On Wed, Sep 23, 2020 at 04:18:26PM -0400, Gabriel Krisman Bertazi wrote: >>> Kees Cook writes: >>> Yes, we can, and I'm happy to follow up with that as part of my TIF >>> clean up work, but can we not block the current p

Re: [RFC-PATCH 2/4] mm: Add __rcu_alloc_page_lockless() func.

2020-09-25 Thread Mel Gorman
On Fri, Sep 25, 2020 at 05:31:29PM +0200, Uladzislau Rezki wrote: > > > > > > > > > > All good points! > > > > > > > > > > On the other hand, duplicating a portion of the allocator > > > > > functionality > > > > > within RCU increases the amount of reserved memory, and needlessly > > > > > mos

Re: [PATCH 1/2] ASoC: qdsp6: Drop of_match_ptr to fix -Wunused-const-variable

2020-09-25 Thread Mark Brown
On Fri, Sep 25, 2020 at 09:49:24AM +0100, Srinivas Kandagatla wrote: > The of_device_id is included unconditionally by of.h header and used > in the driver as well. Remove of_match_ptr to fix W=1 compile test > warning with !CONFIG_OF: It's better to fix this by adding #ifdefs around the table so

Re: [PATCH 08/18] dma-mapping: add a new dma_alloc_noncoherent API

2020-09-25 Thread Christoph Hellwig
On Fri, Sep 25, 2020 at 12:15:37PM +0100, Robin Murphy wrote: > On 2020-09-15 16:51, Christoph Hellwig wrote: > [...] >> +These APIs allow to allocate pages in the kernel direct mapping that are >> +guaranteed to be DMA addressable. This means that unlike >> dma_alloc_coherent, >> +virt_to_page c

Re: [PATCH v13 7/8] x86/vdso: Insert endbr32/endbr64 to vDSO

2020-09-25 Thread Andy Lutomirski
On Fri, Sep 25, 2020 at 7:58 AM Yu-cheng Yu wrote: > > From: "H.J. Lu" > > When Indirect Branch Tracking (IBT) is enabled, vDSO functions may be > called indirectly, and must have ENDBR32 or ENDBR64 as the first > instruction. The compiler must support -fcf-protection=branch so that it > can be

Re: [PATCH v4] cper, apei, mce: Pass x86 CPER through the MCA handling chain

2020-09-25 Thread Yazen Ghannam
On Fri, Sep 25, 2020 at 09:54:06AM +0900, Punit Agrawal wrote: > Borislav Petkov writes: > > > On Thu, Sep 24, 2020 at 12:23:27PM -0500, Smita Koralahalli Channabasappa > > wrote: > >> > Even though it's not defined in the UEFI spec, it doesn't mean a > >> > structure definition cannot be create

Re: REGRESSION: 37f4a24c2469: blk-mq: centralise related handling into blk_mq_get_driver_tag

2020-09-25 Thread Ming Lei
On Fri, Sep 25, 2020 at 03:31:45PM +0800, Ming Lei wrote: > On Thu, Sep 24, 2020 at 09:13:11PM -0400, Theodore Y. Ts'o wrote: > > On Thu, Sep 24, 2020 at 10:33:45AM -0400, Theodore Y. Ts'o wrote: > > > HOWEVER, thanks to a hint from a colleague at $WORK, and realizing > > > that one of the stack tr

Re: [PATCH 1/8] dma-mapping: add DMA_ATTR_LOW_ADDRESS attribute

2020-09-25 Thread Christoph Hellwig
> #define DMA_ATTR_PRIVILEGED (1UL << 9) > +/* > + * DMA_ATTR_LOW_ADDRESS: used to indicate that the buffer should be allocated > + * at the lowest possible DMA address, usually just at the beginning of the > + * DMA/IOVA address space ('first-fit' allocation algorithm). > + */ > +#define

[PATCH v4] sched/deadline: Fix sched_dl_global_validate()

2020-09-25 Thread Peng Liu
I created another root domain(contains 2 CPUs) besides the default one, and the global default rt bandwidth is 95%. Then launched a DL process which need 25% bandwidth and moved it to the new root domain, so far so good. Then I tried to change global rt bandwidth to 20% with cmd: echo 2000

[PATCH] mm: fix some comments in page_alloc.c and mempolicy.c

2020-09-25 Thread Hui Su
1. the cpuset.c has been moved from kernel/cpuset.c to kernel/cgroup/cpuset.c long time ago, but the comment is stale, so we update it. 2. get_page_from_freelist() may alloc many pages according to order, we may use pages for better. Signed-off-by: Hui Su --- kernel/cgroup/cpuset.c | 2 +- mm/me

Re: [PATCH 1/2] ASoC: qdsp6: Drop of_match_ptr to fix -Wunused-const-variable

2020-09-25 Thread Srinivas Kandagatla
On 25/09/2020 17:17, Mark Brown wrote: On Fri, Sep 25, 2020 at 09:49:24AM +0100, Srinivas Kandagatla wrote: The of_device_id is included unconditionally by of.h header and used in the driver as well. Remove of_match_ptr to fix W=1 compile test warning with !CONFIG_OF: It's better to fix th

Re: [PATCH] KVM: VMX: Explicitly check for hv_remote_flush_tlb when loading pgd()

2020-09-25 Thread Sean Christopherson
On Fri, Sep 25, 2020 at 11:59:00AM +0200, Vitaly Kuznetsov wrote: > Sean Christopherson writes: > > +#if IS_ENABLED(CONFIG_HYPERV) > > enum ept_pointers_status ept_pointers_match; > > spinlock_t ept_pointer_lock; > > +#endif > > Reviewed-by: Vitaly Kuznetsov > > In case ept_pointers_mat

Re: [PATCH v1] Bluetooth: Enforce key size of 16 bytes on FIPS level

2020-09-25 Thread Marcel Holtmann
Hi Archie, > According to the spec Ver 5.2, Vol 3, Part C, Sec 5.2.2.8: > Device in security mode 4 level 4 shall enforce: > 128-bit equivalent strength for link and encryption keys required > using FIPS approved algorithms (E0 not allowed, SAFER+ not allowed, > and P-192 not allowed; encryption k

[PATCH] ARM: dts: cros-ec-keyboard: Add alternate keymap for KEY_LEFTMETA

2020-09-25 Thread Stephen Boyd
On newer keyboards this key is in a different place. Add both options to the keymap so that both new and old keyboards work. Cc: Douglas Anderson Signed-off-by: Stephen Boyd --- arch/arm/boot/dts/cros-ec-keyboard.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/boot/dts/cros-ec

Re: [PATCH v4] cper, apei, mce: Pass x86 CPER through the MCA handling chain

2020-09-25 Thread Borislav Petkov
On Fri, Sep 25, 2020 at 11:19:40AM -0500, Yazen Ghannam wrote: > This patch is checking if an MSR context info structure lines up with > the MCAX register space used on Scalable MCA systems. This register > space is defined in the AMD Processor Programming Reference for various > products. This is

Re: [PATCH 1/2] tracepoints: Add helper to test if tracepoint is enabled in a header

2020-09-25 Thread Steven Rostedt
On Fri, 25 Sep 2020 11:30:06 -0400 (EDT) Mathieu Desnoyers wrote: > > Anyway, I don't see any issues with the current patch set as is > > (besides the documentation fix, which I already updated locally). And > > will add this to my queue for linux-next. > > The only thing I would change in the

Re: [PATCH] net: ethernet: cavium: octeon_mgmt: use phy_start and phy_stop

2020-09-25 Thread Andrew Lunn
On Fri, Sep 25, 2020 at 03:44:39PM +0300, Ivan Khoronzhuk wrote: > To start also "phy state machine", with UP state as it should be, > the phy_start() has to be used, in another case machine even is not > triggered. After this change negotiation is supposed to be triggered > by SM workqueue. > > I

RE: [PATCH v5 08/10] fs/ntfs3: Add Kconfig, Makefile and doc

2020-09-25 Thread Konstantin Komarov
From: Pali Rohár Sent: Monday, September 21, 2020 4:27 PM > To: Konstantin Komarov > Cc: linux-fsde...@vger.kernel.org; v...@zeniv.linux.org.uk; > linux-kernel@vger.kernel.org; dste...@suse.cz; aap...@suse.com; > wi...@infradead.org; rdun...@infradead.org; j...@perches.com; > m...@harmstone.com

Re: [PATCH v2] : Add nitems() and snitems() macros

2020-09-25 Thread Alejandro Colomar
Hello Jonathan, On 2020-09-25 16:48, Jonathan Wakely wrote: > Do you really need to provide snitems? > > Users can use (ptrdiff_t)nitems if needed, can't they? They can, but that adds casts in the code, which makes longer lines that are somewhat harder to read. To avoid that, users may sometimes

Re: [PATCH v13 7/8] x86/vdso: Insert endbr32/endbr64 to vDSO

2020-09-25 Thread Yu, Yu-cheng
On 9/25/2020 9:18 AM, Andy Lutomirski wrote: On Fri, Sep 25, 2020 at 7:58 AM Yu-cheng Yu wrote: From: "H.J. Lu" When Indirect Branch Tracking (IBT) is enabled, vDSO functions may be called indirectly, and must have ENDBR32 or ENDBR64 as the first instruction. The compiler must support -fcf-

[PATCH v12 0/6] IOMMU user API enhancement

2020-09-25 Thread Jacob Pan
IOMMU user API header was introduced to support nested DMA translation and related fault handling. The current UAPI data structures consist of three areas that cover the interactions between host kernel and guest: - fault handling - cache invalidation - bind guest page tables, i.e. guest PASID

[PATCH v12 5/6] iommu/uapi: Handle data and argsz filled by users

2020-09-25 Thread Jacob Pan
IOMMU user APIs are responsible for processing user data. This patch changes the interface such that user pointers can be passed into IOMMU code directly. Separate kernel APIs without user pointers are introduced for in-kernel users of the UAPI functionality. IOMMU UAPI data has a user filled args

[PATCH v12 4/6] iommu/uapi: Rename uapi functions

2020-09-25 Thread Jacob Pan
User APIs such as iommu_sva_unbind_gpasid() may also be used by the kernel. Since we introduced user pointer to the UAPI functions, in-kernel callers cannot share the same APIs. In-kernel callers are also trusted, there is no need to validate the data. We plan to have two flavors of the same API f

[PATCH v12 1/6] docs: IOMMU user API

2020-09-25 Thread Jacob Pan
IOMMU UAPI is newly introduced to support communications between guest virtual IOMMU and host IOMMU. There has been lots of discussions on how it should work with VFIO UAPI and userspace in general. This document is intended to clarify the UAPI design and usage. The mechanics of how future extensi

[PATCH v12 2/6] iommu/uapi: Add argsz for user filled data

2020-09-25 Thread Jacob Pan
As IOMMU UAPI gets extended, user data size may increase. To support backward compatibiliy, this patch introduces a size field to each UAPI data structures. It is *always* the responsibility for the user to fill in the correct size. Padding fields are adjusted to ensure 8 byte alignment. Specific

Re: [PATCH] fs/affs: Fix basic permission bits to actually work

2020-09-25 Thread Max Staudt
On 9/25/20 12:07 PM, John Paul Adrian Glaubitz wrote: > Has there already been any progress on reviewing this? It has already been merged, and the maintainers have been so kind as to backport it to all maintained stable branches. Thanks for your help, everyone! Max

[PATCH v12 6/6] iommu/vt-d: Check UAPI data processed by IOMMU core

2020-09-25 Thread Jacob Pan
IOMMU generic layer already does sanity checks on UAPI data for version match and argsz range based on generic information. This patch adjusts the following data checking responsibilities: - removes the redundant version check from VT-d driver - removes the check for vendor specific data size - ad

[PATCH v12 3/6] iommu/uapi: Use named union for user data

2020-09-25 Thread Jacob Pan
IOMMU UAPI data size is filled by the user space which must be validated by the kernel. To ensure backward compatibility, user data can only be extended by either re-purpose padding bytes or extend the variable sized union at the end. No size change is allowed before the union. Therefore, the minim

Re: [PATCH v13 8/8] x86/vsyscall/64: Fixup Shadow Stack and Indirect Branch Tracking for vsyscall emulation

2020-09-25 Thread Andy Lutomirski
On Fri, Sep 25, 2020 at 7:58 AM Yu-cheng Yu wrote: > > Vsyscall entry points are effectively branch targets. Mark them with > ENDBR64 opcodes. When emulating the RET instruction, unwind shadow stack > and reset IBT state machine. > > Signed-off-by: Yu-cheng Yu > --- > v13: > - Check shadow stac

Re: [v3 1/2] mm: khugepaged: recalculate min_free_kbytes after memory hotplug as expected by khugepaged

2020-09-25 Thread Vijay Balakrishna
On 9/25/2020 12:42 AM, Michal Hocko wrote: On Wed 16-09-20 18:21:48, Vijay Balakrishna wrote: When memory is hotplug added or removed the min_free_kbytes must be recalculated based on what is expected by khugepaged. Currently after hotplug, min_free_kbytes will be set to a lower default and

Re: REGRESSION: 37f4a24c2469: blk-mq: centralise related handling into blk_mq_get_driver_tag

2020-09-25 Thread Shakeel Butt
On Fri, Sep 25, 2020 at 9:19 AM Ming Lei wrote: > > On Fri, Sep 25, 2020 at 03:31:45PM +0800, Ming Lei wrote: > > On Thu, Sep 24, 2020 at 09:13:11PM -0400, Theodore Y. Ts'o wrote: > > > On Thu, Sep 24, 2020 at 10:33:45AM -0400, Theodore Y. Ts'o wrote: > > > > HOWEVER, thanks to a hint from a colle

Re: [RFC PATCH 0/3] KVM: Introduce "VM bugged" concept

2020-09-25 Thread Marc Zyngier
Hi Sean, On Wed, 23 Sep 2020 23:45:27 +0100, Sean Christopherson wrote: > > This series introduces a concept we've discussed a few times in x86 land. > The crux of the problem is that x86 has a few cases where KVM could > theoretically encounter a software or hardware bug deep in a call stack >

[PATCH v13 25/26] x86/cet/shstk: Add arch_prctl functions for shadow stack

2020-09-25 Thread Yu-cheng Yu
arch_prctl(ARCH_X86_CET_STATUS, u64 *args) Get CET feature status. The parameter 'args' is a pointer to a user buffer. The kernel returns the following information: *args = shadow stack/IBT status *(args + 1) = shadow stack base address *(args + 2) = shadow stack size ar

[PATCH v2 0/2] ASoC: qdsp6: fix some warnings when build without CONFIG_OF

2020-09-25 Thread Srinivas Kandagatla
Here are fixes for two warnings types discovered while building qdsp6 drivers without CONFIG_OF and with W=1 One of them was reported by Intel kernel test robot on q6afe-clocks patch, which equally applies to rest of the qdsp6 drivers. changes since v1: - added ifdef CONFIG_OF instead of

[PATCH v2 2/2] ASoC: q6asm: fix kernel doc warnings

2020-09-25 Thread Srinivas Kandagatla
This patch fixes below kernel doc warnings on not describing all the parmeters sound/soc/qcom/qdsp6/q6asm.c:927: warning: Function parameter or member 'stream_id' not described in 'q6asm_open_write' sound/soc/qcom/qdsp6/q6asm.c:927: warning: Function parameter or member 'is_gapless' not describe

[PATCH v2 1/2] ASoC: qdsp6: add ifdef CONFIG_OF around of_device_id

2020-09-25 Thread Srinivas Kandagatla
Add ifdef CONFIG_OF around of_device_id table to fix below W=1 compile test warning with !CONFIG_OF: sound/soc/qcom/qdsp6/q6afe-clocks.c:254:34: warning: unused variable 'q6afe_clock_device_id' [-Wunused-const-variable] Fix this warning for across all qdsp6 drivers. Reported-by: kernel test rob

Re: [PATCH v3] Bluetooth: Check for encryption key size on connect

2020-09-25 Thread Marcel Holtmann
Hi Archie, > When receiving connection, we only check whether the link has been > encrypted, but not the encryption key size of the link. > > This patch adds check for encryption key size, and reject L2CAP > connection which size is below the specified threshold (default 7) > with security block.

[PATCH] sched,fair: fix the spelling of enqueued

2020-09-25 Thread Hui Su
just fix the spelling of enqueued. Signed-off-by: Hui Su --- kernel/sched/fair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 1a68a0536add..fadee2b05df3 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -753,7 +75

Re: [f2fs-dev] KMSAN: uninit-value in f2fs_lookup

2020-09-25 Thread Eric Biggers
On Fri, Sep 25, 2020 at 05:06:33PM +0800, Chao Yu wrote: > Hi, > > I don't see any problem here, thanks for your report. :) > > Thanks, What about if max_depth == 0 in __f2fs_find_entry()? Then __f2fs_find_entry() would return NULL without initializing *res_page. A fix could be: diff --git a/

Re: [PATCH v4 1/2] ovl: propagate ovl_fs to ovl_decode_real_fh and ovl_encode_real_fh

2020-09-25 Thread Amir Goldstein
On Fri, Sep 25, 2020 at 11:35 AM Pavel Tikhomirov wrote: > > This will be used in next patch to be able to change uuid checks and > add uuid nullification based on ofs->config.index for a new "uuid=off" > mode. > > CC: Amir Goldstein > CC: Vivek Goyal > CC: Miklos Szeredi > CC: linux-unio...@vg

RE: [PATCH v3 04/10] fs/ntfs3: Add file operations and implementation

2020-09-25 Thread Konstantin Komarov
From: Pali Rohár Sent: Monday, September 21, 2020 4:37 PM > > On Friday 11 September 2020 16:52:50 Konstantin Komarov wrote: > > From: Pali Rohár > > Sent: Friday, September 4, 2020 2:51 PM > > > > > > Hello Konstantin! > > > > > > On Friday 28 August 2020 07:39:32 Konstantin Komarov wrote: > >

Re: [PATCH 3/9] sched/hotplug: Ensure only per-cpu kthreads run during hotplug

2020-09-25 Thread Dietmar Eggemann
On 21/09/2020 18:36, Peter Zijlstra wrote: [...] > This replaces the unlikely(rq->balance_callbacks) test at the tail of > context_switch with an unlikely(rq->balance_work), the fast path is While looking for why BALANCE_WORK is needed: Shouldn't this be unlikely(rq->balance_callback) and unlik

Re: [PATCH 4/5] PCI: only return true when dev io state is really changed

2020-09-25 Thread Andy Shevchenko
On Thu, Sep 24, 2020 at 10:34:22PM -0400, Ethan Zhao wrote: > When uncorrectable error happens, AER driver and DPC driver interrupt > handlers likely call >pcie_do_recovery()->pci_walk_bus()->report_frozen_detected() with > pci_channel_io_frozen the same time. Call chains are better to read if

Re: [PATCH v8 1/8] KVM: x86: Return -ENOENT on unimplemented MSRs

2020-09-25 Thread Jim Mattson
On Fri, Sep 25, 2020 at 7:34 AM Alexander Graf wrote: > > When we find an MSR that we can not handle, bubble up that error code as > MSR error return code. Follow up patches will use that to expose the fact > that an MSR is not handled by KVM to user space. > > Suggested-by: Aaron Lewis > Signed-

Re: [PATCH 1/5] PCI: define a function to check and wait till port finish DPC handling

2020-09-25 Thread Andy Shevchenko
On Thu, Sep 24, 2020 at 10:34:19PM -0400, Ethan Zhao wrote: > Once root port DPC capability is enabled and triggered, at the beginning > of DPC is triggered, the DPC status bits are set by hardware and then > sends DPC/DLLSC/PDC interrupts to OS DPC and pciehp drivers, it will > take the port and s

Re: [PATCH v2 seccomp 2/6] asm/syscall.h: Add syscall_arches[] array

2020-09-25 Thread YiFei Zhu
On Thu, Sep 24, 2020 at 10:28 PM YiFei Zhu wrote: > Ah. Makes sense. > > > Ironicailly, that's the only place I actually know for sure where people > > using x32 because it shows measurable (10%) speed-up for builders: > > https://lore.kernel.org/lkml/caoesgmgu1i3p7xmzucetj63t-st_jh+bfahy-k6lhgqnr

Re: [PATCH 3/5] PCI/ERR: get device before call device driver to avoid null pointer reference

2020-09-25 Thread Andy Shevchenko
On Thu, Sep 24, 2020 at 10:34:21PM -0400, Ethan Zhao wrote: > During DPC error injection test we found there is race condition between > pciehp and DPC driver, null pointer reference caused panic as following null -> NULL > > # setpci -s 64:02.0 0x196.w=000a > // 64:02.0 is rootport has DPC c

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