From: s-anna@ti.com (Suman Anna)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] mailbox/omap: store mailbox interrupt type in omap_mbox_device
Date: Thu, 7 Apr 2016 07:24:48 -0500 [thread overview]
Message-ID: <57065190.4050904@ti.com> (raw)
In-Reply-To: <57063731.9010201@ti.com>
Hi Grygorii,
On 04/07/2016 05:32 AM, Grygorii Strashko wrote:
> On 04/07/2016 02:37 AM, Suman Anna wrote:
>> The interrupt type used for identifying the layout of the interrupt
>> configuration registers between OMAP4+ SoCs and older SoCs is stored
>> only in the sub-mailbox structures for easier access. Store this type
>> in the the omap_mbox_device structure as well along with the other
>> global variables. This is being done to facilitate the context save
>> and restore of appropriate registers during system suspend/resume.
>>
>> Signed-off-by: Suman Anna <s-anna@ti.com>
>> ---
>> drivers/mailbox/omap-mailbox.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/mailbox/omap-mailbox.c
>> b/drivers/mailbox/omap-mailbox.c
>> index 84cafc02e761..adf37f494690 100644
>> --- a/drivers/mailbox/omap-mailbox.c
>> +++ b/drivers/mailbox/omap-mailbox.c
>> @@ -90,6 +90,7 @@ struct omap_mbox_device {
>> void __iomem *mbox_base;
>> u32 num_users;
>> u32 num_fifos;
>> + u32 intr_type;
>> struct omap_mbox **mboxes;
>> struct mbox_controller controller;
>> struct list_head elem;
>> @@ -828,6 +829,7 @@ static int omap_mbox_probe(struct platform_device
>> *pdev)
>> mdev->dev = &pdev->dev;
>> mdev->num_users = num_users;
>> mdev->num_fifos = num_fifos;
>> + mdev->intr_type = intr_type;
>> mdev->mboxes = list;
>>
>> /* OMAP does not have a Tx-Done IRQ, but rather a Tx-Ready IRQ */
>>
>
> This smth. which definitely has to be done using compatible props.
> Why not to pass more info through of_device_id->data?
>
Yeah, that's already the case, intr_type is a local variable assigned
from compatible match data. This patch merely caches it in the
omap_mbox_device structure so that it can be leveraged by the PM
callback functions in the next patch.
regards
Suman
next prev parent reply other threads:[~2016-04-07 12:24 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-06 23:37 [PATCH 0/4] OMAP mailbox suspend/resume support Suman Anna
2016-04-06 23:37 ` [PATCH 1/4] mailbox/omap: store mailbox interrupt type in omap_mbox_device Suman Anna
2016-04-07 10:32 ` Grygorii Strashko
2016-04-07 12:24 ` Suman Anna [this message]
2016-04-07 12:39 ` Grygorii Strashko
2016-04-06 23:37 ` [PATCH 2/4] mailbox/omap: add support for suspend/resume Suman Anna
2016-04-06 23:37 ` [PATCH 3/4] mailbox/omap: check for any unread messages during suspend Suman Anna
2016-04-06 23:37 ` [PATCH 4/4] mailbox/omap: kill omap_mbox_{save/restore}_ctx() functions Suman Anna
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=57065190.4050904@ti.com \
--to=s-anna@ti.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).