Re: [PATCH v3 5/5] spi: imx: drop useless member speed_hz from driver data struct

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2018-11-30 at 18:50 +0100, Uwe Kleine-König wrote:
> Hello Trent,
> 
> On Fri, Nov 30, 2018 at 05:21:40PM +0000, Trent Piepho wrote:
> > On Fri, 2018-11-30 at 07:47 +0100, Uwe Kleine-König wrote:
> > > The driver data's member variable just caches the transfer's speed_hz
> > > member. All users of the former now have access directly to the latter.
> > > So fix them to use the uncached value and remove the cache.
> > 
> > What should have been done with this is to compare the next transfer's
> > speed_hz to this cached value, and not preprogram the clock if it has
> > not changed.  Since usually it doesn't change between transfers.
> 
> Hmm, yes, this could be done, but I'm not sure the additional effort
> brings a performance advantage. If you have the energy to do test that,
> feel free to implement it, preferably on top of my cleanup commit.

I did this for the imx23 spi driver[1], commit a560943ead, and it more
than double the transfer speed.  That's a much slower CPU than
imx6/7/8, but it could still be a pretty good improvement on something
slow like imx27.

[1] Confusingly, imx23 and imx28 are totally different chips that other
imx chips, like imx21 and imx27.  The former are "mxs" designs that
Freescale bought from someone else (I think ST-Micro?).




[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux