On Thu, Jun 13, 2024 at 04:10:12PM -0400, Steven Rostedt wrote:
> On Thu, 13 Jun 2024 13:04:20 -0700
> Andrew Morton wrote:
>
> > On Thu, 13 Jun 2024 15:34:02 -0400 Steven Rostedt
> > wrote:
> >
> > > On Thu, 13 Jun 2024 22:22:18 +0300
> > &g
g++ doesn't like forward enum declarations:
error: use of enum βEβ without previous declaration
64 | enum E;
Delete those which aren't used.
Delete some unused/unnecessary forward struct declarations for a change.
Signed-off-by: Alexey Dobriyan
---
fs/ram
On Sun, Apr 14, 2024 at 01:58:55PM -0700, Luis Chamberlain wrote:
> On Sun, Apr 14, 2024 at 10:05:05PM +0300, Alexey Dobriyan wrote:
> > --- a/include/linux/fs.h
> > +++ b/include/linux/fs.h
> > @@ -3616,4 +3616,12 @@ extern int vfs_fadvise(struct file *file, loff_t
&
nts that newlines should be banned too,
and \x1f, and whitespace, and similar looking characters
from different languages and emojis (except π§obviously).
Signed-off-by: Alexey Dobriyan
---
include/linux/fs.h |8
kernel/module/main.c |5 +
2 files changed, 13 insertions(+)
Signed-off-by: Alexey Dobriyan
---
include/uapi/linux/stddef.h |3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/include/uapi/linux/stddef.h
+++ b/include/uapi/linux/stddef.h
@@ -50,8 +50,9 @@
TYPE NAME[]; \
}
#endif
-#endif
#ifndef __counted_by
T member[];
};
Use "T member[0];" which seems to work and does the right thing wrt
structure layout.
Signed-off-by: Alexey Dobriyan
Fixes: 3080ea5553cc ("stddef: Introduce DECLARE_FLEX_ARRAY() helper")
---
include/uapi/linux/stddef.h |6 ++
1 file changed, 6 inse
On Mon, Sep 11, 2023 at 08:19:20AM +, David Laight wrote:
> ...
> > Okay, can you please split the patch so they can be backported
> > separately? Then I'll get them landed, etc.
>
> Since the header with just the extra #endif is badly broken on C++
> isn't it best to ensure they get back-port
On Tue, Apr 20, 2021 at 03:57:07PM +0200, Michal Hocko wrote:
> On Tue 20-04-21 14:24:30, Matthew Wilcox wrote:
> > On Tue, Apr 20, 2021 at 03:13:54PM +0300, Mike Rapoport wrote:
> > > Add a paragraph that explains that it may happen that the counters in
> > > /proc/meminfo do not add up to the ove
βββ 60XX_WDT
βββ 64BIT
...
βββ ZSWAP_DEFAULT_ON
βββ ZSWAP_ZPOOL_DEFAULT
βββ ZSWAP_ZPOOL_DEFAULT_ZBUD
0 directories, 12364 files
Signed-off-by: Alexey Dobriyan
---
include/linux/compiler-version.h |2 +-
init/Kconfig |
βββ ZSWAP
βββ ZSWAP_COMPRESSOR_DEFAULT
βββ ZSWAP_COMPRESSOR_DEFAULT_LZO
βββ ZSWAP_DEFAULT_ON
βββ ZSWAP_ZPOOL_DEFAULT
βββ ZSWAP_ZPOOL_DEFAULT_ZBUD
0 directories, 12364 files
Signed-off-by: Alexey Dobriyan
---
include/linux/compiler-version.h
g style.
Then run
$ ./scripts/ide/qt-creator.sh xxx
from top-level directory
Note:
ibmvnic.c is excluded from project files to workaround libCPlusPlus crash.
Signed-off-by: Alexey Dobriyan
---
scripts/ide/qt-creator.sh | 49 ++
1 fi
I'm not a security guy, but
The idea is to irrevocably mark task as tainted after its registers
and/or memory have been changed by another task.
The list definitely includes
* ptrace PTRACE_POKEUSER, PTRACE_POKETEXT, PTRACE_POKEDATA,
PTRACE_SETREGS, PTRACE_SETFPREGS.
* process_vm_writev(2)
If
On Wed, Apr 07, 2021 at 08:58:09PM +0100, Matthew Wilcox wrote:
> On Wed, Apr 07, 2021 at 10:55:14PM +0300, Alexey Dobriyan wrote:
> > Now that ->proc_lseek has been made mandatory it would be nice to test
> > that nothing has been forgotten.
>
> > @@ -45,6 +45,8
Now that ->proc_lseek has been made mandatory it would be nice to test
that nothing has been forgotten.
Signed-off-by: Alexey Dobriyan
---
May want to fold into
proc-mandate-proc_lseek-in-struct-proc_ops.patch
tools/testing/selftests/proc/read.c |4 +++-
1 f
It is apparent that emoji outbreak can not be contained.
In that case might as well embrace it.
Change main kernel banner, /proc/version and uname(2) output.
Signed-off-by: Alexey Dobriyan
---
include/linux/uts.h |2 +-
init/version.c |2 +-
2 files changed, 2 insertions(+), 2
On Mon, Mar 22, 2021 at 07:53:10AM +, Christoph Hellwig wrote:
> On Sat, Mar 20, 2021 at 10:23:12AM -0700, Andy Lutomirski wrote:
> > > https://github.com/systemd/systemd/blob/main/src/basic/process-util.c#L354
> > > src/basic/process-util.c:is_kernel_thread()
> >
> > Eww.
> >
> > Could we fi
On Sat, Mar 20, 2021 at 10:23:12AM -0700, Andy Lutomirski wrote:
> > On Mar 20, 2021, at 9:31 AM, Alexey Dobriyan wrote:
> >
> > ο»ΏPF_KTHREAD value is visible via field number 9 of /proc/*/stat
> >
> >$ sudo cat /proc/2/stat
> >
is a disaster.
I hope we can mask everything but few flags and hope for the best :^)
Note for beginner Linux programmers:
every other way you find on the interwebs and Stack Overflow
for checking if pid belongs to a kernel thread is broken one way or
another.
Signed-off-by: Alexey Dobriyan
---
in
Test that /proc instance mounted with
mount -t proc -o subset=pid
contains only ".", "..", "self", "thread-self" and pid directories.
Note:
Currently "subset=pid" doesn't return "." and ".." via readdir.
This mu
Two checks in lookup and readdir code should be enough to not have
third check in open code.
Can't open what can't be looked up?
Signed-off-by: Alexey Dobriyan
---
fs/proc/inode.c |4
1 file changed, 4 deletions(-)
--- a/fs/proc/inode.c
+++ b/fs/proc/inode.c
@@ -48
Now that proc_ops are separate from file_operations and other
operations it easy to check all instances to have ->proc_lseek
hook and remove check in main code.
Note:
nonseekable_open() files naturally don't require ->proc_lseek.
Garbage collect pde_lseek() function.
Signed-off
Can't look at this verbosity anymore.
Signed-off-by: Alexey Dobriyan
---
fs/proc/generic.c | 11 ++-
1 file changed, 2 insertions(+), 9 deletions(-)
--- a/fs/proc/generic.c
+++ b/fs/proc/generic.c
@@ -166,15 +166,8 @@ static int __xlate_proc_name(const char *name, s
On Mon, Mar 15, 2021 at 09:42:47AM +0300, Cyrill Gorcunov wrote:
> On Mon, Mar 15, 2021 at 09:00:00AM +0300, Alexey Dobriyan wrote:
> > On Sun, Mar 14, 2021 at 02:40:05PM -0700, Linus Torvalds wrote:
> > > [mm->saved_auxv]
> > >
> > > That's a separate
On Mon, Mar 15, 2021 at 01:29:02PM +0300, Dan Carpenter wrote:
> On Sun, Mar 14, 2021 at 11:51:14PM +0300, Alexey Dobriyan wrote:
> > prctl(PR_SET_MM, PR_SET_MM_AUXV, addr, 1);
> >
> > will copy 1 byte from userspace to (quite big) on-stack array
> > and
On Sun, Mar 14, 2021 at 02:40:05PM -0700, Linus Torvalds wrote:
> [mm->saved_auxv]
>
> That's a separate issue, and I can't find it in myself to care (and
> nobody has ever complained), but I thought I'd mention it.
There is another (non-security) one. Compat 32-bit process will report
2 longs to
ack contents to userspace.
This devious scheme requires CAP_SYS_RESOURCE.
Signed-off-by: Alexey Dobriyan
---
apply to >=3.5
kernel/sys.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/kernel/sys.c
+++ b/kernel/sys.c
@@ -2079,7 +2079,7 @@ static int prctl_set_auxv(
Nothing really uses init_groups. It can be accessed via init_cred
if necessary.
Signed-off-by: Alexey Dobriyan
---
include/linux/cred.h |1 -
include/linux/init_task.h |1 -
kernel/cred.c |2 +-
3 files changed, 1 insertion(+), 3 deletions(-)
--- a/include/linux
On Tue, Mar 09, 2021 at 10:30:23AM -0800, Eric Biggers wrote:
> On Tue, Mar 09, 2021 at 01:55:27AM -0800, Jia-Ju Bai wrote:
> > When get_task_mm() returns NULL to mm, no error return code of
> > proc_map_files_readdir() is assigned.
> > To fix this bug, ret is assigned with -ENOENT in this case.
>
On Mon, Mar 01, 2021 at 10:19:50AM +, Russell King - ARM Linux admin wrote:
> On Sun, Feb 28, 2021 at 07:59:16PM +0300, Alexey Dobriyan wrote:
> > From 72842f89ae91a4d02ea29604f87c373052bd3f64 Mon Sep 17 00:00:00 2001
> > From: Alexey Dobriyan
> > Date: Tue, 9 Fe
On Sun, Feb 28, 2021 at 09:46:17AM -0800, Linus Torvalds wrote:
> On Sun, Feb 28, 2021 at 8:57 AM Alexey Dobriyan wrote:
> >
> > This is bulk deletion of preprocessor include guards and conversion
> > to #pragma once directive.
>
> So as mentioned earlier, I
On Sun, Feb 28, 2021 at 01:37:41PM -0500, Paul Moore wrote:
> On Sun, Feb 28, 2021 at 12:04 PM Alexey Dobriyan wrote:
> >
> > From 097f2c8b2af7d9e88cff59376ea0ad51b95341cb Mon Sep 17 00:00:00 2001
> > From: Alexey Dobriyan
> > Date: Tue, 9 Feb 2021 00:39:23 +030
misc stuff).
Not compile tested on csky, hexagon, nds32, openrisc.
Love,
Alexey
Signed-off-by: Alexey Dobriyan
#!/bin/sh -x
find . -type f -name '*.h' -print |\
LC_ALL=C sort |\
sed -e 's#^./##g' |\
xargs ./script
>From 2bffcdfec69a8d28e9cb2c535724fbba8e12b820 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 14:47:34 +0300
Subject: [PATCH 11/11] pragma once: conversion script (in Python 2)
Script accepts list of files to be converted from the command line,
strips include guard if
>From 251ca5673886b5bb0a42004944290b9d2b267a4a Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Fri, 19 Feb 2021 13:37:24 +0300
Subject: [PATCH 10/11] pragma once: delete few backslashes
Some macros contain one backslash too many and end up being the last
macro in a header file. When #pra
>From 097f2c8b2af7d9e88cff59376ea0ad51b95341cb Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 00:39:23 +0300
Subject: [PATCH 09/11] pragma once: convert
scripts/selinux/genheaders/genheaders.c
Generate security/selinux/flask.h and security/selinux/av_permissions.h
with
>From e428633ff0df5fe8501aaf785c6961fc766344b2 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 00:31:23 +0300
Subject: [PATCH 07/11] pragma once: convert kernel/time/timeconst.bc
Generate include/generated/timeconst.h without include guard.
Signed-off-by: Alexey Dobri
>From f10fe79897fa9600f144c76bc5df52dba28b7a66 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 01:37:55 +0300
Subject: [PATCH 08/11] pragma once: convert scripts/atomic/
Generate atomic headers without include guards.
Signed-off-by: Alexey Dobriyan
---
include/asm-gene
>From 1c4107e55b322dada46879837d4d64841bc5f150 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 16:56:54 +0300
Subject: [PATCH 06/11] pragma once: convert include/linux/cb710.h
This file is concatenation of two files with two include guards.
Convert it manually.
Signed-
>From fe8504a1a0b5352cbc676b933c3dbb79ae9f59c9 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 16:50:24 +0300
Subject: [PATCH 04/11] pragma once: convert
drivers/gpu/drm/pl111/pl111_nomadik.h
This file has broken include guard, convert it manually.
Signed-off-by: Ale
>From 1f58b4923ca9bfb8b1e73554d3793ee98ab58a77 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 17:14:25 +0300
Subject: [PATCH 05/11] pragma once: convert drivers/scsi/qla2xxx/qla_target.h
This file has broken include guard which is not obvious just by looking
at the c
>From 45622ce1e4db512ad603dd90f959e61285b7541a Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 14:43:52 +0300
Subject: [PATCH 03/11] pragma once: convert arch/s390/tools/gen_facilities.c
Generate arch/s390/include/generated/asm/facility-defs.h without include
guard.
Sig
>From c17ac63e1334c742686cd411736699c1d34d45a7 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Wed, 10 Feb 2021 21:07:45 +0300
Subject: [PATCH 01/11] pragma once: delete include/linux/atm_suni.h
This file has been empty since 2.3.99-pre3!
Delete it instead of converting to #pragma o
>From 72842f89ae91a4d02ea29604f87c373052bd3f64 Mon Sep 17 00:00:00 2001
From: Alexey Dobriyan
Date: Tue, 9 Feb 2021 14:37:40 +0300
Subject: [PATCH 02/11] pragma once: convert arch/arm/tools/gen-mach-types
Generate arch/arm/include/generated/asm/mach-types.h without include
guard.
Signed-off
This is bulk deletion of preprocessor include guards and conversion
to #pragma once directive.
See [PATCH 11/11] and [PATCH 12/11] for the script and rationale.
Everything else is trivial stuff.
On Fri, Feb 26, 2021 at 01:53:48PM -0800, Linus Torvalds wrote:
> On Fri, Feb 26, 2021 at 12:17 PM Alexey Dobriyan wrote:
> >
> > I want to sent treewide "#pragma once" conversion:
>
> Are there *any* advantages to it?
>
> It's non-standard,
It is effe
Linus wrote:
> I'm hoping to just do -rc1 this weekend after all - despite my late
> start due to loss of power for several days.
>
> I'll allow late stragglers with good reason through, but the fewer of
> those there are, the better, of course.
I want to sent treewide "#pragma once" conversion:
On Fri, Feb 12, 2021 at 04:01:48PM -0600, Eric W. Biederman wrote:
> Joe Perches writes:
>
> > Convert S_ permissions to the more readable octal.
> Something like that should be able to address the readability while
> still using symbolic constants.
Macros are easy. I've sent a patch long time
On Mon, Feb 08, 2021 at 03:22:44PM +, Matthew Wilcox wrote:
> On Mon, Feb 08, 2021 at 03:14:28PM +, Kalesh Singh wrote:
> > - seq_printf(m, "pos:\t%lli\nflags:\t0%o\nmnt_id:\t%i\n",
> > + seq_printf(m, "pos:\t%lli\nflags:\t0%o\nmnt_id:\t%i\ninode_no:\t%lu\n",
>
> You changed it everywh
On Mon, Feb 08, 2021 at 04:25:35PM +0100, Peter Zijlstra wrote:
> On Mon, Feb 08, 2021 at 05:52:45PM +0300, Alexey Dobriyan wrote:
> > On Mon, Feb 08, 2021 at 05:30:25PM +0300, Alexey Dobriyan wrote:
> > > On Mon, Feb 08, 2021 at 11:34:18AM +0100, Peter Zijlstra wrote:
> >
On Mon, Feb 08, 2021 at 05:30:25PM +0300, Alexey Dobriyan wrote:
> On Mon, Feb 08, 2021 at 11:34:18AM +0100, Peter Zijlstra wrote:
> > On Sat, Feb 06, 2021 at 06:18:32PM +0300, Alexey Dobriyan wrote:
> >
> > > Silently delete "extern" from prototypes.
> >
On Mon, Feb 08, 2021 at 11:39:25AM +0100, Peter Zijlstra wrote:
> On Sat, Feb 06, 2021 at 06:18:32PM +0300, Alexey Dobriyan wrote:
> > 32-bit accesses are shorter than 64-bit accesses on x86_64.
> > Nothing uses 64-bitness of struct task_struct::state.
> >
> > Pr
On Mon, Feb 08, 2021 at 11:34:18AM +0100, Peter Zijlstra wrote:
> On Sat, Feb 06, 2021 at 06:18:32PM +0300, Alexey Dobriyan wrote:
>
> > Silently delete "extern" from prototypes.
>
> NAK, extern is right.
Extern is only necessary for variables.
ue to futex pid
limits), then per-runqueue counters can't as well.
This patchset has been sponsored by REX Prefix Eradication Society.
Signed-off-by: Alexey Dobriyan
---
kernel/sched/loadavg.c |2 +-
kernel/sched/sched.h | 12 ++--
2 files changed, 7 insertions(+), 7
Runqueue ->nr_iowait counters are 32-bit anyway.
Propagate 32-bitness into other code, but don't try too hard.
Signed-off-by: Alexey Dobriyan
---
drivers/cpuidle/governors/menu.c |6 +++---
include/linux/sched/stat.h |2 +-
kernel/sched/core.c |2 +-
Creating 2**32 tasks to wait in D-state is impossible and wasteful.
Return "unsigned int" and save on REX prefixes.
Signed-off-by: Alexey Dobriyan
---
fs/proc/stat.c |2 +-
include/linux/sched/stat.h |2 +-
kernel/sched/core.c|4 ++--
3 files
Creating 2**32 tasks to run is impossible due to futex pid limits
and wasteful anyway. Nobody have done it.
Bring nr_running() into 32-bit world to save on REX prefixes.
Signed-off-by: Alexey Dobriyan
---
fs/proc/loadavg.c |2 +-
fs/proc/stat.c |2 +-
include
32-bit accesses are shorter than 64-bit accesses on x86_64.
Nothing uses 64-bitness of struct task_struct::state.
Propagate 32-bitness to other variables and functions.
Silently delete "extern" from prototypes.
Signed-off-by: Alexey Dobriyan
---
block/blk-mq.c
The following commit has been merged into the timers/core branch of tip:
Commit-ID: 174bcc691f44fdd05046c694fc650933819f72c7
Gitweb:
https://git.kernel.org/tip/174bcc691f44fdd05046c694fc650933819f72c7
Author:Alexey Dobriyan
AuthorDate:Tue, 29 Dec 2020 00:54:02 +03:00
The following commit has been merged into the x86/cleanups branch of tip:
Commit-ID: 4f63b320afdd9af406f4426b0ff1a2cdb23e5b8d
Gitweb:
https://git.kernel.org/tip/4f63b320afdd9af406f4426b0ff1a2cdb23e5b8d
Author:Alexey Dobriyan
AuthorDate:Thu, 05 Mar 2020 21:17:19 +03:00
On Wed, Jan 27, 2021 at 11:21:18PM +1100, Stephen Rothwell wrote:
> Caused by commit
>
> 5567a1a4b1c3 ("ramfs: support O_TMPFILE")
Can this be merged or sent to Al, please? It's ancient patch.
On Wed, Jan 13, 2021 at 06:41:27PM +0100, Piotr Figiel wrote:
> +static int proc_pid_rseq(struct seq_file *m, struct pid_namespace *ns,
> + struct pid *pid, struct task_struct *task)
> +{
> + int res = lock_trace(task);
> +
> + if (res)
> + return res
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", (uint64_t)task->rseq, task->rseq_sig);
%llx is too much on 32-bit. "%tx %x
Signed-off-by: Alexey Dobriyan
---
kernel/time/namespace.c |6 --
1 file changed, 6 deletions(-)
--- a/kernel/time/namespace.c
+++ b/kernel/time/namespace.c
@@ -465,9 +465,3 @@ struct time_namespace init_time_ns = {
.ns.ops = &timens_operations,
.frozen_off
On Tue, Dec 22, 2020 at 06:18:34PM -0800, a...@linux-foundation.org wrote:
>
> proc-wchan-use-printk-format-instead-of-lookup_symbol_name-fix.patch
> ---
> a/fs/proc/base.c~proc-wchan-use-printk-format-instead-of-lookup_symbol_name-fix
> +++ a/fs/proc/base.c
> @@ -384,15 +384,8 @@ static con
under /proc/net .
Fixes: 1da4d377f943 ("proc: revalidate misc dentries")
Reported-by: "Rantala, Tommi T. (Nokia - FI/Espoo)"
Signed-off-by: Alexey Dobriyan
---
fs/proc/generic.c | 24 ++--
fs/proc/internal.h |7 +++
fs/proc/proc_net.c
under /proc/net .
Fixes: 1da4d377f943 ("proc: revalidate misc dentries")
Reported-by: "Rantala, Tommi T. (Nokia - FI/Espoo)"
Signed-off-by: Alexey Dobriyan
---
fs/proc/generic.c | 24 ++--
fs/proc/internal.h |7 +++
fs/proc/proc_net.c
On Fri, Dec 04, 2020 at 02:31:59AM +0800, Wen Yang wrote:
> From: Alexey Dobriyan
>
> [ Upstream commit e3912ac37e07a13c70675cd75020694de4841c74 ]
>
> PROC_NUMBUF is 13 which is enough for "negative int + \n + \0".
>
> However PIDs and TGIDs are never negati
Range checks can folded into proper conversion function.
kstrto*() exist for all arithmetic types.
Signed-off-by: Alexey Dobriyan
---
mm/khugepaged.c | 18 +-
mm/ksm.c| 18 +-
2 files changed, 18 insertions(+), 18 deletions(-)
--- a/mm/khugepaged.c
Use proper conversion functions.
kstrto*() variants exist for all standard types.
Signed-off-by: Alexey Dobriyan
---
lib/test_firmware.c |9 +++--
lib/test_kmod.c | 26 ++
2 files changed, 13 insertions(+), 22 deletions(-)
--- a/lib/test_firmware.c
+++ b
kstrto*() functions can write result directly to target memory
if no additional checks needs to be done.
Signed-off-by: Alexey Dobriyan
---
drivers/base/core.c | 12 +++-
1 file changed, 3 insertions(+), 9 deletions(-)
--- a/drivers/base/core.c
+++ b/drivers/base/core.c
@@ -1701,12
> BTW., there's another, rather spurious bug I recently triggered in kbuild.
>
> Occasionally when I Ctrl-C a kernel build on a system with a lot of CPUs,
> the .o.cmd file gets corrupted:
Those are temporary files, truncated at page boundary.
$ stat -c %s XXX.pata_sil680.mod.o.cmd
On Wed, Sep 09, 2020 at 08:41:22AM -0600, Tom Hromatka wrote:
> static u64 get_idle_time(struct kernel_cpustat *kcs, int cpu)
> {
> - u64 idle, idle_usecs = -1ULL;
> + u64 idle, idle_usecs;
>
> - if (cpu_online(cpu))
> - idle_usecs = get_cpu_idle_time_us(cpu, NULL);
> -
On Fri, Sep 04, 2020 at 08:00:24AM +0200, Ingo Molnar wrote:
> * Christoph Hellwig wrote:
> > this series removes the last set_fs() used to force a kernel address
> > space for the uaccess code in the kernel read/write/splice code, and then
> > stops implementing the address space overrides entire
On Thu, Aug 20, 2020 at 02:29:40PM -0700, a...@linux-foundation.org wrote:
> Subject: x86/defconfigs: Explicitly unset CONFIG_64BIT in i386_defconfig
>
> A recent refresh of the defconfigs got rid of the following (unset)
> config:
>
> # CONFIG_64BIT is not set
>
> Innocuous as it seems, when
On Sat, Aug 15, 2020 at 11:42:10PM +0100, Al Viro wrote:
> On Sat, Aug 15, 2020 at 11:23:43AM -0700, Pascal Bouchareine wrote:
> > Let caller specify allocation.
> > Preserve existing calls with GFP_USER.
>
> Bloody bad idea, unless you slap a BUG_ON(flags & GFP_ATOMIC) on it,
> to make sure nobod
On Mon, Aug 03, 2020 at 01:03:17PM +0300, Kirill Tkhai wrote:
> On 31.07.2020 01:13, Eric W. Biederman wrote:
> > Kirill Tkhai writes:
> >
> >> On 30.07.2020 17:34, Eric W. Biederman wrote:
> >>> Kirill Tkhai writes:
> >>>
> Currently, there is no a way to list or iterate all or subset of
On Thu, Jul 30, 2020 at 03:00:19PM +0300, Kirill Tkhai wrote:
> # ls /proc/namespaces/ -l
> lrwxrwxrwx 1 root root 0 Jul 29 16:50 'cgroup:[4026531835]' ->
> 'cgroup:[4026531835]'
> lrwxrwxrwx 1 root root 0 Jul 29 16:50 'ipc:[4026531839]' -> 'ipc:[4026531839]'
> lrwxrwxrwx 1 root root 0 Jul 29 16:
On Tue, Jul 28, 2020 at 06:44:19PM -0700, Andrew Morton wrote:
> On Tue, 28 Jul 2020 15:39:21 -0700 Randy Dunlap wrote:
>
> > On 7/28/20 2:55 PM, Andrew Morton wrote:
> > > On Tue, 28 Jul 2020 05:33:58 -0700 Randy Dunlap
> > > wrote:
> > >
> > >> On 7/27/20 6:19 PM, Andrew Morton wrote:
> > >>
On Fri, Jul 24, 2020 at 10:22:36PM -0700, Pascal Bouchareine wrote:
> This command attaches a description to a file descriptor for
> troubleshooting purposes. The free string is displayed in the
> process fdinfo file for that fd /proc/pid/fdinfo/fd.
>
> One intended usage is to allow processes to
The following commit has been merged into the locking/core branch of tip:
Commit-ID: a9232dc5607dbada801f2fe83ea307cda762969a
Gitweb:
https://git.kernel.org/tip/a9232dc5607dbada801f2fe83ea307cda762969a
Author:Alexey Dobriyan
AuthorDate:Sat, 11 Jul 2020 17:59:54 +03:00
On Mon, Jul 13, 2020 at 01:51:41PM +0200, Peter Zijlstra wrote:
> On Sat, Jul 11, 2020 at 05:59:54PM +0300, Alexey Dobriyan wrote:
> > Leading comma prevents arbitrary reordering of initialisation clauses.
> > The whole point of C99 initialisation is to allow any such reord
Leading comma prevents arbitrary reordering of initialisation clauses.
The whole point of C99 initialisation is to allow any such reordering.
Signed-off-by: Alexey Dobriyan
---
include/linux/rwsem.h | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
--- a/include/linux/rwsem.h
Two functions are only called via function pointers, don't bother
inlining them.
Signed-off-by: Alexey Dobriyan
---
ipc/sem.c |3 +--
ipc/shm.c |3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
--- a/ipc/sem.c
+++ b/ipc/sem.c
@@ -585,8 +585,7 @@ static int newary(s
Al wrote:
> > On Sat, Jul 04, 2020 at 09:41:09PM +0200, Miklos Szeredi wrote:
> > 1) just leave the first explanation (it's an open + read + close
> > equivalent) and leave out the rest
> >
> > 2) add a loop around the vfs_read() in the code.
>
> 3) don't bother with the entire thing, until som
On Wed, Jul 01, 2020 at 10:35:03PM +0800, zhenwei pi wrote:
> Only softirq name is not friendly to end-users, typically 'HI' is
> difficult to understand. During developing irqtop/lsirq utilities
> for util-linux, Karel Zak considered that we should give more
> information to end-users. Discuss abo
On Tue, Jun 23, 2020 at 02:33:50PM -0700, Christian Kujau wrote:
> On Tue, 23 Jun 2020, Kees Cook wrote:
> > > $ checksec --format=json --extended --file=`which rsync` | jq
> > > {
> > > "/usr/bin/rsync": {
> > > "relro": "full",
> > > "canary": "yes",
> > > "nx": "no",
> > ^^
On Tue, Jun 23, 2020 at 02:33:50PM -0700, Christian Kujau wrote:
> On Tue, 23 Jun 2020, Kees Cook wrote:
> > > $ checksec --format=json --extended --file=`which rsync` | jq
> > > {
> > > "/usr/bin/rsync": {
> > > "relro": "full",
> > > "canary": "yes",
> > > "nx": "no",
> > ^^
On Tue, Jun 23, 2020 at 02:33:50PM -0700, Christian Kujau wrote:
> On Tue, 23 Jun 2020, Kees Cook wrote:
> > > $ checksec --format=json --extended --file=`which rsync` | jq
> > > {
> > > "/usr/bin/rsync": {
> > > "relro": "full",
> > > "canary": "yes",
> > > "nx": "no",
> > ^^
On Wed, Jun 24, 2020 at 12:12:18AM +0300, Alexey Dobriyan wrote:
> On Tue, Jun 23, 2020 at 10:39:26AM -0700, Christian Kujau wrote:
> > Hi,
> >
> > exactly this[0] happened today, on a 5.6.5 kernel:
> >
> > process '/usr/bin/rsync' started with exec
On Tue, Jun 23, 2020 at 10:39:26AM -0700, Christian Kujau wrote:
> Hi,
>
> exactly this[0] happened today, on a 5.6.5 kernel:
>
> process '/usr/bin/rsync' started with executable stack
>
> But I can't reproduce this message, and rsync (v3.2.0, not exactly
> abandonware) runs several times a d
On Fri, Jun 19, 2020 at 11:37:47AM -0700, Linus Torvalds wrote:
> On Thu, Jun 18, 2020 at 2:06 PM Alexey Dobriyan wrote:
> >
> > Rename
> > struct notifier_block *this
> > to
> > struct notifier_block *nb
> >
> > "nb" is argua
> uint64_t val = cqe->res; // assuming non-error here
>
> if (cqe->flags & IORING_CQE_F_ZONE_FOO)
> val |= (cqe->flags >> 16) << 32ULL;
Jens, ULL in shift doesn't do anything for widening the result.
You need
val |= (uint64_t)(cqe->flags >> 16) << 32;
25.c
Both gcc and g++ accept new name. It would make my adventure of carrying
linux++ patchset slightly less miserable.
Signed-off-by: Alexey Dobriyan
---
arch/alpha/kernel/setup.c|2 +-
arch/mips/kernel/pm-cps.c|2 +-
arch/mips/s
On Thu, Jun 18, 2020 at 04:39:35PM +, David Laight wrote:
> From: Alexey Dobriyan
> > Sent: 18 June 2020 14:17
> ...
> > > > diff --git a/arch/x86/lib/usercopy_64.c b/arch/x86/lib/usercopy_64.c
> > > > index fff28c6f73a2..b0dfac3d3df7 100644
>
On Thu, Jun 18, 2020 at 10:48:05AM +, David Laight wrote:
> From: Matt Fleming
> > Sent: 18 June 2020 11:20
> > x86 CPUs can suffer severe performance drops if a tight loop, such as
> > the ones in __clear_user(), straddles a 16-byte instruction fetch
> > window, or worse, a 64-byte cacheline.
> static inline void *kmem_cache_zalloc(struct kmem_cache *k, gfp_t flags)
> {
> - return kmem_cache_alloc(k, flags | __GFP_ZERO);
> + return kmem_cache_zalloc(k, flags);
> }
That's a good one.
On Wed, May 27, 2020 at 09:41:53AM -0500, Eric W. Biederman wrote:
> Kaitao Cheng writes:
>
> > we don't need {len = PTR_ERR(pathname)} when IS_ERR(pathname) is false,
> > it's better to move it into if(IS_ERR(pathname)){}.
>
> Please look at the generated code.
>
> I believe you will find that
On Mon, Oct 21, 2019 at 11:24:27AM +0200, Marco Elver wrote:
> On Sun, 20 Oct 2019 at 19:30, Alexey Dobriyan wrote:
> >
> > (euid, egid) pair is snapshotted correctly from task under RCU,
> > but writeback to inode can be done in any order.
> >
> > Fix by doing wr
On Mon, Oct 21, 2019 at 05:28:09PM +0900, Masami Hiramatsu wrote:
> Currently proc-self-map-files-002.c sets va_max (max test address
> of user virtual address) to 4GB, but it is too big for 32bit
> arch and 1UL << 32 is overflow on 32bit long.
>
> Make va_max 1GB on 32bit arch like i386 and arm.
On Sun, Oct 20, 2019 at 06:17:42PM -0400, Joel Savitz wrote:
> When one attempts to create a directory in /proc with an invalid name,
> such as one in a subdirectory that doesn't exist, one with a name beyond
> 256 characters, or a reserved name such as '.' or '..', the kernel
> throws a warning me
1 - 100 of 1148 matches
Mail list logo