[PATCH] ARM: k3: beagleplay: Enable 32k crystal
Sascha Hauer
s.hauer at pengutronix.de
Thu Jun 12 00:40:57 PDT 2025
On Wed, Jun 11, 2025 at 08:24:22PM +0200, Ahmad Fatoum wrote:
> Hello Lars,
>
> On 6/11/25 11:36, Lars Schmidt wrote:
> > Signed-off-by: Lars Schmidt <l.schmidt at pengutronix.de>
>
> Would it make sense to describe the existence of the external 32K
> crystal in the DT, so we don't need to add code for every board?
Yes. For now it's ok though.
Sascha
>
> Thanks,
> Ahmad
>
> > ---
> > arch/arm/boards/beagleplay/Makefile | 1 +
> > arch/arm/boards/beagleplay/board.c | 30 +++++++++++++++++++++++++++++
> > 2 files changed, 31 insertions(+)
> > create mode 100644 arch/arm/boards/beagleplay/board.c
> >
> > diff --git a/arch/arm/boards/beagleplay/Makefile b/arch/arm/boards/beagleplay/Makefile
> > index a8c7320bdb..2d257fb4b2 100644
> > --- a/arch/arm/boards/beagleplay/Makefile
> > +++ b/arch/arm/boards/beagleplay/Makefile
> > @@ -1,2 +1,3 @@
> > pbl-y += lowlevel.o
> > +obj-y += board.o
> > pbl-$(CONFIG_MACH_K3_CORTEX_R5) += entry-r5.o ddr.o
> > diff --git a/arch/arm/boards/beagleplay/board.c b/arch/arm/boards/beagleplay/board.c
> > new file mode 100644
> > index 0000000000..dd42f0b7f0
> > --- /dev/null
> > +++ b/arch/arm/boards/beagleplay/board.c
> > @@ -0,0 +1,30 @@
> > +// SPDX-License-Identifier: GPL-2.0-only
> > +
> > +#define pr_fmt(fmt) "beagleplay: " fmt
> > +
> > +#include <linux/kernel.h>
> > +#include <mach/k3/common.h>
> > +#include <driver.h>
> > +#include <bbu.h>
> > +
> > +static int beagleplay_probe(struct device *dev)
> > +{
> > + am625_enable_32k_crystal();
> > +
> > + return 0;
> > +}
> > +
> > +static __maybe_unused struct of_device_id beagleplay_ids[] = {
> > + {
> > + .compatible = "beagle,am625-beagleplay",
> > + }, {
> > + /* sentinel */
> > + }
> > +};
> > +
> > +static struct driver beagleplay_driver = {
> > + .name = "beagleplay",
> > + .probe = beagleplay_probe,
> > + .of_compatible = beagleplay_ids,
> > +};
> > +coredevice_platform_driver(beagleplay_driver);
>
> --
> Pengutronix e.K. | |
> Steuerwalder Str. 21 | http://www.pengutronix.de/ |
> 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
>
>
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list