[Skiboot] [PATCH] capi: Enable channel tag streaming for PHB in CAPP mode
christophe lombard
clombard at linux.vnet.ibm.com
Wed Jan 31 22:33:59 AEDT 2018
Le 31/01/2018 à 07:52, Vaibhav Jain a écrit :
> We re-enable channel tag streaming for PHB in CAPP mode as without it
> PEC was waiting for cresp for each DMA write command before sending a
> new DMA write command on the Powerbus. This resulted in much lower DMA
> write performance than expected.
>
> The patch updates enable_capi_mode() to remove the masking of
> channel_streaming_en bit in PBCQ Hardware Configuration Register. Also
> does some re-factoring of the code that updates this register to use
> xscom_write_mask instead of xscom_read followed by a xscom_write.
>
> Cc: stable
> Signed-off-by: Vaibhav Jain <vaibhav at linux.vnet.ibm.com>
> ---
> hw/phb4.c | 12 ++++--------
> 1 file changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/hw/phb4.c b/hw/phb4.c
> index ff912e1f..4906caf4 100644
> --- a/hw/phb4.c
> +++ b/hw/phb4.c
> @@ -3793,14 +3793,10 @@ static int64_t enable_capi_mode(struct phb4 *p, uint64_t pe_number,
> reg |= dma_eng;
> xscom_write(p->chip_id, p->pe_xscom + XPEC_NEST_CAPP_CNTL, reg);
>
> - /* PCI to PB data movement ignores the PB init signal.
> - * Disable streaming.
> - */
> - xscom_read(p->chip_id, p->pe_xscom + XPEC_NEST_PBCQ_HW_CONFIG, ®);
> - reg |= XPEC_NEST_PBCQ_HW_CONFIG_PBINIT;
> - if (p->index == CAPP0_PHB_INDEX)
> - reg &= ~XPEC_NEST_PBCQ_HW_CONFIG_CH_STR;
> - xscom_write(p->chip_id, p->pe_xscom + XPEC_NEST_PBCQ_HW_CONFIG, reg);
> + /* PCI to PB data movement ignores the PB init signal. */
> + xscom_write_mask(p->chip_id, p->pe_xscom + XPEC_NEST_PBCQ_HW_CONFIG,
> + XPEC_NEST_PBCQ_HW_CONFIG_PBINIT,
> + XPEC_NEST_PBCQ_HW_CONFIG_PBINIT);
>
> /* PEC Phase 4 (PHB) registers adjustment
> * Inbound CAPP traffic: The CAPI can send both CAPP packets and
>
PEC2 in not impacted by this patch as the channel tag streaming is
enabled by default.
Reviewed-by: Christophe Lombard clombard at linux.vnet.ibm.com
More information about the Skiboot
mailing list