174433bf0SRichard Henderson /* 274433bf0SRichard Henderson * PowerPC cpu parameters for qemu. 374433bf0SRichard Henderson * 474433bf0SRichard Henderson * Copyright (c) 2007 Jocelyn Mayer 574433bf0SRichard Henderson * SPDX-License-Identifier: LGPL-2.0+ 674433bf0SRichard Henderson */ 774433bf0SRichard Henderson 874433bf0SRichard Henderson #ifndef PPC_CPU_PARAM_H 9*4f31b54bSMarkus Armbruster #define PPC_CPU_PARAM_H 1074433bf0SRichard Henderson 1174433bf0SRichard Henderson #ifdef TARGET_PPC64 1274433bf0SRichard Henderson # define TARGET_LONG_BITS 64 1374433bf0SRichard Henderson /* 1474433bf0SRichard Henderson * Note that the official physical address space bits is 62-M where M 1574433bf0SRichard Henderson * is implementation dependent. I've not looked up M for the set of 1674433bf0SRichard Henderson * cpus we emulate at the system level. 1774433bf0SRichard Henderson */ 1874433bf0SRichard Henderson #define TARGET_PHYS_ADDR_SPACE_BITS 62 1974433bf0SRichard Henderson /* 2074433bf0SRichard Henderson * Note that the PPC environment architecture talks about 80 bit virtual 2174433bf0SRichard Henderson * addresses, with segmentation. Obviously that's not all visible to a 2274433bf0SRichard Henderson * single process, which is all we're concerned with here. 2374433bf0SRichard Henderson */ 2474433bf0SRichard Henderson # ifdef TARGET_ABI32 2574433bf0SRichard Henderson # define TARGET_VIRT_ADDR_SPACE_BITS 32 2674433bf0SRichard Henderson # else 2774433bf0SRichard Henderson # define TARGET_VIRT_ADDR_SPACE_BITS 64 2874433bf0SRichard Henderson # endif 2974433bf0SRichard Henderson #else 3074433bf0SRichard Henderson # define TARGET_LONG_BITS 32 3174433bf0SRichard Henderson # define TARGET_PHYS_ADDR_SPACE_BITS 36 3274433bf0SRichard Henderson # define TARGET_VIRT_ADDR_SPACE_BITS 32 3374433bf0SRichard Henderson #endif 3474433bf0SRichard Henderson #define TARGET_PAGE_BITS 12 3574433bf0SRichard Henderson #define NB_MMU_MODES 10 3674433bf0SRichard Henderson 3774433bf0SRichard Henderson #endif 38