All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ashish Jangam <ashish.jangam@kpitcummins.com>
To: Venu Byravarasu <vbyravarasu@nvidia.com>
Cc: "akpm@linux-foundation.org" <akpm@linux-foundation.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"sameo@linux.intel.com" <sameo@linux.intel.com>,
	"p_gortmaker@yahoo.com" <p_gortmaker@yahoo.com>,
	"dchen@diasemi.com" <dchen@diasemi.com>,
	"rtc-linux@googlegroups.com" <rtc-linux@googlegroups.com>,
	Alessandro Zummo <a.zummo@towertech.it>
Subject: RE: [Patch v3 3/7] rtc: DA9055 RTC driver
Date: Fri, 23 Nov 2012 17:57:37 +0530	[thread overview]
Message-ID: <1353673657.11305.7.camel@dhruva> (raw)
In-Reply-To: <D958900912E20642BCBC71664EFECE3E6E1702F4A9@BGMAIL02.nvidia.com>

On Fri, 2012-11-23 at 16:39 +0530, Venu Byravarasu wrote:
> > -----Original Message-----
> > From: linux-kernel-owner@vger.kernel.org [mailto:linux-kernel-
> > owner@vger.kernel.org] On Behalf Of Ashish Jangam
> > Sent: Friday, November 23, 2012 3:41 PM
> > To: akpm@linux-foundation.org
> > Cc: linux-kernel@vger.kernel.org; sameo@linux.intel.com;
> > p_gortmaker@yahoo.com; dchen@diasemi.com; rtc-
> > linux@googlegroups.com; Alessandro Zummo
> > Subject: Re: [Patch v3 3/7] rtc: DA9055 RTC driver
> > 
> > Any comments on this patch.
> > On Tue, 2012-10-23 at 15:33 +0530, Ashish Jangam wrote:
> > > Does this patch looks good?
> > > On Thu, 2012-10-11 at 16:10 +0530, Ashish Jangam wrote:
> > > > This is the RTC patch for the DA9055 PMIC. This patch has got
> > dependency on
> > > > the DA9055 MFD core.
> > > >
> > > > This patch is functionally tested on Samsung SMDKV6410.
> > > >
> > > > Signed-off-by: David Dajun Chen <dchen@diasemi.com>
> > > > Signed-off-by: Ashish Jangam <ashish.jangam@kpitcummins.com>
> > > > ---
> > > > changes since version v3:
> > > > - use of module_platform_driver macro
> > > > - add the regmap virtual irq map API.
> > > > changes since version v2:
> > > > - Use of devm_request_threaded_irq API
> > > > ---
> > > >  drivers/rtc/Kconfig      |   10 +
> > > >  drivers/rtc/Makefile     |    1 +
> > > >  drivers/rtc/rtc-da9055.c |  413
> > ++++++++++++++++++++++++++++++++++++++++++++++
> > > >  3 files changed, 424 insertions(+), 0 deletions(-)
> > > >  mode change 100644 => 100755 drivers/rtc/Kconfig
> > > >  create mode 100644 drivers/rtc/rtc-da9055.c
> > > >
> 
> > > > +static int da9055_set_alarm(struct da9055 *da9055, struct rtc_time
> > *rtc_tm)
> > > > +{
> > > > +	int ret;
> > > > +	uint8_t v[2];
> > > > +
> > > > +	rtc_tm->tm_year -= 100;
> > > > +	rtc_tm->tm_mon += 1;
> > > > +
> > > > +	ret = da9055_reg_update(da9055, DA9055_REG_ALARM_MI,
> > > > +				DA9055_RTC_ALM_MIN, rtc_tm->tm_min);
> > > > +	if (ret != 0) {
> > > > +		dev_err(da9055->dev, "Failed to write ALRM MIN: %d\n",
> > ret);
> > > > +		return ret;
> > > > +	}
> > > > +
> > > > +	v[0] = rtc_tm->tm_hour;
> > > > +	v[1] = rtc_tm->tm_mday;
> > > > +
> > > > +	ret = da9055_group_write(da9055, DA9055_REG_ALARM_H, 2, v);
> 
> Why don't you write all registers at once using single multi byte
> write command as you already used in da9055_rtc_set_time() ?
Unlike TIME/Date registers some of the ALARM register bits has got few
other bits which should not get modified during the setting of ALARM
therefore reg_update was used for those ALARM register.   



  reply	other threads:[~2012-11-23 12:28 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-11 10:40 [Patch v3 3/7] RTC: DA9055 RTC driver Ashish Jangam
2012-10-11 11:23 ` shubhro
2012-10-23 10:03 ` Ashish Jangam
2012-11-23 10:11   ` [Patch v3 3/7] rtc: " Ashish Jangam
2012-11-23 11:09     ` Venu Byravarasu
2012-11-23 12:27       ` Ashish Jangam [this message]
2012-11-27 22:23     ` Andrew Morton
2012-11-28  9:24       ` Ashish Jangam
2012-12-10  5:42         ` Ashish Jangam
2012-12-12 21:11           ` Andrew Morton
2012-12-13  5:51             ` Ashish Jangam
2012-12-13 13:04             ` Ashish Jangam
2012-12-13 21:39               ` Andrew Morton
2012-11-28  9:24       ` Ashish Jangam

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=1353673657.11305.7.camel@dhruva \
    --to=ashish.jangam@kpitcummins.com \
    --cc=a.zummo@towertech.it \
    --cc=akpm@linux-foundation.org \
    --cc=dchen@diasemi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=p_gortmaker@yahoo.com \
    --cc=rtc-linux@googlegroups.com \
    --cc=sameo@linux.intel.com \
    --cc=vbyravarasu@nvidia.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 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.