Message ID | 1410568932-21823-1-git-send-email-jay.xu@rock-chips.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Sat, Sep 13, 2014 at 08:42:12AM +0800, Jianqun wrote: > Reference rockchip I2S controller TRM, modify some registers' property > I2S_FIFOLR: read / write, but not volatile, not precious > I2S_INTSR: read / write > I2S_CLR: volatile, register value will be cleared by read Applied, again this is a bug fix (volatile and precious being wrong seem like bugs) so should have been earlier in the series.
Hello. On 9/13/2014 3:42 AM, Jianqun wrote: > Reference rockchip I2S controller TRM, modify some registers' property > I2S_FIFOLR: read / write, but not volatile, not precious > I2S_INTSR: read / write > I2S_CLR: volatile, register value will be cleared by read > Test on RK3288 with max98090. > Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> > --- > sound/soc/rockchip/rockchip_i2s.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c > index 1b9b404..6595383 100644 > --- a/sound/soc/rockchip/rockchip_i2s.c > +++ b/sound/soc/rockchip/rockchip_i2s.c [...] > @@ -385,8 +387,6 @@ static bool rockchip_i2s_volatile_reg(struct device *dev, unsigned int reg) > static bool rockchip_i2s_precious_reg(struct device *dev, unsigned int reg) > { > switch (reg) { > - case I2S_FIFOLR: > - return true; > default: > return false; > } Shouldn't this be folded into simple *return* false now? WBR, Sergei
? 09/14/2014 12:36 AM, Mark Brown ??: > On Sat, Sep 13, 2014 at 08:42:12AM +0800, Jianqun wrote: >> Reference rockchip I2S controller TRM, modify some registers' property >> I2S_FIFOLR: read / write, but not volatile, not precious >> I2S_INTSR: read / write >> I2S_CLR: volatile, register value will be cleared by read > > Applied, again this is a bug fix (volatile and precious being wrong seem > like bugs) so should have been earlier in the series. > ok, I'll re-order the patches
? 09/14/2014 04:57 AM, Sergei Shtylyov ??: > Hello. > > On 9/13/2014 3:42 AM, Jianqun wrote: > >> Reference rockchip I2S controller TRM, modify some registers' property >> I2S_FIFOLR: read / write, but not volatile, not precious >> I2S_INTSR: read / write >> I2S_CLR: volatile, register value will be cleared by read > >> Test on RK3288 with max98090. > >> Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> >> --- >> sound/soc/rockchip/rockchip_i2s.c | 6 +++--- >> 1 file changed, 3 insertions(+), 3 deletions(-) > >> diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c >> index 1b9b404..6595383 100644 >> --- a/sound/soc/rockchip/rockchip_i2s.c >> +++ b/sound/soc/rockchip/rockchip_i2s.c > [...] >> @@ -385,8 +387,6 @@ static bool rockchip_i2s_volatile_reg(struct device *dev, unsigned int reg) >> static bool rockchip_i2s_precious_reg(struct device *dev, unsigned int reg) >> { >> switch (reg) { >> - case I2S_FIFOLR: >> - return true; >> default: >> return false; >> } > > Shouldn't this be folded into simple *return* false now? That is more reasonable, thank you. > > WBR, Sergei > > > > >
Hello. On 09/14/2014 06:29 AM, Jianqun wrote: >>> Reference rockchip I2S controller TRM, modify some registers' property >>> I2S_FIFOLR: read / write, but not volatile, not precious >>> I2S_INTSR: read / write >>> I2S_CLR: volatile, register value will be cleared by read >>> Test on RK3288 with max98090. >>> Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> >>> --- >>> sound/soc/rockchip/rockchip_i2s.c | 6 +++--- >>> 1 file changed, 3 insertions(+), 3 deletions(-) >>> diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c >>> index 1b9b404..6595383 100644 >>> --- a/sound/soc/rockchip/rockchip_i2s.c >>> +++ b/sound/soc/rockchip/rockchip_i2s.c >> [...] >>> @@ -385,8 +387,6 @@ static bool rockchip_i2s_volatile_reg(struct device *dev, unsigned int reg) >>> static bool rockchip_i2s_precious_reg(struct device *dev, unsigned int reg) >>> { >>> switch (reg) { >>> - case I2S_FIFOLR: >>> - return true; >>> default: >>> return false; >>> } >> Shouldn't this be folded into simple *return* false now? > That is more reasonable, thank you. Moreover, this function may be completely eliminated. WBR, Sergei
diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c index 1b9b404..6595383 100644 --- a/sound/soc/rockchip/rockchip_i2s.c +++ b/sound/soc/rockchip/rockchip_i2s.c @@ -365,6 +365,8 @@ static bool rockchip_i2s_rd_reg(struct device *dev, unsigned int reg) case I2S_XFER: case I2S_CLR: case I2S_RXDR: + case I2S_FIFOLR: + case I2S_INTSR: return true; default: return false; @@ -374,8 +376,8 @@ static bool rockchip_i2s_rd_reg(struct device *dev, unsigned int reg) static bool rockchip_i2s_volatile_reg(struct device *dev, unsigned int reg) { switch (reg) { - case I2S_FIFOLR: case I2S_INTSR: + case I2S_CLR: return true; default: return false; @@ -385,8 +387,6 @@ static bool rockchip_i2s_volatile_reg(struct device *dev, unsigned int reg) static bool rockchip_i2s_precious_reg(struct device *dev, unsigned int reg) { switch (reg) { - case I2S_FIFOLR: - return true; default: return false; }
Reference rockchip I2S controller TRM, modify some registers' property I2S_FIFOLR: read / write, but not volatile, not precious I2S_INTSR: read / write I2S_CLR: volatile, register value will be cleared by read Test on RK3288 with max98090. Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com> --- sound/soc/rockchip/rockchip_i2s.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)