13887d241SBalamuruhan S /* 23887d241SBalamuruhan S * QEMU PowerPC PowerNV Emulation of a few HOMER related registers 33887d241SBalamuruhan S * 43887d241SBalamuruhan S * Copyright (c) 2019, IBM Corporation. 53887d241SBalamuruhan S * 63887d241SBalamuruhan S * This library is free software; you can redistribute it and/or 73887d241SBalamuruhan S * modify it under the terms of the GNU Lesser General Public 83887d241SBalamuruhan S * License as published by the Free Software Foundation; either 9f70c5966SChetan Pant * version 2.1 of the License, or (at your option) any later version. 103887d241SBalamuruhan S * 113887d241SBalamuruhan S * This library is distributed in the hope that it will be useful, 123887d241SBalamuruhan S * but WITHOUT ANY WARRANTY; without even the implied warranty of 133887d241SBalamuruhan S * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 143887d241SBalamuruhan S * Lesser General Public License for more details. 153887d241SBalamuruhan S * 163887d241SBalamuruhan S * You should have received a copy of the GNU Lesser General Public 173887d241SBalamuruhan S * License along with this library; if not, see <http://www.gnu.org/licenses/>. 183887d241SBalamuruhan S */ 193887d241SBalamuruhan S 203887d241SBalamuruhan S #ifndef PPC_PNV_HOMER_H 213887d241SBalamuruhan S #define PPC_PNV_HOMER_H 223887d241SBalamuruhan S 233887d241SBalamuruhan S #include "hw/ppc/pnv.h" 24db1015e9SEduardo Habkost #include "qom/object.h" 253887d241SBalamuruhan S 263887d241SBalamuruhan S #define TYPE_PNV_HOMER "pnv-homer" 27c821774aSEduardo Habkost OBJECT_DECLARE_TYPE(PnvHomer, PnvHomerClass, 2830b5707cSEduardo Habkost PNV_HOMER) 293887d241SBalamuruhan S #define TYPE_PNV8_HOMER TYPE_PNV_HOMER "-POWER8" 308110fa1dSEduardo Habkost DECLARE_INSTANCE_CHECKER(PnvHomer, PNV8_HOMER, 318110fa1dSEduardo Habkost TYPE_PNV8_HOMER) 323887d241SBalamuruhan S #define TYPE_PNV9_HOMER TYPE_PNV_HOMER "-POWER9" 338110fa1dSEduardo Habkost DECLARE_INSTANCE_CHECKER(PnvHomer, PNV9_HOMER, 348110fa1dSEduardo Habkost TYPE_PNV9_HOMER) 3592499676SCédric Le Goater #define TYPE_PNV10_HOMER TYPE_PNV_HOMER "-POWER10" 3692499676SCédric Le Goater DECLARE_INSTANCE_CHECKER(PnvHomer, PNV10_HOMER, 3792499676SCédric Le Goater TYPE_PNV10_HOMER) 383887d241SBalamuruhan S 39db1015e9SEduardo Habkost struct PnvHomer { 403887d241SBalamuruhan S DeviceState parent; 413887d241SBalamuruhan S 42*b6c80037SMarkus Armbruster PnvChip *chip; 438f092316SCédric Le Goater MemoryRegion pba_regs; 443887d241SBalamuruhan S MemoryRegion regs; 45db1015e9SEduardo Habkost }; 463887d241SBalamuruhan S 473887d241SBalamuruhan S 48db1015e9SEduardo Habkost struct PnvHomerClass { 493887d241SBalamuruhan S DeviceClass parent_class; 503887d241SBalamuruhan S 518f092316SCédric Le Goater int pba_size; 528f092316SCédric Le Goater const MemoryRegionOps *pba_ops; 533887d241SBalamuruhan S int homer_size; 543887d241SBalamuruhan S const MemoryRegionOps *homer_ops; 553887d241SBalamuruhan S 563887d241SBalamuruhan S hwaddr core_max_base; 57db1015e9SEduardo Habkost }; 583887d241SBalamuruhan S 593887d241SBalamuruhan S #endif /* PPC_PNV_HOMER_H */ 60