// SPDX-License-Identifier: GPL-2.0 /* * s390 arch random implementation. * * Copyright IBM Corp. 2017 * Author(s): Harald Freudenberger <freude@de.ibm.com> */ #include <linux/kernel.h> #include <linux/atomic.h> #include <linux/random.h> #include <linux/static_key.h> #include <asm/cpacf.h> DEFINE_STATIC_KEY_FALSE(s390_arch_random_available); atomic64_t s390_arch_random_counter = ATOMIC64_INIT(0); EXPORT_SYMBOL(s390_arch_random_counter);
static int __init s390_arch_random_init(void) { /* check if subfunction CPACF_PRNO_TRNG is available */ if (cpacf_query_func(CPACF_PRNO, CPACF_PRNO_TRNG)) static_branch_enable(&s390_arch_random_available); return 0; }Contributors
Person | Tokens | Prop | Commits | CommitProp |
Harald Freudenberger | 28 | 100.00% | 1 | 100.00% |
Total | 28 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Harald Freudenberger | 63 | 92.65% | 1 | 25.00% |
Heiko Carstens | 3 | 4.41% | 1 | 25.00% |
Greg Kroah-Hartman | 2 | 2.94% | 2 | 50.00% |
Total | 68 | 100.00% | 4 | 100.00% |