* __clksrc_of_table and "clocksource_probe: no matching clocksources found"
@ 2019-04-23 20:07 Guilherme Costa
2019-04-23 20:17 ` Valdis Klētnieks
0 siblings, 1 reply; 3+ messages in thread
From: Guilherme Costa @ 2019-04-23 20:07 UTC (permalink / raw)
To: kernelnewbies
Hi,
I'm working with kernel 4.9.51 LTSI on a custom board with an AM3352.
The system seems to be working just fine, but I'm getting the
following message on boot:
"clocksource_probe: no matching clocksources found"
I did some snooping around and this message is printed by
clocksource_probe(), called during time_init(). This is the function
code:
void __init clocksource_probe(void)
{
struct device_node *np;
const struct of_device_id *match;
of_init_fn_1_ret init_func_ret;
unsigned clocksources = 0;
int ret;
for_each_matching_node_and_match(np, __clksrc_of_table, &match) {
if (!of_device_is_available(np))
continue;
init_func_ret = match->data;
ret = init_func_ret(np);
if (ret) {
pr_err("Failed to initialize '%s': %d",
of_node_full_name(np), ret);
continue;
}
clocksources++;
}
clocksources += acpi_probe_device_table(clksrc);
if (!clocksources)
pr_crit("%s: no matching clocksources found\n", __func__);
}
From the code, we can see that the message was printed because
clocksources == 0. This implies that there were no matching nodes on
the device tree,
and that acpi_probe_device_table returned 0 (which is correct, seeing
that the kernel has no ACPI support).
This leaves me with two questions:
1 - Is this message a problem indicator? I'm assuming it is, because
it's printed with a pr_crit...
2 - Why is for_each_matching_node_and_match not getting any matches? I
did not find where __clksrc_of_table is initialized, so maybe it's
because it is empty?
Cheers,
Guilherme
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: __clksrc_of_table and "clocksource_probe: no matching clocksources found"
2019-04-23 20:07 __clksrc_of_table and "clocksource_probe: no matching clocksources found" Guilherme Costa
@ 2019-04-23 20:17 ` Valdis Klētnieks
2019-04-23 20:36 ` Guilherme Costa
0 siblings, 1 reply; 3+ messages in thread
From: Valdis Klētnieks @ 2019-04-23 20:17 UTC (permalink / raw)
To: Guilherme Costa; +Cc: kernelnewbies
On Tue, 23 Apr 2019 17:07:14 -0300, Guilherme Costa said:
> From the code, we can see that the message was printed because
> clocksources == 0. This implies that there were no matching nodes on
> the device tree,
Right.
> and that acpi_probe_device_table returned 0 (which is correct, seeing
> that the kernel has no ACPI support).
> This leaves me with two questions:
> 1 - Is this message a problem indicator? I'm assuming it is, because
> it's printed with a pr_crit...
Depends. Most systems really want a clocksource of some sort.
> 2 - Why is for_each_matching_node_and_match not getting any matches? I
> did not find where __clksrc_of_table is initialized, so maybe it's
> because it is empty?
My first guess is that your hardware has a busted device tree that doesn't
have an entry pointing at any actual valid hardware clock device. Could
be an incorrect address, or the DT says it's a Frobozz1 clock but the actual
hardware has a Frobozz2 that won't probe using the Frobozz1 driver, or
something else....
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: __clksrc_of_table and "clocksource_probe: no matching clocksources found"
2019-04-23 20:17 ` Valdis Klētnieks
@ 2019-04-23 20:36 ` Guilherme Costa
0 siblings, 0 replies; 3+ messages in thread
From: Guilherme Costa @ 2019-04-23 20:36 UTC (permalink / raw)
To: Valdis Klētnieks; +Cc: kernelnewbies
Em ter, 23 de abr de 2019 às 17:18, Valdis Klētnieks
<valdis.kletnieks@vt.edu> escreveu:
> > 2 - Why is for_each_matching_node_and_match not getting any matches? I
> > did not find where __clksrc_of_table is initialized, so maybe it's
> > because it is empty?
>
> My first guess is that your hardware has a busted device tree that doesn't
> have an entry pointing at any actual valid hardware clock device. Could
> be an incorrect address, or the DT says it's a Frobozz1 clock but the actual
> hardware has a Frobozz2 that won't probe using the Frobozz1 driver, or
> something else....
I see... My board is based on the AM335x evaluation kit
(am335x-evm.dts). My DT file differs only at the topmost level from
the EVM file,
using the exact same includes as the other. As I imagined this would
be a more "elementary" configuration, I looked through a bunch of
.dtsi
files but found nothing. Any hints on what I should look for?
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-04-23 20:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-23 20:07 __clksrc_of_table and "clocksource_probe: no matching clocksources found" Guilherme Costa
2019-04-23 20:17 ` Valdis Klētnieks
2019-04-23 20:36 ` Guilherme Costa
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).