Re: [PATCH 3/4] RISC-V: Fix L1_CACHE_BYTES for RV32

2021-01-14 Thread Palmer Dabbelt
On Thu, 14 Jan 2021 10:33:01 PST (-0800), ati...@atishpatra.org wrote: On Wed, Jan 13, 2021 at 9:10 PM Palmer Dabbelt wrote: On Thu, 07 Jan 2021 01:26:51 PST (-0800), Atish Patra wrote: > SMP_CACHE_BYTES/L1_CACHE_BYTES should be defined as 32 instead of > 64 for RV32. Otherwise, there will be

drivers/media/test-drivers/vidtv/vidtv_psi.c:1778:32: warning: taking address of packed member 'bitfield' of class or structure 'vidtv_psi_table_eit_event' may result in an unaligned pointer value

2021-01-14 Thread kernel test robot
-20210114 (attached as .config) compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 68ff52ffead2ba25cca442778ab19286000daad7) reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x

[PATCH 00/21] objtool: vmlinux.o and CLANG LTO support

2021-01-14 Thread Josh Poimboeuf
Add support for proper vmlinux.o validation, which will be needed for Sami's upcoming x86 LTO set. (And vmlinux validation is the future for objtool anyway, for other reasons.) This isn't 100% done -- most notably, crypto still needs to be supported -- but I think this gets us most of the way

[PATCH 19/21] x86/power: Convert indirect jumps to retpolines

2021-01-14 Thread Josh Poimboeuf
It's kernel policy to not have (unannotated) indirect jumps because of Spectre v2. These are probably harmless, but better safe than sorry. Convert them to retpolines. Cc: "Rafael J. Wysocki" Cc: Pavel Machek Signed-off-by: Josh Poimboeuf --- arch/x86/power/hibernate_asm_64.S | 5 +++-- 1

[PATCH 18/21] x86/acpi: Support objtool validation in wakeup_64.S

2021-01-14 Thread Josh Poimboeuf
The OBJECT_FILES_NON_STANDARD annotation is used to tell objtool to ignore a file. File-level ignores won't work when validating vmlinux.o. Instead, tell objtool to ignore do_suspend_lowlevel() directly with the STACK_FRAME_NON_STANDARD annotation. Cc: "Rafael J. Wysocki" Cc: Len Brown Cc:

[PATCH 21/21] x86/power: Support objtool validation in hibernate_asm_64.S

2021-01-14 Thread Josh Poimboeuf
The OBJECT_FILES_NON_STANDARD annotation is used to tell objtool to ignore a file. File-level ignores won't work when validating vmlinux.o. Instead, convert restore_image() and core_restore_code() to be ELF functions. Their code is conventional enough for objtool to be able to understand them.

[PATCH 20/21] x86/power: Move restore_registers() to top of the file

2021-01-14 Thread Josh Poimboeuf
Because restore_registers() is page-aligned, the assembler inexplicably adds an unreachable jump from after the end of the previous function to the beginning of restore_registers(). That confuses objtool, understandably. It also creates significant text fragmentation. As a result, most of the

[PATCH 17/21] x86/acpi: Convert indirect jump to retpoline

2021-01-14 Thread Josh Poimboeuf
It's kernel policy to not have (unannotated) indirect jumps because of Spectre v2. This one's probably harmless, but better safe than sorry. Convert it to a retpoline. Cc: "Rafael J. Wysocki" Cc: Len Brown Cc: Pavel Machek Signed-off-by: Josh Poimboeuf --- arch/x86/kernel/acpi/wakeup_64.S |

[PATCH 15/21] x86/xen/pvh: Convert indirect jump to retpoline

2021-01-14 Thread Josh Poimboeuf
It's kernel policy to not have (unannotated) indirect jumps because of Spectre v2. This one's probably harmless, but better safe than sorry. Convert it to a retpoline. Cc: Boris Ostrovsky Cc: Juergen Gross Signed-off-by: Josh Poimboeuf --- arch/x86/platform/pvh/head.S | 3 ++- 1 file

[PATCH 16/21] x86/ftrace: Support objtool vmlinux.o validation in ftrace_64.S

2021-01-14 Thread Josh Poimboeuf
With objtool vmlinux.o validation of return_to_handler(), now that objtool has visibility inside the retpoline, jumping from EMPTY state to a proper function state results in a stack state mismatch. return_to_handler() is actually quite normal despite the underlying magic. Just annotate it as a

[PATCH 14/21] x86/xen: Support objtool vmlinux.o validation in xen-head.S

2021-01-14 Thread Josh Poimboeuf
The Xen hypercall page is filled with zeros, causing objtool to fall through all the empty hypercall functions until it reaches a real function, resulting in a stack state mismatch. The build-time contents of the hypercall page don't matter, since it gets mapped to the hypervisor. Make it more

[PATCH 02/21] objtool: Fix error handling for STD/CLD warnings

2021-01-14 Thread Josh Poimboeuf
Actually return an error (and display a backtrace, if requested) for directional bit warnings. Fixes: 2f0f9e9ad7b3 ("objtool: Add Direction Flag validation") Signed-off-by: Josh Poimboeuf --- tools/objtool/check.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git

[PATCH 13/21] x86/xen: Support objtool validation in xen-asm.S

2021-01-14 Thread Josh Poimboeuf
The OBJECT_FILES_NON_STANDARD annotation is used to tell objtool to ignore a file. File-level ignores won't work when validating vmlinux.o. Tweak the ELF metadata and unwind hints to allow objtool to follow the code. Cc: Boris Ostrovsky Cc: Juergen Gross Signed-off-by: Josh Poimboeuf ---

[PATCH 12/21] objtool: Add CONFIG_CFI_CLANG support

2021-01-14 Thread Josh Poimboeuf
The upcoming CONFIG_CFI_CLANG support uses -fsanitize=cfi, the non-canonical version of which hijacks function entry by changing function relocation references to point to an intermediary jump table. For example: Relocation section '.rela.discard.func_stack_frame_non_standard' at offset

[PATCH 11/21] objtool: Move unsuffixed symbol conversion to a helper function

2021-01-14 Thread Josh Poimboeuf
This logic will also be needed for the CONFIG_CFI_CLANG support. Signed-off-by: Josh Poimboeuf --- tools/objtool/elf.c | 59 - 1 file changed, 37 insertions(+), 22 deletions(-) diff --git a/tools/objtool/elf.c b/tools/objtool/elf.c index

[PATCH 09/21] objtool: Combine UNWIND_HINT_RET_OFFSET and UNWIND_HINT_FUNC

2021-01-14 Thread Josh Poimboeuf
The ORC metadata generated for UNWIND_HINT_FUNC isn't actually very func-like. With certain usages it can cause stack state mismatches because it doesn't set the return address (CFI_RA). Also, users of UNWIND_HINT_RET_OFFSET no longer need to set a custom return stack offset. Instead they just

[PATCH 10/21] objtool: Add xen_start_kernel() to noreturn list

2021-01-14 Thread Josh Poimboeuf
xen_start_kernel() doesn't return. Annotate it as such so objtool can follow the code flow. Signed-off-by: Josh Poimboeuf --- tools/objtool/check.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/objtool/check.c b/tools/objtool/check.c index 6636f4fd694a..a430eaacd7aa 100644 ---

[PATCH 08/21] objtool: Add asm version of STACK_FRAME_NON_STANDARD

2021-01-14 Thread Josh Poimboeuf
To be used for adding asm functions to the ignore list. The "aw" is needed to help the ELF section metadata match GCC-created sections. Otherwise the linker creates duplicate sections instead of combining them. Signed-off-by: Josh Poimboeuf --- include/linux/objtool.h | 8

[PATCH 07/21] objtool: Assume only ELF functions do sibling calls

2021-01-14 Thread Josh Poimboeuf
There's an inconsistency in how sibling calls are detected in non-function asm code, depending on the scope of the object. If the target code is external to the object, objtool considers it a sibling call. If the target code is internal but not a function, objtool *doesn't* consider it a sibling

Re: [RFC PATCH 4/8] mm: Separate fault info out of 'struct vm_fault'

2021-01-14 Thread Will Deacon
On Thu, Jan 14, 2021 at 11:09:01AM -0800, Linus Torvalds wrote: > On Thu, Jan 14, 2021 at 11:00 AM Will Deacon wrote: > > > > I tried that initially, but I found that I had to make all of the > > members const to get it to work, at which point the anonymous struct > > wasn't really adding

[PATCH 06/21] x86/ftrace: Add UNWIND_HINT_FUNC annotation for ftrace_stub

2021-01-14 Thread Josh Poimboeuf
Prevent an unreachable objtool warning after the sibling call detection gets improved. ftrace_stub() is basically a function, annotate it as such. Cc: Steven Rostedt Signed-off-by: Josh Poimboeuf --- arch/x86/kernel/ftrace_64.S | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 04/21] objtool: Fix ".cold" section suffix check for newer versions of GCC

2021-01-14 Thread Josh Poimboeuf
With my version of GCC 9.3.1 the ".cold" subfunctions no longer have a numbered suffix, so the trailing period is no longer there. Presumably this doesn't yet trigger a user-visible bug since most of the subfunction detection logic is duplicated. I only found it when testing vmlinux.o

[PATCH 05/21] objtool: Support retpoline jump detection for vmlinux.o

2021-01-14 Thread Josh Poimboeuf
Objtool converts direct retpoline jumps to type INSN_JUMP_DYNAMIC, since that's what they are semantically. That conversion doesn't work in vmlinux.o validation because the indirect thunk function is present in the object, so the intra-object jump check succeeds before the retpoline jump check

[PATCH 03/21] objtool: Fix retpoline detection in asm code

2021-01-14 Thread Josh Poimboeuf
The JMP_NOSPEC macro branches to __x86_retpoline_*() rather than the __x86_indirect_thunk_*() wrappers used by C code. Detect jumps to __x86_retpoline_*() as retpoline dynamic jumps. Presumably this doesn't trigger a user-visible bug. I only found it when testing vmlinux.o validation. Fixes:

[PATCH 01/21] objtool: Fix seg fault in BT_FUNC() with fake jump

2021-01-14 Thread Josh Poimboeuf
Objtool appends a temporary fake jump at the end of alternative replacement instructions. If the replacement code is empty -- resulting in patched nops -- the fake jump doesn't have a section. When running objtool with '--backtrace', the fake jump's missing section can cause BT_FUNC() to trigger

linux-next: Fixes tag needs some work in the battery tree

2021-01-14 Thread Stephen Rothwell
Hi all, In commit e1cc2d7d3868 ("power: supply: bq256xx: Fix BQ256XX_NUM_WD_VAL and bq256xx_watchdog_time[] overrun") Fixes tag Fixes: 32e4978bb92 ("power: supply: bq256xx: Introduce the BQ256XX charger driver") has these problem(s): - SHA1 should be at least 12 digits long Probably

Re: [PATCH] driver core: Extend device_is_dependent()

2021-01-14 Thread Rafael J. Wysocki
On Thu, Jan 14, 2021 at 8:32 PM Saravana Kannan wrote: > > On Thu, Jan 14, 2021 at 10:41 AM Rafael J. Wysocki wrote: > > > > From: Rafael J. Wysocki > > > > When adding a new device link, device_is_dependent() is used to > > check whether or not the prospective supplier device does not > >

[PATCH v3 13/15] kasan: add proper page allocator tests

2021-01-14 Thread Andrey Konovalov
The currently existing page allocator tests rely on kmalloc fallback with large sizes that is only present for SLUB. Add proper tests that use alloc/free_pages(). Link: https://linux-review.googlesource.com/id/Ia173d5a1b215fe6b2548d814ef0f4433cf983570 Reviewed-by: Marco Elver Reviewed-by:

[PATCH v3 12/15] kasan: fix bug detection via ksize for HW_TAGS mode

2021-01-14 Thread Andrey Konovalov
The currently existing kasan_check_read/write() annotations are intended to be used for kernel modules that have KASAN compiler instrumentation disabled. Thus, they are only relevant for the software KASAN modes that rely on compiler instrumentation. However there's another use case for these

[PATCH v3 11/15] kasan: move _RET_IP_ to inline wrappers

2021-01-14 Thread Andrey Konovalov
Generic mm functions that call KASAN annotations that might report a bug pass _RET_IP_ to them as an argument. This allows KASAN to include the name of the function that called the mm function in its report's header. Now that KASAN has inline wrappers for all of its annotations, move _RET_IP_ to

[PATCH v3 15/15] kasan: don't run tests when KASAN is not enabled

2021-01-14 Thread Andrey Konovalov
Don't run KASAN tests when it's disabled with kasan.mode=off to avoid corrupting kernel memory. Link: https://linux-review.googlesource.com/id/I6447af436a69a94bfc35477f6bf4e2122948355e Signed-off-by: Andrey Konovalov --- lib/test_kasan.c | 5 + 1 file changed, 5 insertions(+) diff --git

[PATCH v3 14/15] kasan: add a test for kmem_cache_alloc/free_bulk

2021-01-14 Thread Andrey Konovalov
Add a test for kmem_cache_alloc/free_bulk to make sure there are no false-positives when these functions are used. Link: https://linux-review.googlesource.com/id/I2a8bf797aecf81baeac61380c567308f319e263d Signed-off-by: Andrey Konovalov --- lib/test_kasan.c | 38

[PATCH v3 09/15] kasan: adapt kmalloc_uaf2 test to HW_TAGS mode

2021-01-14 Thread Andrey Konovalov
In the kmalloc_uaf2() test, the pointers to the two allocated memory blocks might happen to be the same, and the test will fail. With the software tag-based mode, the probability of the that is 1/254, so it's hard to observe the failure. For the hardware tag-based mode though, the probablity is

[PATCH v3 10/15] kasan: fix memory corruption in kasan_bitops_tags test

2021-01-14 Thread Andrey Konovalov
Since the hardware tag-based KASAN mode might not have a redzone that comes after an allocated object (when kasan.mode=prod is enabled), the kasan_bitops_tags() test ends up corrupting the next object in memory. Change the test so it always accesses the redzone that lies within the allocated

[PATCH v3 07/15] kasan: rename CONFIG_TEST_KASAN_MODULE

2021-01-14 Thread Andrey Konovalov
Rename CONFIG_TEST_KASAN_MODULE to CONFIG_KASAN_MODULE_TEST. This naming is more consistent with the existing CONFIG_KASAN_KUNIT_TEST. Link: https://linux-review.googlesource.com/id/Id347dfa5fe8788b7a1a189863e039f409da0ae5f Reviewed-by: Marco Elver Reviewed-by: Alexander Potapenko

[PATCH v3 08/15] kasan: add compiler barriers to KUNIT_EXPECT_KASAN_FAIL

2021-01-14 Thread Andrey Konovalov
It might not be obvious to the compiler that the expression must be executed between writing and reading to fail_data. In this case, the compiler might reorder or optimize away some of the accesses, and the tests will fail. Add compiler barriers around the expression in KUNIT_EXPECT_KASAN_FAIL

[PATCH v3 02/15] kasan: clarify HW_TAGS impact on TBI

2021-01-14 Thread Andrey Konovalov
Mention in the documentation that enabling CONFIG_KASAN_HW_TAGS always results in in-kernel TBI (Top Byte Ignore) being enabled. Also do a few minor documentation cleanups. Link: https://linux-review.googlesource.com/id/Iba2a6697e3c6304cb53f89ec61dedc77fa29e3ae Reviewed-by: Marco Elver

[PATCH v3 06/15] kasan, arm64: allow using KUnit tests with HW_TAGS mode

2021-01-14 Thread Andrey Konovalov
On a high level, this patch allows running KUnit KASAN tests with the hardware tag-based KASAN mode. Internally, this change reenables tag checking at the end of each KASAN test that triggers a tag fault and leads to tag checking being disabled. With this patch KASAN tests are still failing for

[PATCH v3 05/15] kasan: add match-all tag tests

2021-01-14 Thread Andrey Konovalov
Add 3 new tests for tag-based KASAN modes: 1. Check that match-all pointer tag is not assigned randomly. 2. Check that 0xff works as a match-all pointer tag. 3. Check that there are no match-all memory tags. Note, that test #3 causes a significant number (255) of KASAN reports to be printed

[PATCH v3 04/15] kasan: add macros to simplify checking test constraints

2021-01-14 Thread Andrey Konovalov
Some KASAN tests require specific kernel configs to be enabled. Instead of copy-pasting the checks for these configs add a few helper macros and use them. Link: https://linux-review.googlesource.com/id/I237484a7fddfedf4a4aae9cc61ecbcdbe85a0a63 Suggested-by: Alexander Potapenko Reviewed-by:

[PATCH v3 01/15] kasan: prefix global functions with kasan_

2021-01-14 Thread Andrey Konovalov
There's a number of internal KASAN functions that are used across multiple source code files and therefore aren't marked as static inline. To avoid littering the kernel function names list with generic function names, prefix all such KASAN functions with kasan_. As a part of this change: -

[PATCH v3 03/15] kasan: clean up comments in tests

2021-01-14 Thread Andrey Konovalov
Clarify and update comments in KASAN tests. Link: https://linux-review.googlesource.com/id/I6c816c51fa1e0eb7aa3dead6bda1f339d2af46c8 Reviewed-by: Marco Elver Signed-off-by: Andrey Konovalov --- lib/test_kasan.c| 59 + lib/test_kasan_module.c |

[PATCH v3 00/15] kasan: HW_TAGS tests support and fixes

2021-01-14 Thread Andrey Konovalov
This patchset adds support for running KASAN-KUnit tests with the hardware tag-based mode and also contains a few fixes. Changes v2->v3: - Don't call kmalloc(0) when generating random size. - Use ARRAY_SIZE() in kmem_cache_bulk_alloc() test. - Print error message when tests are being ran with

[PATCH v2 1/2] kasan, mm: fix conflicts with init_on_alloc/free

2021-01-14 Thread Andrey Konovalov
A few places where SLUB accesses object's data or metadata were missed in a previous patch. This leads to false positives with hardware tag-based KASAN when bulk allocations are used with init_on_alloc/free. Fix the false-positives by resetting pointer tags during these accesses. (The

Re: objtool/ORC generation for noreturn functions

2021-01-14 Thread Hack, Vanessa
Am 2021-01-13 19:41, schrieb Josh Poimboeuf: On Wed, Jan 13, 2021 at 11:44:22AM +0100, vanessa.h...@fau.de wrote: Hi, I am currently writing my final thesis at university on the topic of stack unwinding. My goal is to implement and evaluate stack unwinders for research operating

[PATCH v2 0/2] kasan: fixes for 5.11-rc

2021-01-14 Thread Andrey Konovalov
Changes v1->v2: - Update changelog of patch #1. Andrey Konovalov (2): kasan, mm: fix conflicts with init_on_alloc/free kasan, arm64: fix pointer tags in KASAN reports arch/arm64/mm/fault.c | 2 ++ mm/slub.c | 7 --- 2 files changed, 6 insertions(+), 3 deletions(-) --

[PATCH v2 2/2] kasan, arm64: fix pointer tags in KASAN reports

2021-01-14 Thread Andrey Konovalov
As of the "arm64: expose FAR_EL1 tag bits in siginfo" patch, the address that is passed to report_tag_fault has pointer tags in the format of 0x0X, while KASAN uses 0xFX format (note the difference in the top 4 bits). Fix up the pointer tag before calling kasan_report. Link:

Re: [PATCH] driver core: Extend device_is_dependent()

2021-01-14 Thread Saravana Kannan
On Thu, Jan 14, 2021 at 10:41 AM Rafael J. Wysocki wrote: > > From: Rafael J. Wysocki > > When adding a new device link, device_is_dependent() is used to > check whether or not the prospective supplier device does not > depend on the prospective consumer one to avoid adding loops > to the graph

Re: [PATCH v4 1/3] dt-bindings: hwmon: Add TI TPS23861 bindings

2021-01-14 Thread Rob Herring
On Mon, Jan 11, 2021 at 02:57:06PM +0100, Robert Marko wrote: > Document bindings for the Texas Instruments TPS23861 driver. > > Signed-off-by: Robert Marko > Cc: Luka Perkov > --- > Changes in v4: > * Correct shunt binding > > .../bindings/hwmon/ti,tps23861.yaml | 52

Re: [PATCH v2 1/2] dt-bindings: phy: qcom,qmp: Add SDX55 USB PHY binding

2021-01-14 Thread Rob Herring
On Mon, 11 Jan 2021 17:00:09 +0530, Manivannan Sadhasivam wrote: > Add devicetree YAML binding for Qualcomm QMP Super Speed (SS) PHY found > in SDX55. > > Signed-off-by: Manivannan Sadhasivam > --- > .../devicetree/bindings/phy/qcom,qmp-phy.yaml | 27 +++ > 1 file changed, 27

Re: [PATCH] selinux: include a consumer of the new IMA critical data hook

2021-01-14 Thread Paul Moore
On Thu, Jan 14, 2021 at 2:15 PM Lakshmi Ramasubramanian wrote: > > SELinux stores the active policy in memory, so the changes to this data > at runtime would have an impact on the security guarantees provided > by SELinux. Measuring in-memory SELinux policy through IMA subsystem > provides a

Re: [PATCH v6 06/33] of/device: Move dma_range_map before of_iommu_configure

2021-01-14 Thread Rob Herring
On Mon, Jan 11, 2021 at 07:18:47PM +0800, Yong Wu wrote: > "dev->dma_range_map" contains the devices' dma_ranges information, > This patch moves dma_range_map before of_iommu_configure. The iommu > driver may need to know the dma_address requirements of its iommu > consumer devices. > > CC: Rob

Re: [PATCH] x86/mm/mtrr: remove definition of DEBUG

2021-01-14 Thread Tom Rix
On 1/14/21 10:46 AM, Borislav Petkov wrote: > On Thu, Jan 14, 2021 at 08:27:43AM -0800, t...@redhat.com wrote: >> From: Tom Rix >> >> Defining DEBUG should only be done in development. >> So remove DEBUG. >> >> Signed-off-by: Tom Rix >> --- >> arch/x86/kernel/cpu/mtrr/generic.c | 1 - >> 1

linux-next: Signed-off-by missing for commit in the arm64-fixes tree

2021-01-14 Thread Stephen Rothwell
Hi all, Commit b5639879902a ("arm64: syscall: include prototype for EL0 SVC functions") is missing a Signed-off-by from its author. -- Cheers, Stephen Rothwell pgpI3bMkgV9wJ.pgp Description: OpenPGP digital signature

Re: [RFC PATCH v3 14/16] cxl/mem: Use CEL for enabling commands

2021-01-14 Thread Jonathan Cameron
On Thu, 14 Jan 2021 11:04:25 -0800 Ben Widawsky wrote: > On 21-01-14 18:32:17, Jonathan Cameron wrote: > > On Thu, 14 Jan 2021 10:13:40 -0800 > > Ben Widawsky wrote: > > > > > On 21-01-14 18:02:11, Jonathan Cameron wrote: > > > > On Mon, 11 Jan 2021 14:51:19 -0800 > > > > Ben Widawsky

arch/arm/mach-omap2/board-generic.c:36:28: warning: no previous prototype for 'omap_init_time_of'

2021-01-14 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 65f0d2414b7079556fbbcc070b3d1c9f9587606d commit: e69b4e1a7577c169e9f52edf977401734a6a29eb ARM: OMAP2+: Add omap_init_time_of() date: 8 months ago config: arm-randconfig-r005-20210114 (attached as .config

Re: [Bug 211189] New: vgaarb overrides boot device unexpectedly with Intel and discrete AMDGPU

2021-01-14 Thread Bjorn Helgaas
[cc'd efifb and vgaarb maintainers on bugzilla, but not sure whether people pay attention to that] On Thu, Jan 14, 2021 at 10:42:53AM +, bugzilla-dae...@bugzilla.kernel.org wrote: > https://bugzilla.kernel.org/show_bug.cgi?id=211189 > > Bug ID: 211189 >Summary:

Re: [PATCH v10 8/8] selinux: include a consumer of the new IMA critical data hook

2021-01-14 Thread Lakshmi Ramasubramanian
On 1/14/21 9:48 AM, Lakshmi Ramasubramanian wrote: On 1/14/21 8:50 AM, Mimi Zohar wrote: On Thu, 2021-01-14 at 11:44 -0500, Mimi Zohar wrote: [Cc'ing Sasha] Hi Lakshmi, On Thu, 2021-01-14 at 08:22 -0800, Lakshmi Ramasubramanian wrote: On 1/13/21 6:49 PM, Mimi Zohar wrote: Lakshmi is

Re: [PATCH] fs/proc: Expose RSEQ configuration

2021-01-14 Thread Piotr Figiel
On Thu, Jan 14, 2021 at 12:32:30AM +0300, Alexey Dobriyan wrote: > On Wed, Jan 13, 2021 at 06:41:27PM +0100, Piotr Figiel wrote: > > For userspace checkpoint and restore (C/R) some way of getting process > > state containing RSEQ configuration is needed. > > + seq_printf(m, "0x%llx 0x%x\n",

Re: [PATCH] mm/hugetlb: Use helper huge_page_order and pages_per_huge_page

2021-01-14 Thread Mike Kravetz
On 1/14/21 3:44 AM, Miaohe Lin wrote: > Since commit a5516438959d ("hugetlb: modular state for hugetlb page size"), > we can use huge_page_order to access hstate->order and pages_per_huge_page > to fetch the pages per huge page. But gather_bootmem_prealloc() forgot to > use it. > > Signed-off-by:

Re: [PATCH v3 1/2] arm64: dts: sdm845: add oneplus6/6t devices

2021-01-14 Thread Konrad Dybcio
Hi! > dtb-$(CONFIG_ARCH_QCOM) += sdm845-db845c.dtb > dtb-$(CONFIG_ARCH_QCOM) += sdm845-mtp.dtb > dtb-$(CONFIG_ARCH_QCOM) += sdm845-xiaomi-beryllium.dtb > +dtb-$(CONFIG_ARCH_QCOM) += sdm845-oneplus-enchilada.dtb > +dtb-$(CONFIG_ARCH_QCOM) += sdm845-oneplus-fajita.dtb >

Re: [PATCH v1 (RFC)] docs: discourage users from using bugzilla.kernel.org

2021-01-14 Thread Konstantin Ryabitsev
On Wed, Jan 13, 2021 at 01:17:10PM +0200, Jani Nikula wrote: > >> Well, that said, a lot of stuff sent to the _proper_ mailing lists also > >> never > >> receives a response > > > > Good point. > > There's a school of thought that this is actually a feature. If there's > no attention, the

[PATCH v2 2/3] bus: mhi: core: Download AMSS image from appropriate function

2021-01-14 Thread Bhaumik Bhatt
During full boot chain firmware download, the PM state worker downloads the AMSS image after waiting for the SBL execution environment change in PBL mode itself. Since getting rid of the firmware load worker thread, this design needs to change and MHI host must download the AMSS image from the SBL

Re: [PATCH v2 02/14] KVM: SVM: Free sev_asid_bitmap during init if SEV setup fails

2021-01-14 Thread Sean Christopherson
On Thu, Jan 14, 2021, Tom Lendacky wrote: > On 1/14/21 11:12 AM, Sean Christopherson wrote: > > On Thu, Jan 14, 2021, Tom Lendacky wrote: > > > On 1/13/21 6:36 PM, Sean Christopherson wrote: > > > > Free sev_asid_bitmap if the reclaim bitmap allocation fails, othwerise > > > > KVM will

[PATCH v2 1/3] bus: mhi: core: Clear devices when moving execution environments

2021-01-14 Thread Bhaumik Bhatt
When moving from SBL to mission mode execution environment, there is no remove callback notification to MHI client drivers which operate on SBL mode only. Client driver devices are being created in SBL or AMSS(mission mode) and only destroyed after power down or SYS_ERROR. If there exist any

[PATCH v2 3/3] bus: mhi: core: Process execution environment changes serially

2021-01-14 Thread Bhaumik Bhatt
In current design, whenever the BHI interrupt is fired, the execution environment is updated. This can cause race conditions and impede any ongoing power up/down processing. For example, if a power down is in progress and the host has updated the execution environment to a local "disabled" state,

[PATCH v2 0/3] Serialize execution environment changes for MHI

2021-01-14 Thread Bhaumik Bhatt
v2: -Add patch to clear devices when moving execution environments During full boot chain firmware download, the PM state worker downloads the AMSS image after waiting for the SBL execution environment change in PBL mode itself. Since getting rid of the firmware load worker thread, this design

Re: perf tools build broken for RISCV 32 bit

2021-01-14 Thread Arnd Bergmann
On Thu, Jan 14, 2021 at 7:38 PM Emiliano Ingrassia wrote: > > Hi, > > When building perf for RISCV 32 bit (v5.10.7) I got the following > > | In file included from bench/futex-hash.c:29: > | bench/futex.h: In function ‘futex_wait’: > | bench/futex.h:37:10: error: ‘SYS_futex’ undeclared (first use

Re: [PATCH] mm/hugetlb: avoid unnecessary hugetlb_acct_memory() call

2021-01-14 Thread Mike Kravetz
On 1/14/21 4:32 AM, David Hildenbrand wrote: > On 14.01.21 12:31, Miaohe Lin wrote: >> When gbl_reserve is 0, hugetlb_acct_memory() will do nothing except holding >> and releasing hugetlb_lock. > > So, what's the deal then? Adding more code? > > If this is a performance improvement, we should

[PATCH] selinux: include a consumer of the new IMA critical data hook

2021-01-14 Thread Lakshmi Ramasubramanian
SELinux stores the active policy in memory, so the changes to this data at runtime would have an impact on the security guarantees provided by SELinux. Measuring in-memory SELinux policy through IMA subsystem provides a secure way for the attestation service to remotely validate the policy

Re: [PATCH v4 3/5] dt-bindings: mxsfb: Add interconnect bindings for LCDIF path

2021-01-14 Thread Rob Herring
On Mon, Jan 11, 2021 at 09:22:40AM +0100, Martin Kepplinger wrote: > Add optional interconnect properties for the dram path requests. > > Signed-off-by: Martin Kepplinger > --- > Documentation/devicetree/bindings/display/mxsfb.txt | 6 ++ > 1 file changed, 6 insertions(+) Looks fine, but I

Re: [PATCH v2 1/2] dt-bindings: arm: fsl: add Kontron sl28 variant 1

2021-01-14 Thread Rob Herring
On Mon, 11 Jan 2021 09:21:33 +0100, Michael Walle wrote: > Add the a new variant for the Kontron SMARC-sAL28 board. > > Signed-off-by: Michael Walle > --- > changes since v1: > - none > > Documentation/devicetree/bindings/arm/fsl.yaml | 3 +++ > 1 file changed, 3 insertions(+) > Acked-by:

Re: [PATCH v2 6/6] iio:pressure:ms5637: add ms5803 support

2021-01-14 Thread Rob Herring
On Sun, 10 Jan 2021 00:11:48 +0100, Alexandre Belloni wrote: > The ms5803 is very similar to the ms5805 but has less resolution options > and has the 128bit PROM layout. > > Signed-off-by: Alexandre Belloni > --- > Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++ >

Re: [PATCH v3, 01/15] dt-bindings: mediatek: add description for postmask

2021-01-14 Thread Rob Herring
On Mon, 11 Jan 2021 15:43:37 +0800, Yongqiang Niu wrote: > add description for postmask > postmask is used control round corner for display frame > > Signed-off-by: Yongqiang Niu > --- > Documentation/devicetree/bindings/display/mediatek/mediatek,disp.txt | 1 + > 1 file changed, 1 insertion(+)

Re: [RFC PATCH 4/8] mm: Separate fault info out of 'struct vm_fault'

2021-01-14 Thread Linus Torvalds
On Thu, Jan 14, 2021 at 11:00 AM Will Deacon wrote: > > I tried that initially, but I found that I had to make all of the > members const to get it to work, at which point the anonymous struct > wasn't really adding anything. Did I just botch the syntax? I'm not sure what you tried. But this

Re: [PATCH 2/3] dt-bindings: arm: rockchip: Add Radxa ROCK Pi E

2021-01-14 Thread Rob Herring
On Sun, 10 Jan 2021 11:58:45 +0800, Chen-Yu Tsai wrote: > From: Chen-Yu Tsai > > Radxa ROCK Pi E is a router oriented SBC based on Rockchip's RK3328 SoC. > As the official wiki page puts it, "E for Ethernets". > > It features the RK3328 SoC, gigabit and fast Ethernet RJ45 ports, both > directly

Re: [PATCH v3 00/17] KVM: x86/pmu: Add support to enable Guest PEBS via DS

2021-01-14 Thread Sean Christopherson
On Mon, Jan 04, 2021, Like Xu wrote: > 2) Slow path (part 3, patch 0012-0017) > > This is when the host assigned physical PMC has a different index > from the virtual PMC (e.g. using physical PMC1 to emulate virtual PMC0) > In this case, KVM needs to rewrite the PEBS records to change the >

Re: [PATCH net-next 1/2] dt-bindings: net: dsa: add MT7530 GPIO controller binding

2021-01-14 Thread Rob Herring
On Mon, 11 Jan 2021 13:44:27 +0800, DENG Qingfang wrote: > Add device tree binding to support MT7530 GPIO controller. > > Signed-off-by: DENG Qingfang > --- > Documentation/devicetree/bindings/net/dsa/mt7530.txt | 6 ++ > 1 file changed, 6 insertions(+) > Acked-by: Rob Herring

Re: [PATCH v2 1/6] dt-bindings: trivial-devices: reorder memsic devices

2021-01-14 Thread Rob Herring
On Sun, 10 Jan 2021 00:11:43 +0100, Alexandre Belloni wrote: > Reorder memsic compatible strings alphabetically > > Signed-off-by: Alexandre Belloni > --- > Documentation/devicetree/bindings/trivial-devices.yaml | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > Acked-by: Rob

Re: [PATCH] soc: samsung: pm_domains: Convert to regular platform driver

2021-01-14 Thread Saravana Kannan
On Thu, Jan 14, 2021 at 11:03 AM Marek Szyprowski wrote: > > Hi Saravana, > > On 13.01.2021 21:27, Saravana Kannan wrote: > > On Wed, Jan 13, 2021 at 3:03 AM Marek Szyprowski > > wrote: > >> When Exynos power domain driver was introduced, the only way to ensure > >> that power domains will be

Re: [PATCH v2 03/14] KVM: SVM: Move SEV module params/variables to sev.c

2021-01-14 Thread Tom Lendacky
On 1/13/21 6:36 PM, Sean Christopherson wrote: Unconditionally invoke sev_hardware_setup() when configuring SVM and handle clearing the module params/variable 'sev' and 'sev_es' in sev_hardware_setup(). This allows making said variables static within sev.c and reduces the odds of a collision

Re: [PATCH 1/9] clk: qcom: gcc-msm8998: Wire up gcc_mmss_gpll0 clock

2021-01-14 Thread Rob Herring
On Sat, Jan 09, 2021 at 02:46:09PM +0100, AngeloGioacchino Del Regno wrote: > This clock enables the GPLL0 output to the multimedia subsystem > clock controller. > > Signed-off-by: AngeloGioacchino Del Regno > > --- > drivers/clk/qcom/gcc-msm8998.c | 17 + >

Re: [PATCH] rpmsg: char: return an error if device already open

2021-01-14 Thread Mathieu Poirier
On Wed, Jan 06, 2021 at 02:37:14PM +0100, Arnaud Pouliquen wrote: > The rpmsg_create_ept function is invoked when the device is opened. > As only one endpoint must be created per device. It is not > possible to open the same device twice. > The fix consists in returning -EBUSY when device is

Re: [RFC PATCH v3 14/16] cxl/mem: Use CEL for enabling commands

2021-01-14 Thread Ben Widawsky
On 21-01-14 18:32:17, Jonathan Cameron wrote: > On Thu, 14 Jan 2021 10:13:40 -0800 > Ben Widawsky wrote: > > > On 21-01-14 18:02:11, Jonathan Cameron wrote: > > > On Mon, 11 Jan 2021 14:51:19 -0800 > > > Ben Widawsky wrote: > > > > > > > The Command Effects Log (CEL) is specified in the CXL

Re: [PATCH v2] perf test: Fix shadow stat test for non-bash shells

2021-01-14 Thread Jiri Olsa
On Thu, Jan 14, 2021 at 03:20:22PM -0300, Arnaldo Carvalho de Melo wrote: > Em Thu, Jan 14, 2021 at 02:06:09PM +0900, Namhyung Kim escreveu: > > It was using some bash-specific features and failed to parse when > > running with a different shell like below: > > > >

Re: [PATCH v26 00/12] Landlock LSM

2021-01-14 Thread Mickaël Salaün
On 14/01/2021 04:22, Jann Horn wrote: > On Wed, Dec 9, 2020 at 8:28 PM Mickaël Salaün wrote: >> This patch series adds new built-time checks, a new test, renames some >> variables and functions to improve readability, and shift syscall >> numbers to align with -next. > > Sorry, I've finally

Re: [PATCH] soc: samsung: pm_domains: Convert to regular platform driver

2021-01-14 Thread Marek Szyprowski
Hi Saravana, On 13.01.2021 21:27, Saravana Kannan wrote: > On Wed, Jan 13, 2021 at 3:03 AM Marek Szyprowski > wrote: >> When Exynos power domain driver was introduced, the only way to ensure >> that power domains will be instantiated before the devices which belongs >> to them was to initialize

Re: [PATCH v5] perf stat: Fix wrong skipping for per-die aggregation

2021-01-14 Thread Jiri Olsa
On Thu, Jan 14, 2021 at 03:30:47PM -0300, Arnaldo Carvalho de Melo wrote: > Em Wed, Jan 13, 2021 at 12:07:01PM +0100, Jiri Olsa escreveu: > > On Wed, Jan 13, 2021 at 09:56:31AM +0800, Jin Yao wrote: > > > > SNIP > > > > > > > > root@lkp-csl-2ap4 ~# ./perf stat -a -I 1000 -e llc_misses.mem_read

Re: [PATCH v6] perf stat: Fix wrong skipping for per-die aggregation

2021-01-14 Thread Jiri Olsa
On Thu, Jan 14, 2021 at 09:27:55AM +0800, Jin Yao wrote: SNIP > 2.003776312 S1-D0 1 855616 Bytes > llc_misses.mem_read > 2.003776312 S1-D1 1 949376 Bytes > llc_misses.mem_read > 3.006512788 S0-D0 11338880 Bytes >

drivers/media/test-drivers/vidtv/vidtv_psi.c:1457:31: warning: taking address of packed member 'bitfield' of class or structure 'vidtv_psi_table_nit' may result in an unaligned pointer value

2021-01-14 Thread kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: 65f0d2414b7079556fbbcc070b3d1c9f9587606d commit: c2f78f0cb294aa6f009d3a170f4ee8ad199ba5da media: vidtv: psi: add a Network Information Table (NIT) date: 7 weeks ago config: mips-randconfig-r026-20210114

Re: [PATCH] scripts: kconfig: fix HOSTCC call

2021-01-14 Thread Masahiro Yamada
On Thu, Jan 14, 2021 at 7:05 PM Enrico Weigelt, metux IT consult wrote: > Thanks for catching this. > The change c0f975af1745391749e4306aa8081b9a4d2cced8 introduces a bug when Please use 12-digit hash ("subject") style. Commit c0f975af1745 ("kconfig: Support building mconf with vendor

Re: [RFC PATCH 4/8] mm: Separate fault info out of 'struct vm_fault'

2021-01-14 Thread Will Deacon
On Thu, Jan 14, 2021 at 10:16:13AM -0800, Linus Torvalds wrote: > On Thu, Jan 14, 2021 at 10:01 AM Will Deacon wrote: > > > > Try to clean this up by splitting the immutable fault information out > > into a new 'struct vm_fault_info' which is embedded in 'struct vm_fault' > > and will later be

Re: [PATCH] nt: usb: USB_RTL8153_ECM should not default to y

2021-01-14 Thread patchwork-bot+netdevbpf
Hello: This patch was applied to netdev/net.git (refs/heads/master): On Wed, 13 Jan 2021 15:43:09 +0100 you wrote: > In general, device drivers should not be enabled by default. > > Fixes: 657bc1d10bfc23ac ("r8153_ecm: avoid to be prior to r8152 driver") > Signed-off-by: Geert Uytterhoeven >

Re: [PATCH v7 3/7] mfd: Add base driver for Netronix embedded controller

2021-01-14 Thread Jonathan Neuschäfer
On Tue, Jan 12, 2021 at 08:36:49PM +0100, Andreas Kemnade wrote: > On Sat, 9 Jan 2021 19:02:16 +0100 > Jonathan Neuschäfer wrote: [...] > > +static const struct of_device_id of_ntxec_match_table[] = { > > + { .compatible = "netronix,ntxec", }, > > + {} > > +}; > > + > MODULE_DEVICE_TABLE?

Re: [PATCH v26 11/12] samples/landlock: Add a sandbox manager example

2021-01-14 Thread Mickaël Salaün
On 14/01/2021 04:21, Jann Horn wrote: > On Wed, Dec 9, 2020 at 8:29 PM Mickaël Salaün wrote: >> Add a basic sandbox tool to launch a command which can only access a >> whitelist of file hierarchies in a read-only or read-write way. > > I have to admit that I didn't really look at this closely

Re: [PATCH bpf-next 2/3] bpf: Add size arg to build_id_parse function

2021-01-14 Thread Yonghong Song
On 1/14/21 5:40 AM, Jiri Olsa wrote: It's possible to have other build id types (other than default SHA1). Currently there's also ld support for MD5 build id. Currently, bpf build_id based stackmap does not returns the size of the build_id. Did you see an issue here? I guess user space can

Re: [PATCH v3 04/17] perf: x86/ds: Handle guest PEBS overflow PMI and inject it to guest

2021-01-14 Thread Sean Christopherson
On Mon, Jan 04, 2021, Like Xu wrote: > --- > arch/x86/events/intel/ds.c | 62 ++ > 1 file changed, 62 insertions(+) > > diff --git a/arch/x86/events/intel/ds.c b/arch/x86/events/intel/ds.c > index b47cc4226934..c499bdb58373 100644 > ---

[PATCH v3 2/2] dt-bindings: Document bindings for new SDM845 devices

2021-01-14 Thread Caleb Connolly
Document compatible bindings for the new OnePlus 6/6T devices. Signed-off-by: Caleb Connolly --- Documentation/devicetree/bindings/arm/qcom.yaml| 5 + Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 2 files changed, 7 insertions(+) diff --git

[PATCH v4] kbuild: check the minimum compiler version in Kconfig

2021-01-14 Thread Masahiro Yamada
Paul Gortmaker reported a regression in the GCC version check [1]. If you use GCC 4.8, the build breaks before showing the error message "error Sorry, your version of GCC is too old - please use 4.9 or newer." I do not want to apply his fix-up since it implies we would not be able to remove any

Re: [PATCH v26 07/12] landlock: Support filesystem access-control

2021-01-14 Thread Mickaël Salaün
On 14/01/2021 04:22, Jann Horn wrote: > On Wed, Dec 9, 2020 at 8:28 PM Mickaël Salaün wrote: >> Thanks to the Landlock objects and ruleset, it is possible to identify >> inodes according to a process's domain. To enable an unprivileged >> process to express a file hierarchy, it first needs to

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