From: Nishanth Menon <nm@ti.com>
To: Viresh Kumar <viresh.kumar@linaro.org>, Shawn Guo <shawn.guo@linaro.org>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>,
"cpufreq@vger.kernel.org" <cpufreq@vger.kernel.org>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Carlos Hernandez <ceh@ti.com>
Subject: Re: [PATCH] cpufreq: cpufreq-cpu0: Use a sane boot frequency when booting with a mismatched bootloader configuration
Date: Mon, 18 Nov 2013 08:45:12 -0600 [thread overview]
Message-ID: <528A27F8.3070402@ti.com> (raw)
In-Reply-To: <CAKohponU-WFnG8Gx6ba=k3eJmWV_0eWtpsy9kDP8yA2KrdoKtg@mail.gmail.com>
On 11/16/2013 10:02 PM, Viresh Kumar wrote:
> On 16 November 2013 19:14, Shawn Guo <shawn.guo@linaro.org> wrote:
>> No, it's not a kernel bug.
>>
>> OPP is not a definition that belongs to kernel. Instead, it's
>> characteristics of hardware, and that's why we can naturally put the
>> definition into device tree. Bear it in mind that device tree is a
>> hardware description and should be OS agnostic. So it shouldn't be
>> treated as part of Linux kernel in any case, even though the device
>> tree source is currently maintained in kernel tree.
>>
>> Device tree is designed as a way for firmware/bootloader to describe
>> hardware to kernel. That said, device tree is more part of bootloader
>> than kernel. If bootloader runs at a frequency that does not match the
>> OPP in device tree, the one should be fixed is either bootloader or
>> device tree but never kernel.
>
> I agree for all that..
I do not agree about this stance - device tree describes hardware
capabilities to kernel -> I agree with that statement. Kernel should
not care if that is provided by bootloader/firmware/fused into
flash/ROM etc.
If we agree with that statement, the moment kernel sees device
operating in a configuration that is not hardware capability, it is
our job to switch to the right configuration if it is possible for us
to do so (which in this case, we can). to give a comparison - if i2c
bus was configured for 3.4MHz and device tree describes the bus to
operate at 100KHz, do we ignore device tree recommended configuration?
No. we would switch to 100KHz. as far as kernel is concerned, it can
detect invalid configuration and switch back to a valid configuration
based on hardware description provided by device tree.
--
Regards,
Nishanth Menon
next prev parent reply other threads:[~2013-11-18 14:45 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-16 2:22 [PATCH] cpufreq: cpufreq-cpu0: Use a sane boot frequency when booting with a mismatched bootloader configuration Nishanth Menon
2013-11-16 13:44 ` Shawn Guo
2013-11-17 4:02 ` Viresh Kumar
2013-11-18 14:45 ` Nishanth Menon [this message]
2013-11-18 15:57 ` Shawn Guo
2013-11-18 16:41 ` Nishanth Menon
2013-11-19 2:21 ` Shawn Guo
2013-11-19 3:46 ` Viresh Kumar
2013-11-19 14:16 ` Nishanth Menon
2013-11-19 14:26 ` Viresh Kumar
2013-11-19 14:59 ` Nishanth Menon
2013-11-19 15:32 ` Viresh Kumar
2013-11-19 15:48 ` Nishanth Menon
2013-11-19 17:10 ` Viresh Kumar
2013-11-19 17:43 ` Nishanth Menon
2013-11-20 5:24 ` viresh kumar
2013-11-20 14:59 ` Nishanth Menon
2013-11-21 7:41 ` Viresh Kumar
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=528A27F8.3070402@ti.com \
--to=nm@ti.com \
--cc=ceh@ti.com \
--cc=cpufreq@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rjw@rjwysocki.net \
--cc=shawn.guo@linaro.org \
--cc=viresh.kumar@linaro.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