From: <Claudiu.Beznea@microchip.com>
To: <alexandre.belloni@bootlin.com>
Cc: <linux-kernel@vger.kernel.org>, <linux-pm@vger.kernel.org>,
<sre@kernel.org>, <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 2/4] power: reset: at91-poweroff: move shdwc related data to one structure
Date: Wed, 7 Nov 2018 14:54:17 +0000 [thread overview]
Message-ID: <6719a808-e704-3c63-f592-3b90d44ccbfe@microchip.com> (raw)
In-Reply-To: <20181106210933.GU24212@piout.net>
Hi Alexandre,
On 06.11.2018 23:09, Alexandre Belloni wrote:
> Hi Claudiu,
>
> On 05/11/2018 11:14:26+0000, Claudiu.Beznea@microchip.com wrote:
>> static int __init at91_poweroff_probe(struct platform_device *pdev)
>> @@ -154,16 +160,22 @@ static int __init at91_poweroff_probe(struct platform_device *pdev)
>> u32 ddr_type;
>> int ret;
>>
>> + at91_shdwc = devm_kzalloc(&pdev->dev, sizeof(*at91_shdwc), GFP_KERNEL);
>> + if (!at91_shdwc)
>> + return -ENOMEM;
>> +
>
> Is there any real benefit that will offset the time lost for that
> allocation at boot time?
No, I haven't run benchmarks on this. I only wanted to have them grouped in
one structure. Please let me know if you have some tests in mind.
>
> I understand you are then testing at91_shdwc to know whether the driver
> already probed once. But, the driver will never probe twice as there is
> only one shutdown controller on the SoC and anyway, If it was to probe
> twice, it will still work as expected.
I had in mind the scenario where the driver would be compiled as module. I
know insmod already does this checking. I'm ok to remove this checking. I
will do it in next version. With this I will also remove devm_kzalloc() of
at91_shdwc.
Thank you,
Claudiu Beznea
>
>
next prev parent reply other threads:[~2018-11-07 14:54 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-05 11:14 [PATCH 0/4] power: reset: at91-poweroff: cleanups Claudiu.Beznea
2018-11-05 11:14 ` [PATCH 1/4] power: reset: at91-poweroff: use one poweroff function for at91-poweroff Claudiu.Beznea
2018-12-05 22:37 ` Sebastian Reichel
2018-11-05 11:14 ` [PATCH 2/4] power: reset: at91-poweroff: move shdwc related data to one structure Claudiu.Beznea
2018-11-06 21:09 ` Alexandre Belloni
2018-11-07 14:54 ` Claudiu.Beznea [this message]
2018-11-07 17:23 ` Alexandre Belloni
2018-12-05 22:40 ` Sebastian Reichel
2018-12-06 9:48 ` Claudiu.Beznea
2018-11-05 11:14 ` [PATCH 3/4] power: reset: at91-poweroff: check shdwc data structure at the beginning of probe Claudiu.Beznea
2018-12-05 22:38 ` Sebastian Reichel
2018-11-05 11:14 ` [PATCH 4/4] power: reset: at91-poweroff: remove at91_ramc_of_match Claudiu.Beznea
2018-12-05 22:37 ` Sebastian Reichel
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=6719a808-e704-3c63-f592-3b90d44ccbfe@microchip.com \
--to=claudiu.beznea@microchip.com \
--cc=alexandre.belloni@bootlin.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=sre@kernel.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
all inboxes | Powered by JetHome®