mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Renaud Barbier <Renaud.Barbier@ametek.com>
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>,
	Barebox List <barebox@lists.infradead.org>
Subject: Re: Subject: [PATCH 1/3] ARM:lib32: add architected timer
Date: Fri, 3 Mar 2023 12:57:41 +0100	[thread overview]
Message-ID: <20230303115741.GU32097@pengutronix.de> (raw)
In-Reply-To: <BL0PR07MB56650B290C9598A267BFF8A3ECB39@BL0PR07MB5665.namprd07.prod.outlook.com>

On Fri, Mar 03, 2023 at 09:23:13AM +0000, Renaud Barbier wrote:
> > On 01.03.23 17:59, Renaud Barbier wrote:
> > > Subject: [PATCH 1/3] ARM:lib32: add architected timer
> > >
> > > In preparation for the introduction of the LS1021A support, add a
> > > specific timer support based on the LS1046A support so that delays can
> > > be used in the PBL.
> > >
> > > Signed-off-by: Renaud Barbier <renaud.barbier@ametek.com>
> > > ---
> > >  arch/arm/lib32/Makefile |  1 +
> > >  arch/arm/lib32/pbl.c    | 17 +++++++++++++++++
> > >  include/clock.h         |  2 ++
> > >  3 files changed, 20 insertions(+)
> > >  create mode 100644 arch/arm/lib32/pbl.c
> > >
> > > diff --git a/arch/arm/lib32/Makefile b/arch/arm/lib32/Makefile index
> > > 82507fffc0..1be8d70c45 100644
> > > --- a/arch/arm/lib32/Makefile
> > > +++ b/arch/arm/lib32/Makefile
> > > @@ -31,6 +31,7 @@ extra-y += barebox.lds
> > >  pbl-y        += lib1funcs.o
> > >  pbl-y        += ashldi3.o
> > >  pbl-y        += div0.o
> > > +pbl-y        += pbl.o
> > 
> > I think we need a CFLAGS_pbl.o := -march=armv7-a here, otherwise this would
> > break builds of non-ARMv7 platforms.
> > 
> > See arm_architected_timer.o in drivers/clocksource. Also, perhaps you should
> > rename the file to arm_architected_timer.c as well?
> > 
> > 
> 
> Would something like below makes sense in arch/arm/lib32/Makefile:
> 
> pbl-$(CONFIG_CLOCKSOURCE_ARM_ARCHITECTED_TIMER) += arm_architected_timer.o
> ifeq ($(CONFIG_CPU_32v7),y)
> CFLAGS_arm_architected_timer.o := -march=armv7-a
> endif

I don't see what the ifeq is needed for. I think you can drop it.

Sascha

-- 
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 |



  reply	other threads:[~2023-03-03 11:58 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-01 16:59 Renaud Barbier
2023-03-01 17:41 ` Ahmad Fatoum
2023-03-02 10:57   ` Renaud Barbier
2023-03-03  9:23   ` Renaud Barbier
2023-03-03 11:57     ` Sascha Hauer [this message]
2023-03-03 14:44     ` Ahmad Fatoum

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=20230303115741.GU32097@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=Renaud.Barbier@ametek.com \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /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