All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Tyser <ptyser@xes-inc.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v3 1/4] arm: Tegra2: Add basic NVIDIA Tegra2 SoC support
Date: Thu, 20 Jan 2011 11:15:50 -0600	[thread overview]
Message-ID: <1295543750.13088.85.camel@petert> (raw)
In-Reply-To: <AANLkTi=yMzEztQ5p=doSj4ukKfvx8gMRZOAxjBwbJmkT@mail.gmail.com>

On Thu, 2011-01-20 at 09:41 -0700, Tom Warren wrote:
> On Wed, Jan 19, 2011 at 5:04 PM, Peter Tyser <ptyser@xes-inc.com> wrote:
> > Hi Tom,
> > Some last minutes nits:
> >
> > It looks like some of the new functions can be declared statically.
> > It'd be nice to do so where possible.
> Which functions, Peter? Please point them out specifically, thanks.

Any function that won't be called from outside the scope of the file.
Eg it looks like init_uart() and setup_uart() are local functions and
should be static.  Those are the 2 that jumped out initially, but you
should review to see if there are others.

<snip>

> >> +/*
> >> + * Routine: uart_clock_init
> >> + * Description: init the PLL and clock for the UART in uart_num
> >> + */
> >> +void uart_clock_init(int uart_num)
> >> +{
> >
> > Are all these uart functions board-specific?  They look more
> > CPU-specific.  If that's the case they should be moved somewhere in
> > arch/arm/*.  Other boards that use the Tegra2 don't want to duplicate
> > this code or link into Nvidia's board/nvidia directory.
> It's Tegra2 SoC-specific - that's not the CPU, per se.  I guess I could move
> it to arch/arm/cpu/armv7/tegra2, if you think it's important enough.

I think they should be moved.  If they aren't, the next board vendor (eg
my company) that uses the Tegra2 will copy your board.[ch] into their
board/<vendor> directory and use them as a starting point, which is a
large duplication of code.  Moving it somewhere in arch/arm is the
"right" thing to do and will make every future tegra2 board port cleaner
and easier.

Best,
Peter

  reply	other threads:[~2011-01-20 17:15 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-19 21:19 [U-Boot] [PATCH v3 0/4] Add basic NVIDIA Tegra2 SoC support Tom Warren
2011-01-19 21:19 ` [U-Boot] [PATCH v3 1/4] arm: Tegra2: " Tom Warren
2011-01-20  0:04   ` Peter Tyser
2011-01-20 16:41     ` Tom Warren
2011-01-20 17:15       ` Peter Tyser [this message]
2011-01-20 22:47       ` Wolfgang Denk
2011-01-20  0:20   ` Graeme Russ
2011-01-20 16:44     ` Tom Warren
2011-01-20 22:50       ` Wolfgang Denk
2011-01-21  0:13         ` Graeme Russ
2011-01-20  8:40   ` Wolfgang Denk
2011-01-20 16:49     ` Tom Warren
2011-01-20 22:51       ` Wolfgang Denk
2011-01-24 11:55   ` Mike Rapoport
2011-01-24 17:26     ` Tom Warren
2011-01-24 19:00       ` Wolfgang Denk
2011-01-24 20:11         ` Tom Warren
2011-01-24 21:23           ` Wolfgang Denk
2011-01-24 18:53     ` Wolfgang Denk
2011-01-19 21:19 ` [U-Boot] [PATCH v3 2/4] serial: Add Tegra2 serial port support Tom Warren
2011-01-19 21:19 ` [U-Boot] [PATCH v3 3/4] arm: Tegra2: Add support for NVIDIA Harmony board Tom Warren
2011-01-24 11:58   ` Mike Rapoport
2011-01-24 17:29     ` Tom Warren
2011-01-19 21:19 ` [U-Boot] [PATCH v3 4/4] arm: Tegra2: Add support for NVIDIA Seaboard board Tom Warren

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=1295543750.13088.85.camel@petert \
    --to=ptyser@xes-inc.com \
    --cc=u-boot@lists.denx.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.