public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Nishanth Menon <nm@ti.com>
To: Francesco Dolcini <francesco@dolcini.it>
Cc: Tom Rini <trini@konsulko.com>,
	Neha Malcom Francis <n-francis@ti.com>,
	Bryan Brattlof <bb@ti.com>, Praneeth Bajjuri <praneeth@ti.com>,
	Andrew Davis <afd@ti.com>,
	Robert Nelson <robertcnelson@gmail.com>,
	Vignesh R <vigneshr@ti.com>, <u-boot@lists.denx.de>
Subject: Re: [PATCH 3/6] board: ti: am62x: Add basic initialization for usb voltage, 32k crystal, debounce
Date: Wed, 26 Jul 2023 06:10:19 -0500	[thread overview]
Message-ID: <20230726111019.gotprceqsrmpwgyg@stopwatch> (raw)
In-Reply-To: <ZMBOONYlgGWMVK7h@francesco-nb.int.toradex.com>

On 00:35-20230726, Francesco Dolcini wrote:
[...]
> > > 
> > > At least the ones we have currently (I am not sure about toradex,
> > > phytech etc), seem to operate the vdd_core at 0.85V .. (which is what
> > > USB is dependent upon).
> > 
> > For Toradex, we do have the equivalent code in our board file, see 
> > https://git.toradex.com/cgit/u-boot-toradex.git/tree/board/toradex/verdin-am62/verdin-am62.c?h=toradex_ti-u-boot-2023.04#n92
> > 
> > The 32kHz configuration is just different for us, we do not re-use the
> > same you have here.

True, you are hitting the bypass control and not powering on the
oscillator control since the 32k is incoming from RTC, in my case, since
I have an actual 32k crystal, I am clearing the powerdown.


> > 
> > The debounce conf registers I have no idea what they are about,
> > something we should have also on our board? Any additional details?
> 
> So, I got curious and checked on the datasheet/TRM on this debounce. If
> I understood correctly this is to have debounce on GPIO and/or EQEP.

Typically, yes - input signals more useful for eQEP or GPIO. but the
implementation is at pin level which, technically could be used for
other purposes (but I have'nt seen any).

> 
> However to my understanding this would need to have the corresponding
> DEBOUNCE_SEL register written on the pad configuration, and by default it's 0.
> 
> What's the use case for this debounce configuration you have here?

TRM was a bit of a crap (internal ticket was filed to improve), but long
story short:
* bootloader configures delays per index
* in the pinmux configuration, we pick which index to use for the pin

On Beagleplay, for example, the HDMI hot plug detect GPIO benefited from
this[1]. Corresponding pinctrl.h macros were posted in [2].

Why do it in the bootloader? since gpio inputs could also used in u-boot
(e.g. MMC/CD)


All said, Tom's question is very valid - we'd rather not modify evm.c
for these specific configurations (popcorn as they might be), and we
need to figure out a better option to introduce this kind of variation
cleanly. For now, I will try dropping this patch.


[1] https://git.beagleboard.org/beagleboard/linux/-/blob/v6.1.33-ti-rt-arm64-r6/arch/arm64/boot/dts/ti/k3-am625-beagleplay.dts#L311
[2] https://lore.kernel.org/all/20230619131620.3286650-1-nm@ti.com/

-- 
Regards,
Nishanth Menon
Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3  1A34 DDB5 849D 1736 249D

  reply	other threads:[~2023-07-26 20:26 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-25 18:52 [PATCH 0/6] board: ti: Add support for BeaglePlay Nishanth Menon
2023-07-25 18:52 ` [PATCH 1/6] doc: board: ti: k3: Sort the boards in alphabetical order Nishanth Menon
2023-07-25 21:23   ` Tom Rini
2023-07-25 18:52 ` [PATCH 2/6] arm: dts: k3-am625-sk-binman: Add labels for unsigned binary Nishanth Menon
2023-07-25 21:23   ` Tom Rini
2023-07-25 18:52 ` [PATCH 3/6] board: ti: am62x: Add basic initialization for usb voltage, 32k crystal, debounce Nishanth Menon
2023-07-25 21:25   ` Tom Rini
2023-07-25 21:37     ` Nishanth Menon
2023-07-25 21:42       ` Tom Rini
2023-07-25 22:03         ` Nishanth Menon
2023-07-25 22:16           ` Francesco Dolcini
2023-07-25 22:35             ` Francesco Dolcini
2023-07-26 11:10               ` Nishanth Menon [this message]
2023-07-26 13:29                 ` Francesco Dolcini
2024-01-07 10:54                 ` Jan Kiszka
2023-07-25 18:52 ` [PATCH 4/6] arm: dts: Add k3-am625-beagleplay Nishanth Menon
2023-07-25 21:25   ` Tom Rini
2023-07-25 18:52 ` [PATCH 5/6] configs: Add am62x_beagleplay_* defconfigs Nishanth Menon
2023-07-25 18:52 ` [PATCH 6/6] doc: board: ti: Add beagleplay documentation Nishanth Menon
2023-07-25 21:35   ` Tom Rini
2023-07-25 22:00     ` Nishanth Menon
2023-07-25 22:45       ` Tom Rini
2023-07-26 14:59         ` Andrew Davis
2023-07-26 16:21           ` Tom Rini
2023-07-26 16:41             ` Andrew Davis
2023-07-26 16:49               ` Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230726111019.gotprceqsrmpwgyg@stopwatch \
    --to=nm@ti.com \
    --cc=afd@ti.com \
    --cc=bb@ti.com \
    --cc=francesco@dolcini.it \
    --cc=n-francis@ti.com \
    --cc=praneeth@ti.com \
    --cc=robertcnelson@gmail.com \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=vigneshr@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox