linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Laxman Dewangan <ldewangan@nvidia.com>
To: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: "sameo@linux.intel.com" <sameo@linux.intel.com>,
	"lrg@ti.com" <lrg@ti.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH V3 1/2] mfd: add TI TPS80031 mfd core driver
Date: Tue, 13 Nov 2012 21:35:45 -0500	[thread overview]
Message-ID: <50A30381.3000609@nvidia.com> (raw)
In-Reply-To: <20121114012217.GE4415@opensource.wolfsonmicro.com>

On 11/13/2012 08:22 PM, Mark Brown wrote:
> * PGP Signed by an unknown key
>
> On Tue, Nov 13, 2012 at 11:18:34PM +0530, Laxman Dewangan wrote:
>> On Tuesday 13 November 2012 01:16 PM, Mark Brown wrote:
>>> I'm not sure your wake_base setting is sane here - this is expected to
>>> be a register.  If it is a register why is it not a #define?
>> There is no wake register. Here I kept for the incerease the wake
>> conut so that irq_set_irq_wake() can be called.
> So you want to write to random registers in the chip instead...  that
> doesn't seem like a terribly clever idea.

Yes, this is not a good idea, We will need support for wakeup without 
wakeup registers.
Probably we need to add one more parameter, wake enable to control 
without wake_base.


>
>> I think it is also not correct after change
>> regmap: irq: initialize all irqs to wake disabled
>> I need to set the irq_wake(0 without the register.
> I can't really parse any of the above, sorry.
>
>> There is 2 sets of registers which need to be configure, MASK and
>> LINE enable.
> So what does the second one do?


The MASK register used for updating status register when interrupt 
occurs and LINE register used to pass the status to actual interrupt line.
As per datasheet:

When INT_MSK_LINE [i] is set to 1, the associated interrupt number i is 
INT line masked, which means that no interrupt is generated on the INT line.
When INT_MSK_LINE [i] is set to 0, the associated interrupt number i is  
line enabled: An interrupt is generated on the INT line.
In any case, the INT_STS [i] status bit may or may not be updated, only 
linked to the INT_MSK_STS [i] configuration register bit.


When INT_MSK_STS [i] is set to 1, the associated interrupt number i is
status masked, which means that no interrupt is stored in the INT_STS 
[i]status bit. Note that no interrupt number i is generated on the INT 
line, even if the INT_MSK_LINE [i] register bit is set to 0.
When INT_MSK_STS [i] is set to 0, the associated interrupt number i is 
status enabled: An interrupt status is updated in the INT_STS [i] register.
The interrupt may or may not be generated on the INT line, depending on 
the INT_MSK_LINE [i] configuration register bit.

  reply	other threads:[~2012-11-14  2:35 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-11 15:11 [PATCH V3 0/2] tps80031: Add mfd and regulator driver Laxman Dewangan
2012-11-11 15:12 ` [PATCH V3 1/2] mfd: add TI TPS80031 mfd core driver Laxman Dewangan
2012-11-12 11:30   ` Guennadi Liakhovetski
2012-11-13  7:46   ` Mark Brown
2012-11-13 17:48     ` Laxman Dewangan
2012-11-14  1:22       ` Mark Brown
2012-11-14  2:35         ` Laxman Dewangan [this message]
2012-11-14  2:45           ` Mark Brown
2012-11-14  3:01             ` Laxman Dewangan
2012-11-14  3:04               ` Mark Brown
2012-11-14  3:51                 ` Laxman Dewangan
2012-11-11 15:12 ` [PATCH V3 2/2] regulator: tps80031: add regulator driver for tps80031 Laxman Dewangan
2012-11-12 12:28   ` Guennadi Liakhovetski
2012-11-13  6:54   ` Mark Brown

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=50A30381.3000609@nvidia.com \
    --to=ldewangan@nvidia.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lrg@ti.com \
    --cc=sameo@linux.intel.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;
as well as URLs for NNTP newsgroup(s).