linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: mark.rutland@arm.com (Mark Rutland)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 6/6] cpufreq: probe the Integrator cpufreq driver from DT
Date: Tue, 8 Oct 2013 11:00:44 +0100	[thread overview]
Message-ID: <20131008100044.GF28972@e106331-lin.cambridge.arm.com> (raw)
In-Reply-To: <1380816238-3255-1-git-send-email-linus.walleij@linaro.org>

[adding devicetree to Cc]

Hi Linus,

[...]

> +static int __init integrator_cpufreq_probe(struct platform_device *pdev)
>  {
> +	struct device_node *np = pdev->dev.of_node;
> +
> +	cm_base = of_iomap(np, 0);
> +	if (!cm_base)
> +		return -ENODEV;
>  	return cpufreq_register_driver(&integrator_driver);

If we fail to register the driver we could unmap cm_base, no?

>  }
>  
> -static void __exit integrator_cpu_exit(void)
> +static void __exit integrator_cpufreq_remove(struct platform_device *pdev)
>  {
>  	cpufreq_unregister_driver(&integrator_driver);

Unmap here?

>  }
>  
> +static const struct of_device_id integrator_cpufreq_match[] = {
> +	{ .compatible = "arm,core-module-integrator"},
> +	{ },
> +};

It feels a little scary that this also got handled by some other code in
the previous patch. Is no arbitrarion required between the two when
accessing the core module registers?

Cheers,
Mark.

  reply	other threads:[~2013-10-08 10:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-03 16:03 [PATCH 6/6] cpufreq: probe the Integrator cpufreq driver from DT Linus Walleij
2013-10-08 10:00 ` Mark Rutland [this message]
2013-10-10 15:11   ` Linus Walleij

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=20131008100044.GF28972@e106331-lin.cambridge.arm.com \
    --to=mark.rutland@arm.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).