[U-Boot] [PATCH] spi: prevent overriding established bus settings

Marcin Wojtas mw at semihalf.com
Thu Jan 16 10:55:52 CET 2020


Hi Jagan,

sob., 28 gru 2019 o 03:27 Simon Glass <sjg at chromium.org> napisaƂ(a):
>
> On Thu, 21 Nov 2019 at 04:45, Marcin Wojtas <mw at semihalf.com> wrote:
> >
> > The SPI stack relies on a proper bus speed/mode configuration
> > by calling dm_spi_claim_bus(). However the hitherto code
> > allowed to accidentally override those settings in
> > the spi_get_bus_and_cs() routine.
> >
> > The initially established speed could be discarded by using
> > the slave platdata, which turned out to be an issue on
> > the platforms whose slave maximum supported frequency
> > is not on par with the maximum frequency of the bus controller.
> >
> > This patch fixes above issue by configuring the bus from
> > spi_get_bus_and_cs() only in case it was not done before.
> >
> > Signed-off-by: Marcin Wojtas <mw at semihalf.com>
> > ---
> >  drivers/spi/spi-uclass.c | 20 +++++++++++---------
> >  1 file changed, 11 insertions(+), 9 deletions(-)
>
> Reviewed-by: Simon Glass <sjg at chromium.org>

Is there a chance to merge the patch, or do you have any objections?

Best regards,
Marcin


More information about the U-Boot mailing list