Re: [PATCH 2/2] exec: Avoid pathological argc, envc, and bprm->p values

2024-06-21 Thread Kees Cook
On Thu, Jun 20, 2024 at 05:19:55PM -0700, Guenter Roeck wrote: > Hi, > > On Sun, May 19, 2024 at 07:16:12PM -0700, Kees Cook wrote: > > Make sure nothing goes wrong with the string counters or the bprm's > > belief about the stack pointer. Add checks and matching self-tests. > > > > For 32-bit va

Re: [PATCH] powerpc/pseries: Whitelist dtl slub object for copying to userspace

2024-06-21 Thread Anjali K
Hi Michael On 18/06/24 12:41, Michael Ellerman wrote: > I guess there isn't a kmem_cache_create_user_readonly() ? Thank you for your review.     My understanding of the question is whether there's a way to whitelist a    region such that it can be co

Re: [PATCH v2 0/9] Add per-core RAPL energy counter support for AMD CPUs

2024-06-21 Thread K Prateek Nayak
Hello Dhananjay, On 6/20/2024 6:26 PM, Dhananjay Ugwekar wrote: Currently the energy-cores event in the power PMU aggregates energy consumption data at a package level. On the other hand the core energy RAPL counter in AMD CPUs has a core scope (which means the energy consumption is recorded sep

Re: [PATCH v2 0/9] Add per-core RAPL energy counter support for AMD CPUs

2024-06-21 Thread Dhananjay Ugwekar
Hello Prateek, On 6/21/2024 1:54 PM, K Prateek Nayak wrote: > Hello Dhananjay, > > On 6/20/2024 6:26 PM, Dhananjay Ugwekar wrote: >> Currently the energy-cores event in the power PMU aggregates energy >> consumption data at a package level. On the other hand the core energy >> RAPL counter in AMD

Re: [PATCH v5 2/6] mm/slab: Plumb kmem_buckets into __do_kmalloc_node()

2024-06-21 Thread Markus Elfring
… > functions can then been built without the argument, … be? … > +++ b/include/linux/slab.h … > -void *kmalloc_node_track_caller_noprof(size_t size, gfp_t flags, int node, … > +void *__kmalloc_node_track_caller_noprof(DECL_BUCKET_PARAMS(size, b), gfp_t > flags, int node, …

Re: [PATCH v4 2/3] leds: sy7802: Add support for Silergy SY7802 flash LED controller

2024-06-21 Thread Lee Jones
On Sun, 16 Jun 2024, André Apitzsch via B4 Relay wrote: > From: André Apitzsch > > The SY7802 is a current-regulated charge pump which can regulate two > current levels for Flash and Torch modes. > > It is a high-current synchronous boost converter with 2-channel high > side current sources. Ea

Re: [PATCH] randomize_kstack: Remove non-functional per-arch entropy filtering

2024-06-21 Thread Mark Rutland
On Thu, Jun 20, 2024 at 11:34:22AM -0700, Kees Cook wrote: > On Thu, Jun 20, 2024 at 11:47:58AM +0800, liuyuntao (F) wrote: > > > > > > On 2024/6/20 5:47, Kees Cook wrote: > > > An unintended consequence of commit 9c573cd31343 ("randomize_kstack: > > > Improve entropy diffusion") was that the per

Re: [PATCH] powerpc/pseries: Whitelist dtl slub object for copying to userspace

2024-06-21 Thread Michael Ellerman
Anjali K writes: > Hi Michael > > On 18/06/24 12:41, Michael Ellerman wrote: >> I guess there isn't a kmem_cache_create_user_readonly() ? > Thank you for your review.     > > My understanding of the question is whether there's a way to whitelist a 

Re: [PATCH net-next] netdevice: define and allocate &net_device _properly_

2024-06-21 Thread Breno Leitao
On Fri, Jun 14, 2024 at 05:00:54AM -0700, Breno Leitao wrote: > On Wed, May 08, 2024 at 11:13:21AM +0200, Alexander Lobakin wrote: > > From: Jakub Kicinski > > Date: Tue, 7 May 2024 11:10:35 -0700 > > > > > On Tue, 7 May 2024 14:39:37 +0200 Alexander Lobakin wrote: > > >> There are several insta

Re: [PATCH v5 2/4] interconnect: qcom: sc7280: enable QoS configuration

2024-06-21 Thread Odelu Kukatla
On 6/18/2024 8:16 PM, Konrad Dybcio wrote: > > > On 6/7/24 19:39, Odelu Kukatla wrote: >> Enable QoS configuration for master ports with predefined values >> for priority and urgency forawrding. >> >> Signed-off-by: Odelu Kukatla >> --- > > msm-5.4 also has a qhm_gic node with QoS offset 0x9

Re: [PATCH 2/2] exec: Avoid pathological argc, envc, and bprm->p values

2024-06-21 Thread Kees Cook
On Fri, Jun 21, 2024 at 06:21:15AM -0700, Guenter Roeck wrote: > On 6/21/24 00:00, Kees Cook wrote: > > On Thu, Jun 20, 2024 at 05:19:55PM -0700, Guenter Roeck wrote: > > > Hi, > > > > > > On Sun, May 19, 2024 at 07:16:12PM -0700, Kees Cook wrote: > > > > Make sure nothing goes wrong with the stri

[PATCH v2 0/2] exec: Avoid pathological argc, envc, and bprm->p values

2024-06-21 Thread Kees Cook
Hi, This pair of patches replaces the last patch in this[1] series. Perform bprm argument overflow checking but only do argmin checks for MMU systems. To avoid tripping over this again, argmin is explicitly defined only for CONFIG_MMU. Thank you to Guenter Roeck for finding this issue (again)! -

[PATCH v2 1/2] execve: Keep bprm->argmin behind CONFIG_MMU

2024-06-21 Thread Kees Cook
When argmin was added in commit 655c16a8ce9c ("exec: separate MM_ANONPAGES and RLIMIT_STACK accounting"), it was intended only for validating stack limits on CONFIG_MMU[1]. All checking for reaching the limit (argmin) is wrapped in CONFIG_MMU ifdef checks, though setting argmin was not. That argmin

[PATCH v2 2/2] exec: Avoid pathological argc, envc, and bprm->p values

2024-06-21 Thread Kees Cook
Make sure nothing goes wrong with the string counters or the bprm's belief about the stack pointer. Add checks and matching self-tests. Take special care for !CONFIG_MMU, since argmin is not exposed there. For 32-bit validation, 32-bit UML was used: $ tools/testing/kunit/kunit.py run \ --