aboutsummaryrefslogtreecommitdiff
path: root/hw/phb3.c
diff options
context:
space:
mode:
authorChristophe Lombard <clombard@linux.vnet.ibm.com>2017-06-13 14:21:18 +0200
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-06-19 14:49:29 +1000
commit20cf0c833bcfd5bc159a891c852f6de9313deffe (patch)
treeff47d86c7814086dea83ce56a8a086e3189bb2a1 /hw/phb3.c
parent5e55f0b5e0791eae54da39dfeff38f57a3dcbfa4 (diff)
downloadskiboot-20cf0c833bcfd5bc159a891c852f6de9313deffe.zip
skiboot-20cf0c833bcfd5bc159a891c852f6de9313deffe.tar.gz
skiboot-20cf0c833bcfd5bc159a891c852f6de9313deffe.tar.bz2
capi: Externalize capp timebase synchronization
Externalize the chiptod code. this code will be common for PHB3 and PHB4. The reference to the structure PHB3 is remove and new arguments appear due to specific address registers. Signed-off-by: Christophe Lombard <clombard@linux.vnet.ibm.com> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Reviewed-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/phb3.c')
-rw-r--r--hw/phb3.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/hw/phb3.c b/hw/phb3.c
index 2b036a5..df92df8 100644
--- a/hw/phb3.c
+++ b/hw/phb3.c
@@ -3717,7 +3717,8 @@ static int64_t enable_capi_mode(struct phb3 *p, uint64_t pe_number, bool dma_mod
phb3_init_capp_regs(p, dma_mode);
- if (!chiptod_capp_timebase_sync(p)) {
+ if (!chiptod_capp_timebase_sync(p->chip_id, CAPP_TFMR, CAPP_TB,
+ PHB3_CAPP_REG_OFFSET(p))) {
PHBERR(p, "CAPP: Failed to sync timebase\n");
return OPAL_HARDWARE;
}