linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: r.sricharan@ti.com (Sricharan R)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH-V2 3/4] ARM: OMAP2+: CLEANUP: Remove unnecessary ifdef around __omap2_set_globals
Date: Fri, 11 May 2012 12:07:59 +0530	[thread overview]
Message-ID: <7c4ff0c2577bb15874d6adad285cf21c@mail.gmail.com> (raw)
In-Reply-To: <79CD15C6BA57404B839C016229A409A83EA220A3@DBDE01.ent.ti.com>

Vaibhav,

> > >> > This patch adds new config flag SOC_HAS_OMAP2_SDRC to handle
> sdrc,
> > >> > so that we can reuse same function across omap2/3/4...
> > >>
> > >> But what happens when a single kernel is built that has support
> for an
> > >> SoC with an SDRC (OMAP4) and one that doesn't (AM33xx)?
> > >>
> > >
> > > As such Nothing...I looking into this direction while implementing.
> > >
> > > In that case, sdrc.c file will be compiled in and execution will
> jump to
> > > omap2_set_globals_sdrc(). But inside this function, we are already
> checking
> > > whether the omap2_globals->sdrc and omap2_globals->sms for NULL and
> then use
> > > it.
> > >
> > > And function omap2_sdrc_init() is also depends on machine, so in
> case of
> > > Am33xx, it won't get into sdrc execution at all. And in case of
> omap4, it
> > > will.
> >
> > Then why bother with the #ifdef at all?
> >
> > If it already safe to call on all SoCs, just get rid of the #ifdef
> all
> > together.
> >
>
> Kevin,
>
> sdrc.o target gets built only as "omap-2-3-common", this will not get
> built
> for omap4, am33xx, ti81xx, etc...
> So in order to avoid build break, you have to have some mechanism, and
> that's where we need to create config option dependent on platform.
>
> Another better way of handling this is adding __weak function.
>
> What's your opinion on this?
>
  Then how about just allowing to compile for all omap2/3/4 ?

Thanks,
 Sricharan

  reply	other threads:[~2012-05-11  6:37 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-08 19:52 [PATCH-V2 0/4] ARM: OMAP2+: Cleanup series in order to remove ARCH_OMAPx dependency Vaibhav Hiremath
2012-05-08 19:52 ` [PATCH-V2 1/4] ARM: OMAP2+: CLEANUP: All OMAP2PLUS uses omap-device.o target so add one entry Vaibhav Hiremath
2012-05-08 19:52 ` [PATCH-V2 2/4] ARM: OMAP2+: CLEANUP: Move omap3 dpll ops to dpll3xxx.c Vaibhav Hiremath
2012-05-10 23:02   ` Paul Walmsley
2012-05-11  7:01     ` Hiremath, Vaibhav
2012-05-08 19:52 ` [PATCH-V2 3/4] ARM: OMAP2+: CLEANUP: Remove unnecessary ifdef around __omap2_set_globals Vaibhav Hiremath
2012-05-08 22:38   ` Kevin Hilman
2012-05-09  8:59     ` Hiremath, Vaibhav
2012-05-10 21:39       ` Kevin Hilman
2012-05-11  6:09         ` Hiremath, Vaibhav
2012-05-11  6:37           ` Sricharan R [this message]
2012-05-11  6:43             ` Hiremath, Vaibhav
2012-05-11 21:54           ` Kevin Hilman
2012-05-14  9:23             ` Hiremath, Vaibhav
2012-05-08 19:52 ` [PATCH-V2 4/4] ARM: OMAP2+: CLEANUP: Add new config option for different DPLL features Vaibhav Hiremath
2012-05-08 22:50   ` Kevin Hilman
2012-05-09  9:06     ` Hiremath, Vaibhav
2012-05-10 22:35       ` Paul Walmsley
2012-05-11  5:30         ` Hiremath, Vaibhav

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=7c4ff0c2577bb15874d6adad285cf21c@mail.gmail.com \
    --to=r.sricharan@ti.com \
    --cc=linux-arm-kernel@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;
as well as URLs for NNTP newsgroup(s).