public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Rabin VINCENT <rabin.vincent@stericsson.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>,
	"rtc-linux@googlegroups.com" <rtc-linux@googlegroups.com>,
	Samuel Ortiz <sameo@linux.intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	STEricsson_nomadik_linux <STEricsson_nomadik_linux@list.st.com>,
	Virupax SADASHIVPETIMATH 
	<virupax.sadashivpetimath@stericsson.com>,
	Linus WALLEIJ <linus.walleij@stericsson.com>,
	Srinidhi KASAGAR <srinidhi.kasagar@stericsson.com>
Subject: Re: [PATCH] rtc: AB8500 RTC driver
Date: Wed, 26 May 2010 20:45:22 -0700	[thread overview]
Message-ID: <20100526204522.ff41994d.akpm@linux-foundation.org> (raw)
In-Reply-To: <20100527031443.GA6926@bnru02.bnr.st.com>

On Thu, 27 May 2010 08:44:44 +0530 Rabin VINCENT <rabin.vincent@stericsson.com> wrote:

> On Wed, May 26, 2010 at 21:09:04 +0200, Andrew Morton wrote:
> > > --- a/drivers/rtc/rtc-ab8500.c~rtc-ab8500-rtc-driver-update
> > > +++ a/drivers/rtc/rtc-ab8500.c
> > > @@ -46,16 +46,25 @@
> > >  #define COUNTS_PER_SEC			(0xF000 / 60)
> > >  #define AB8500_RTC_EPOCH		2000
> > >  
> > > +static const unsigned long ab8500_rtc_time_regs[] = {
> > > +	AB8500_RTC_WATCH_TMIN_HI_REG, AB8500_RTC_WATCH_TMIN_MID_REG,
> > > +	AB8500_RTC_WATCH_TMIN_LOW_REG, AB8500_RTC_WATCH_TSECHI_REG,
> > > +	AB8500_RTC_WATCH_TSECMID_REG
> > > +};
> > > +
> > > +static const unsigned long ab8500_rtc_alarm_regs[] = {
> > > +	AB8500_RTC_ALRM_MIN_HI_REG, AB8500_RTC_ALRM_MIN_MID_REG,
> > > +	AB8500_RTC_ALRM_MIN_LOW_REG
> > > +};
> > 
> > Well, it wasn't necessary to move these into file-global scope.  It
> > would be nicer to leave them in function scope, really.  I was just
> > pointing out that the `static' was missing, although unnecessary due to
> > compiler magic.
> 
> I know, but we moved them out to reduce code duplication because these
> lists were used in multiple functions and were copy/pasted in them.
> 

Ah.  Good reason :)

      reply	other threads:[~2010-05-27  3:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-21 14:56 [PATCH] rtc: AB8500 RTC driver Rabin Vincent
2010-05-25 20:51 ` Andrew Morton
2010-05-26 12:11   ` Rabin VINCENT
2010-05-26 19:09     ` Andrew Morton
2010-05-27  3:14       ` Rabin VINCENT
2010-05-27  3:45         ` Andrew Morton [this message]

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=20100526204522.ff41994d.akpm@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=STEricsson_nomadik_linux@list.st.com \
    --cc=a.zummo@towertech.it \
    --cc=linus.walleij@stericsson.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rabin.vincent@stericsson.com \
    --cc=rtc-linux@googlegroups.com \
    --cc=sameo@linux.intel.com \
    --cc=srinidhi.kasagar@stericsson.com \
    --cc=virupax.sadashivpetimath@stericsson.com \
    /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