diff options
author | Vaibhav Jain <vaibhav@linux.ibm.com> | 2019-01-13 11:07:10 +0530 |
---|---|---|
committer | Stewart Smith <stewart@linux.ibm.com> | 2019-01-16 00:46:49 -0600 |
commit | 763f397d5be7580e3ecf525ca5939f3ab9f6ff5d (patch) | |
tree | 33afb23fc038cde0d3ec877ec1c00b0d18a2b7a1 /include/chip.h | |
parent | 9d2d0115eaca5d92e8032f3c051a200e59e80971 (diff) | |
download | skiboot-763f397d5be7580e3ecf525ca5939f3ab9f6ff5d.zip skiboot-763f397d5be7580e3ecf525ca5939f3ab9f6ff5d.tar.gz skiboot-763f397d5be7580e3ecf525ca5939f3ab9f6ff5d.tar.bz2 |
capp/phb: Introduce 'struct capp' to hold capp related info in 'struct phb'
Previously struct proc_chip member 'capp_phb3_attached_mask' was used
for Power-8 to keep track of PHB attached to the single CAPP on the
chip. CAPP on that chip supported a flexible PHB assignment
scheme. However since then new chips only support a static assignment
i.e a CAPP can only be attached to a specific PEC.
Hence instead of using 'proc_chip.capp_phb4_attached_mask' to manage
CAPP <-> PEC assignments which needs a global lock (capi_lock) to be
updated, we introduce a new struct named 'capp' a pointer to which
resides inside struct 'phb4'. Since updates to struct 'phb4' already
happen in context of phb_lock; this eliminates the
need to use mutex 'capi_lock' while updating
'capp_phb4_attached_mask'.
This struct is also used to hold CAPP specific variables such as
pointer to the 'struct phb' to which the CAPP is attached,
'capp_xscom_offset' which is the xscom offset to be added to CAPP
registers in case there are more than 1 on the chip, 'capp_index'
which is the index of the CAPP on the chip, and attached_pe' which is
the process endpoint index to which CAPP is attached. Finally member
'chip_id' holds the chip-id thats used for performing xscom
read/writes.
Also new helpers named capp_xscom_read()/write() are introduced to
make access to CAPP xscom registers easier.
Signed-off-by: Vaibhav Jain <vaibhav@linux.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Reviewed-by: Christophe Lombard <clombard@linux.vnet.ibm.com>
Reviewed-by: Frederic Barrat <fbarrat@linux.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
Diffstat (limited to 'include/chip.h')
-rw-r--r-- | include/chip.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/include/chip.h b/include/chip.h index 2fb8126..c759d0a 100644 --- a/include/chip.h +++ b/include/chip.h @@ -197,7 +197,6 @@ struct proc_chip { /* Must hold capi_lock to change */ uint8_t capp_phb3_attached_mask; - uint8_t capp_phb4_attached_mask; uint8_t capp_ucode_loaded; /* Used by hw/centaur.c */ |