lkml.org 
[lkml]   [2015]   [Feb]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RESEND PATCH v2 5/9] mfd: rtsx: update phy register
    On Thu, 22 Jan 2015, micky_ching@realsil.com.cn wrote:

    > From: Micky Ching <micky_ching@realsil.com.cn>
    >
    > update phy register value and using direct value instead of macros.
    > It is much easier to debug using constant value than a lot of macros.
    > We usually need compare the value directly to check the configure.

    This is no longer an adequate description of the patch.

    > Signed-off-by: Micky Ching <micky_ching@realsil.com.cn>
    > ---
    > drivers/mfd/rts5249.c | 55 ++++++++++++----------
    > include/linux/mfd/rtsx_pci.h | 109 ++++++++++++++++++++++---------------------
    > 2 files changed, 85 insertions(+), 79 deletions(-)
    >
    > diff --git a/drivers/mfd/rts5249.c b/drivers/mfd/rts5249.c
    > index 2fe2854..d8072f6 100644
    > --- a/drivers/mfd/rts5249.c
    > +++ b/drivers/mfd/rts5249.c
    > @@ -132,57 +132,62 @@ static int rts5249_optimize_phy(struct rtsx_pcr *pcr)
    > if (err < 0)
    > return err;
    >
    > - err = rtsx_pci_write_phy_register(pcr, PHY_REG_REV,
    > - PHY_REG_REV_RESV | PHY_REG_REV_RXIDLE_LATCHED |
    > - PHY_REG_REV_P1_EN | PHY_REG_REV_RXIDLE_EN |
    > - PHY_REG_REV_RX_PWST | PHY_REG_REV_CLKREQ_DLY_TIMER_1_0 |
    > - PHY_REG_REV_STOP_CLKRD | PHY_REG_REV_STOP_CLKWR);
    > + err = rtsx_pci_write_phy_register(pcr, PHY_REV,
    > + PHY_REV_RESV | PHY_REV_RXIDLE_LATCHED |
    > + PHY_REV_P1_EN | PHY_REV_RXIDLE_EN |
    > + PHY_REV_CLKREQ_TX_EN | PHY_REV_RX_PWST |
    > + PHY_REV_CLKREQ_DT_1_0 | PHY_REV_STOP_CLKRD |
    > + PHY_REV_STOP_CLKWR);

    The tabbing changes make it difficult to see what you're _really_
    doing. If you think the tabs are important (I think they were better
    before personally), then send them as a separate patch.

    > if (err < 0)
    > return err;
    >
    > msleep(1);
    >
    > err = rtsx_pci_write_phy_register(pcr, PHY_BPCR,
    > - PHY_BPCR_IBRXSEL | PHY_BPCR_IBTXSEL |
    > - PHY_BPCR_IB_FILTER | PHY_BPCR_CMIRROR_EN);
    > + PHY_BPCR_IBRXSEL | PHY_BPCR_IBTXSEL |
    > + PHY_BPCR_IB_FILTER | PHY_BPCR_CMIRROR_EN);

    More nonsense?

    > if (err < 0)
    > return err;
    > +
    > err = rtsx_pci_write_phy_register(pcr, PHY_PCR,
    > - PHY_PCR_FORCE_CODE | PHY_PCR_OOBS_CALI_50 |
    > - PHY_PCR_OOBS_VCM_08 | PHY_PCR_OOBS_SEN_90 |
    > - PHY_PCR_RSSI_EN);
    > + PHY_PCR_FORCE_CODE | PHY_PCR_OOBS_CALI_50 |
    > + PHY_PCR_OOBS_VCM_08 | PHY_PCR_OOBS_SEN_90 |
    > + PHY_PCR_RSSI_EN | PHY_PCR_RX10K);

    Etc.

    I'm going to stop here. Please resubmit this patch properly.

    [...]

    --
    Lee Jones
    Linaro STMicroelectronics Landing Team Lead
    Linaro.org │ Open source software for ARM SoCs
    Follow Linaro: Facebook | Twitter | Blog


    \
     
     \ /
      Last update: 2015-02-16 15:21    [W:4.693 / U:0.172 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site