From: boris.brezillon@free-electrons.com (Boris Brezillon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 0/8] ARM: at91: Remove mach/ includes from the reset driver
Date: Tue, 28 Oct 2014 08:50:53 +0100 [thread overview]
Message-ID: <20141028085053.41c6ce46@bbrezillon> (raw)
In-Reply-To: <1414451377-11053-1-git-send-email-alexandre.belloni@free-electrons.com>
Hi,
On Tue, 28 Oct 2014 00:09:29 +0100
Alexandre Belloni <alexandre.belloni@free-electrons.com> wrote:
> This series removes the mach/ headers dependency from the reset driver. It is
> also laying some groundwork for the necessary power management support rework.
>
> The first patch adds and export a function to shutdown the sdram from the sdramc
> driver. That function also take the RSTC CR register and a value as parameters
> to be able to reset the chip. This is a hackish way of doing it but it ensures
> that all the code fits in one cache line. We already have plan to start using
> the sram to have a cleaner way to execute that code safely as soon as that
> series goes in:
> http://lists.infradead.org/pipermail/linux-arm-kernel/2013-September/198778.html
>
> The second patch makes the sdramc driver usable from the board files.
>
> The third patch actually registers the sdramc driver from the boards files.
> The fourth patch does the same, only for sam9g45 and sam9rl to simplify future
> merging as the board files have been removed. Simply drop that patch.
>
> The fifth patch makes the at91-reset driver use the newly created
> at91_ramc_shutdown() function and removes the mach/ headers inclusion.
I'm not a big fan of this approach.
I definitely think each step of the reset process should be handled in
the appropriate block (and the patch series you pointed out would
definitely help in achieving this goal), but you're just moving all the
stuff done in the reset driver into the SDRAM one, which means you're
solving one design issue by introducing a new one.
Moreover, the errata at the origin of this hack is attached to the RSTC
(Rest Controller) block in the datasheets.
I'd rather keep the reset driver as is and move SDRAM related macros
into a specific header (include/linux/memory/atmel-sdram.h or
include/soc/atmel/memory.h as you proposed) so that the reset driver
can reference them without including mach headers.
Best Regards,
Boris
--
Boris Brezillon, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
next prev parent reply other threads:[~2014-10-28 7:50 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-27 23:09 [PATCH v2 0/8] ARM: at91: Remove mach/ includes from the reset driver Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 1/8] memory: atmel-sdramc: export a shutdown function Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 2/8] memory: atmel-sdramc: allow probing from pdata Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 3/8] ARM: at91: sam9: probe the RAMC driver " Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 4/8] ARM: at91: sam9g45/sam9rl: probe the ramc driver Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 5/8] power: reset: at91-reset: use at91_ramc_shutdown Alexandre Belloni
2014-10-28 2:18 ` Sebastian Reichel
2014-10-27 23:09 ` [PATCH v2 6/8] ARM: at91: sam9: remove useless resource for rstc Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 7/8] ARM: at91: sam9g45/sam9rl: remove useless resources " Alexandre Belloni
2014-10-27 23:09 ` [PATCH v2 8/8] MAINTAINERS: add at91 power and memory entries Alexandre Belloni
2014-10-27 23:17 ` Joe Perches
2014-11-21 20:17 ` Pavel Machek
2014-10-28 7:50 ` Boris Brezillon [this message]
2014-10-28 8:52 ` [PATCH v2 0/8] ARM: at91: Remove mach/ includes from the reset driver Alexandre Belloni
2014-10-28 8:59 ` Maxime Ripard
2014-10-28 9:04 ` Alexandre Belloni
2014-10-28 9:11 ` Maxime Ripard
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=20141028085053.41c6ce46@bbrezillon \
--to=boris.brezillon@free-electrons.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).