Message ID | 9a2b8920df291915ac6be0d14e6e9896e81ea9bd.1700221559.git.oleksii.kurochko@gmail.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | Introduce generic headers | expand |
On 17.11.2023 13:24, Oleksii Kurochko wrote: > <asm/random.h> is common for Arm, PPC and RISC-V thereby it > is moved to asm-generic. > > Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com> Reviewed-by: Jan Beulich <jbeulich@suse.com> with ... > --- /dev/null > +++ b/xen/include/asm-generic/random.h > @@ -0,0 +1,20 @@ > +/* SPDX-License-Identifier: GPL-2.0-only */ > +#ifndef __ASM_GENERIC_RANDOM_H__ > +#define __ASM_GENERIC_RANDOM_H__ > + > +static inline unsigned int arch_get_random(void) > +{ > + return 0; > +} > + > +#endif /* __ASM_GENERIC_RANDOM_H__ */ > + > + > +/* ... the double blank lines above here shrunk to a single one. Can likely be done while committing. Jan
Hi Oleksii, On 17/11/2023 12:24, Oleksii Kurochko wrote: > <asm/random.h> is common for Arm, PPC and RISC-V thereby it > is moved to asm-generic. > > Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com> Acked-by: Julien Grall <jgrall@amazon.com> Cheers,
diff --git a/xen/arch/arm/include/asm/Makefile b/xen/arch/arm/include/asm/Makefile index 96e3aa6b6c..cac6d5e3df 100644 --- a/xen/arch/arm/include/asm/Makefile +++ b/xen/arch/arm/include/asm/Makefile @@ -1,4 +1,5 @@ # SPDX-License-Identifier: GPL-2.0-only generic-y += iocap.h generic-y += paging.h +generic-y += random.h generic-y += vm_event.h diff --git a/xen/arch/arm/include/asm/random.h b/xen/arch/arm/include/asm/random.h deleted file mode 100644 index b4acee276b..0000000000 --- a/xen/arch/arm/include/asm/random.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef __ASM_RANDOM_H__ -#define __ASM_RANDOM_H__ - -static inline unsigned int arch_get_random(void) -{ - return 0; -} - -#endif /* __ASM_RANDOM_H__ */ diff --git a/xen/arch/ppc/include/asm/Makefile b/xen/arch/ppc/include/asm/Makefile index 9f5a0dfb31..d8f2a1453c 100644 --- a/xen/arch/ppc/include/asm/Makefile +++ b/xen/arch/ppc/include/asm/Makefile @@ -2,4 +2,5 @@ generic-y += hypercall.h generic-y += iocap.h generic-y += paging.h +generic-y += random.h generic-y += vm_event.h diff --git a/xen/arch/ppc/include/asm/random.h b/xen/arch/ppc/include/asm/random.h deleted file mode 100644 index 2f9e9bbae4..0000000000 --- a/xen/arch/ppc/include/asm/random.h +++ /dev/null @@ -1,9 +0,0 @@ -#ifndef __ASM_PPC_RANDOM_H__ -#define __ASM_PPC_RANDOM_H__ - -static inline unsigned int arch_get_random(void) -{ - return 0; -} - -#endif /* __ASM_PPC_RANDOM_H__ */ diff --git a/xen/include/asm-generic/random.h b/xen/include/asm-generic/random.h new file mode 100644 index 0000000000..cd2307e70b --- /dev/null +++ b/xen/include/asm-generic/random.h @@ -0,0 +1,20 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ +#ifndef __ASM_GENERIC_RANDOM_H__ +#define __ASM_GENERIC_RANDOM_H__ + +static inline unsigned int arch_get_random(void) +{ + return 0; +} + +#endif /* __ASM_GENERIC_RANDOM_H__ */ + + +/* + * Local variables: + * mode: C + * c-file-style: BSD + * c-basic-offset: 4 + * indent-tabs-mode: nil + * End: + */
<asm/random.h> is common for Arm, PPC and RISC-V thereby it is moved to asm-generic. Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com> --- Changes in V3: - Drop Arm and PPC's random.h and switch to asm-generic verison. --- Changes in V2: - update the commit messages --- xen/arch/arm/include/asm/Makefile | 1 + xen/arch/arm/include/asm/random.h | 9 --------- xen/arch/ppc/include/asm/Makefile | 1 + xen/arch/ppc/include/asm/random.h | 9 --------- xen/include/asm-generic/random.h | 20 ++++++++++++++++++++ 5 files changed, 22 insertions(+), 18 deletions(-) delete mode 100644 xen/arch/arm/include/asm/random.h delete mode 100644 xen/arch/ppc/include/asm/random.h create mode 100644 xen/include/asm-generic/random.h