Re: [PATCH v8 06/14] alpha: Align prototypes of IO memcpy/memset

2024-10-08 Thread Richard Henderson
--- Changes for v8: - Mask the argument with 0xff because now it's an int and not a u8 anymore Reviewed-by: Richard Henderson r~ --- arch/alpha/include/asm/io.h | 6 ++ arch/alpha/kernel/io.c | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/arch/alpha/in

Re: [PATCH 4/5] asm-generic: use asm-generic/mman-common.h on parisc and alpha

2024-10-05 Thread Richard Henderson
/mman.h | 68 +++--- arch/parisc/include/uapi/asm/mman.h| 66 + include/uapi/asm-generic/mman-common.h | 5 ++ 3 files changed, 13 insertions(+), 126 deletions(-) Reviewed-by: Richard Henderson r~

Re: [PATCH 3/5] asm-generic: use asm-generic/mman-common.h on mips and xtensa

2024-10-05 Thread Richard Henderson
On 9/25/24 14:06, Arnd Bergmann wrote: From: Arnd Bergmann mips and xtensa have almost the same asm/mman.h, aside from an unintentional difference in MAP_UNINITIALIZED that has no effect in practice. Now that the MAP_* flags are moved out of asm-generic/mman-common.h, the only difference from

[PATCH] random: Make RANDOM_TRUST_CPU depend on ARCH_RANDOM

2019-11-14 Thread richard . henderson
From: Richard Henderson Listing the set of host architectures does not scale. Depend instead on the existance of the architecture rng. Signed-off-by: Richard Henderson --- drivers/char/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/char/Kconfig b

[PATCH v2 10/10] s390x: Mark archrandom.h functions __must_check

2019-11-06 Thread Richard Henderson
We must not use the pointer output without validating the success of the random read. Reviewed-by: Harald Freudenberger Reviewed-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- arch/s390/include/asm/archrandom.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git

[PATCH v2 09/10] powerpc: Mark archrandom.h functions __must_check

2019-11-06 Thread Richard Henderson
We must not use the pointer output without validating the success of the random read. Acked-by: Michael Ellerman Reviewed-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- arch/powerpc/include/asm/archrandom.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a

[PATCH v2 08/10] powerpc: Use bool in archrandom.h

2019-11-06 Thread Richard Henderson
The generic interface uses bool not int; match that. Reviewed-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- arch/powerpc/include/asm/archrandom.h | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/arch/powerpc/include/asm/archrandom.h b/arch

[PATCH v2 07/10] x86: Mark archrandom.h functions __must_check

2019-11-06 Thread Richard Henderson
We must not use the pointer output without validating the success of the random read. Reviewed-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- arch/x86/include/asm/archrandom.h | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/arch/x86/include/asm

[PATCH v2 06/10] linux/random.h: Mark CONFIG_ARCH_RANDOM functions __must_check

2019-11-06 Thread Richard Henderson
We must not use the pointer output without validating the success of the random read. Reviewed-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- include/linux/random.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/linux/random.h b/include/linux

[PATCH v2 05/10] linux/random.h: Use false with bool

2019-11-06 Thread Richard Henderson
Keep the generic fallback versions in sync with the other architecture specific implementations and use the proper name for false. Suggested-by: Ard Biesheuvel Signed-off-by: Richard Henderson --- include/linux/random.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git

[PATCH v2 04/10] linux/random.h: Remove arch_has_random, arch_has_random_seed

2019-11-06 Thread Richard Henderson
The arm64 version of archrandom.h will need to be able to test for support and read the random number without preemption, so a separate query predicate is not practical. Since this part of the generic interface is unused, remove it. Signed-off-by: Richard Henderson --- include/linux/random.h

[PATCH v2 03/10] s390: Remove arch_has_random, arch_has_random_seed

2019-11-06 Thread Richard Henderson
These symbols are currently part of the generic archrandom.h interface, but are currently unused and can be removed. Signed-off-by: Richard Henderson --- arch/s390/include/asm/archrandom.h | 12 1 file changed, 12 deletions(-) diff --git a/arch/s390/include/asm/archrandom.h b

[PATCH v2 02/10] powerpc: Remove arch_has_random, arch_has_random_seed

2019-11-06 Thread Richard Henderson
These symbols are currently part of the generic archrandom.h interface, but are currently unused and can be removed. Signed-off-by: Richard Henderson --- arch/powerpc/include/asm/archrandom.h | 10 -- 1 file changed, 10 deletions(-) diff --git a/arch/powerpc/include/asm/archrandom.h b

[PATCH v2 01/10] x86: Remove arch_has_random, arch_has_random_seed

2019-11-06 Thread Richard Henderson
Use the expansion of these macros directly in arch_get_random_*. These symbols are currently part of the generic archrandom.h interface, but are currently unused and can be removed. Signed-off-by: Richard Henderson --- arch/x86/include/asm/archrandom.h | 12 1 file changed, 4

[PATCH v2 00/10] Improvements for random.h/archrandom.h

2019-11-06 Thread Richard Henderson
different architectures, e.g. powerpc isn't using bool. Change since v1: * Remove arch_has_random, arch_has_random_seed. r~ Richard Henderson (10): x86: Remove arch_has_random, arch_has_random_seed powerpc: Remove arch_has_random, arch_has_random_seed s390: Remove arch_has_r

Re: [PATCH 6/6] s390x: Mark archrandom.h functions __must_check

2019-10-29 Thread Richard Henderson
On 10/29/19 8:26 AM, Harald Freudenberger wrote: > Fine with me, Thanks, reviewed, build and tested. > You may add my reviewed-by: Harald Freudenberger > However, will this go into the kernel tree via crypto or s390 subsystem ? That's an excellent question. As an API decision, perhaps going via

[PATCH 6/6] s390x: Mark archrandom.h functions __must_check

2019-10-28 Thread Richard Henderson
We cannot use the pointer output without validating the success of the random read. Signed-off-by: Richard Henderson --- Cc: Heiko Carstens Cc: Vasily Gorbik Cc: Christian Borntraeger --- arch/s390/include/asm/archrandom.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff

[PATCH 3/6] x86: Mark archrandom.h functions __must_check

2019-10-28 Thread Richard Henderson
We cannot use the pointer output without validating the success of the random read. Signed-off-by: Richard Henderson --- Cc: Thomas Gleixner Cc: Ingo Molnar Cc: Borislav Petkov Cc: "H. Peter Anvin" --- arch/x86/include/asm/archrandom.h | 16 1 file changed, 8

[PATCH 2/6] x86: Move arch_has_random* inside CONFIG_ARCH_RANDOM

2019-10-28 Thread Richard Henderson
These functions are declared generically without CONFIG_ARCH_RANDOM. The only reason this compiles for x86 is that we currently have a mix of inline functions are preprocessor defines. Signed-off-by: Richard Henderson --- Cc: Thomas Gleixner Cc: Ingo Molnar Cc: Borislav Petkov Cc: "H.

[PATCH 1/6] random: Mark CONFIG_ARCH_RANDOM functions __must_check

2019-10-28 Thread Richard Henderson
We cannot use the pointer output without validating the success of the random read. Signed-off-by: Richard Henderson --- Cc: Kees Cook Cc: "H. Peter Anvin" Cc: linux-a...@vger.kernel.org --- include/linux/random.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) di

[PATCH 5/6] powerpc: Mark archrandom.h functions __must_check

2019-10-28 Thread Richard Henderson
We cannot use the pointer output without validating the success of the random read. Signed-off-by: Richard Henderson --- Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Michael Ellerman --- arch/powerpc/include/asm/archrandom.h | 8 1 file changed, 4 insertions(+), 4 deletions

[PATCH 0/6] Improvements for random.h/archrandom.h

2019-10-28 Thread Richard Henderson
noticed a few other minor inconsistencies between the different architectures: x86 defines some functional macros outside CONFIG_ARCH_RANDOM, and powerpc isn't using bool. r~ Richard Henderson (6): random: Mark CONFIG_ARCH_RANDOM functions __must_check x86: Move arch_has_random* i

[PATCH 4/6] powerpc: Use bool in archrandom.h

2019-10-28 Thread Richard Henderson
The generic interface uses bool not int; match that. Signed-off-by: Richard Henderson --- Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Michael Ellerman --- arch/powerpc/include/asm/archrandom.h | 24 +--- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git

Re: [PATCH 4/7] alpha: provide ioread64 and iowrite64 implementations

2017-06-22 Thread Richard Henderson
On 06/22/2017 09:48 AM, Logan Gunthorpe wrote: Alpha implements its own io operation and doesn't use the common library. Thus to make ioread64 and iowrite64 globally available we need to add implementations for alpha. For this, we simply use calls that chain two 32-bit operations. (mostly becaus

Re: [PATCH] tty: add TIOCGPTPEER ioctl

2017-06-01 Thread Richard Henderson
On 06/01/2017 01:00 PM, Aleksa Sarai wrote: --- a/arch/alpha/include/uapi/asm/ioctls.h +++ b/arch/alpha/include/uapi/asm/ioctls.h @@ -94,6 +94,7 @@ #define TIOCSRS485 _IOWR('T', 0x2F, struct serial_rs485) #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux d

Re: [RFC PATCH 00/13] Introduce first class virtual address spaces

2017-03-13 Thread Richard Henderson
On 03/14/2017 10:39 AM, Till Smejkal wrote: Is this an indication that full virtual address spaces are useless? It would seem like if you only use virtual address segments then you avoid all of the problems with executing code, active stacks, and brk. What do you mean with *virtual address seg

Re: [RFC PATCH 00/13] Introduce first class virtual address spaces

2017-03-13 Thread Richard Henderson
On 03/14/2017 08:14 AM, Till Smejkal wrote: At the current state of the development, first class virtual address spaces have one limitation, that we haven't been able to solve so far. The feature allows, that different threads of the same process can execute in different AS at the same time. This

Re: Ping Re: [PATCH 0/8] math-emu: Update kernel math-emu code from current glibc soft-fp

2015-08-26 Thread Richard Henderson
thing* from the other maintainers. Ping again for the other-architecture maintainers (alpha, s390, sh, sparc) I thought I already gave an Acked-by: Richard Henderson for the alpha patches. r~ ___ Linuxppc-dev mailing list Linuxppc-dev@lists.o

Re: bit fields && data tearing

2014-07-15 Thread Richard Henderson
On 07/15/2014 06:54 AM, Peter Hurley wrote: > > Jonathan Corbet wrote a LWN article about this back in 2012: > http://lwn.net/Articles/478657/ > > I guess it's fixed in gcc 4.8, but too bad there's not a workaround for > earlier compilers (akin to -fstrict_volatile_bitfields without requiring > t

Accumulating PPC_FEATURE_ARCH bits

2013-02-18 Thread Richard Henderson
If one wants to test the PPC_FEATURE_ARCH_ISA_2_0[56] bits, one has to be careful that if 2_06 is set, 2_05 won't be. This seems illogical to me: given that 2.06 includes all of the 2.05 instructions, it would make most sense if both bits were set in the hwcap. Now, obviously I have to code a

Re: [PATCH 01/10] Add support for GCC-4.5's __builtin_unreachable() to compiler.h

2009-09-10 Thread Richard Henderson
On 09/10/2009 04:56 PM, David Daney wrote: +#ifndef unreachable +# define unreachable() do { for (;;) ; } while (0) +#endif #define unreachable() do { } while (1) r~ ___ Linuxppc-dev mailing list Linuxppc-dev@lists.ozlabs.org https://lists.ozlabs.or

Re: [PATCH] powerpc: Fix bug in __futex_atomic_op

2009-04-14 Thread Richard Henderson
Paul Mackerras wrote: Can anyone see any reason why the FUTEX_OP_SET case can't just do a __put_user? Because you need to return the old value. Despite the name, it's an exchange operation not a set. r~ ___ Linuxppc-dev mailing list Linuxppc-dev@oz

Re: alpha: half done futex implementation

2009-04-13 Thread Richard Henderson
Andreas Schwab wrote: Richard Henderson writes: switch (op) { case FUTEX_OP_SET: __futex_atomic_op("mov %0,%1", ret, oldval, uaddr, oparg); That should probably be "mov %4,%1\n"? You're right. r~ ___

Re: alpha: half done futex implementation

2009-04-13 Thread Richard Henderson
Matt Turner wrote: Hi, Going on Richard's advice, I've tried to write an alpha futex implementation based on the powerpc futex.h. I've gotten this far.. :\ #define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ __asm__ __volatile( \ __ASM_MB