e500mc.c (ae19b15d917887a450787de6f5c8f26a16d3fba9) | e500mc.c (81a1cf9f89a6b71e71bfd7d43837ce9235e70b38) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (C) 2010,2012 Freescale Semiconductor, Inc. All rights reserved. 4 * 5 * Author: Varun Sethi, <varun.sethi@freescale.com> 6 * 7 * Description: 8 * This file is derived from arch/powerpc/kvm/e500.c, --- 390 unchanged lines hidden (view full) --- 399 /* 400 * Use two lpids per VM on dual threaded processors like e6500 401 * to workarround the lack of tlb write conditional instruction. 402 * Expose half the number of available hardware lpids to the lpid 403 * allocator. 404 */ 405 kvmppc_init_lpid(KVMPPC_NR_LPIDS/threads_per_core); 406 | 1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (C) 2010,2012 Freescale Semiconductor, Inc. All rights reserved. 4 * 5 * Author: Varun Sethi, <varun.sethi@freescale.com> 6 * 7 * Description: 8 * This file is derived from arch/powerpc/kvm/e500.c, --- 390 unchanged lines hidden (view full) --- 399 /* 400 * Use two lpids per VM on dual threaded processors like e6500 401 * to workarround the lack of tlb write conditional instruction. 402 * Expose half the number of available hardware lpids to the lpid 403 * allocator. 404 */ 405 kvmppc_init_lpid(KVMPPC_NR_LPIDS/threads_per_core); 406 |
407 r = kvm_init(NULL, sizeof(struct kvmppc_vcpu_e500), 0, THIS_MODULE); | 407 r = kvm_init(sizeof(struct kvmppc_vcpu_e500), 0, THIS_MODULE); |
408 if (r) 409 goto err_out; 410 kvm_ops_e500mc.owner = THIS_MODULE; 411 kvmppc_pr_ops = &kvm_ops_e500mc; 412 413err_out: 414 return r; 415} 416 417static void __exit kvmppc_e500mc_exit(void) 418{ 419 kvmppc_pr_ops = NULL; 420 kvmppc_booke_exit(); 421} 422 423module_init(kvmppc_e500mc_init); 424module_exit(kvmppc_e500mc_exit); 425MODULE_ALIAS_MISCDEV(KVM_MINOR); 426MODULE_ALIAS("devname:kvm"); | 408 if (r) 409 goto err_out; 410 kvm_ops_e500mc.owner = THIS_MODULE; 411 kvmppc_pr_ops = &kvm_ops_e500mc; 412 413err_out: 414 return r; 415} 416 417static void __exit kvmppc_e500mc_exit(void) 418{ 419 kvmppc_pr_ops = NULL; 420 kvmppc_booke_exit(); 421} 422 423module_init(kvmppc_e500mc_init); 424module_exit(kvmppc_e500mc_exit); 425MODULE_ALIAS_MISCDEV(KVM_MINOR); 426MODULE_ALIAS("devname:kvm"); |