mbox series

[0/2] sunxi, usb: Clean up SRAM initialization code

Message ID 20230607231644.28203-1-CFSworks@gmail.com
Headers show
Series sunxi, usb: Clean up SRAM initialization code | expand

Message

Sam Edwards June 7, 2023, 11:16 p.m. UTC
Hi list,

This pair of patches is a byproduct of discussion on my earlier patchset
(Patchwork series #357953), which had simply disabled this initialization where
SUNXI_SRAMC_BASE was set to null. It is true that this initialization is not
needed on newer devices, but not because the SRAMC (now called "SYSCON") has
been removed, so a null SRAMC base was not the appropriate fix.

Of the two patches here, only the first is an actual fix; the second is a
mostly-cosmetic cleanup, which also adds a TODO to make this function
independent of SUNXI_SRAMC_BASE altogether, per the aforementioned prior
discussion.

I do not have an A10, A10s, A13, GR8, or A20 against which to test this change;
a reviewer with access to one of these should verify that USB-OTG functionality
is still working. That ought to be a sufficient regression test. :)

A note to committers: If patch 1 is acceptable but patch 2 is not, go ahead and
commit only patch 1 (unless the U-Boot project specifically avoids doing this).

Thanks for your time,
Sam

Sam Edwards (2):
  usb: musb-new: sunxi: only perform SRAM initialization when necessary
  usb: musb-new: sunxi: clarify the purpose of SRAM initialization

 drivers/usb/musb-new/sunxi.c | 33 +++++++++++++++++++++++++--------
 1 file changed, 25 insertions(+), 8 deletions(-)