mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-22 09:21:57 -05:00
Kernel/aarch64: Reject ARMv8Timers with the "interrupt-names" property
Our current check `interrupts.size() != 4` doesn't always work because timers with the "interrupt-names" property can define 4 timers at the same indices mapping to different interrupts. The old devicetree binding only allowed 4 interrupts, so keep the old check as well.
This commit is contained in:
parent
98f26fac1b
commit
4cc9bea86d
1 changed files with 2 additions and 1 deletions
|
@ -101,7 +101,8 @@ DEVICETREE_DRIVER(ARMv8TimerDriver, compatibles_array);
|
|||
ErrorOr<void> ARMv8TimerDriver::probe(DeviceTree::Device const& device, StringView) const
|
||||
{
|
||||
auto const interrupts = TRY(device.node().interrupts(DeviceTree::get()));
|
||||
if (interrupts.size() != 4)
|
||||
|
||||
if (device.node().has_property("interrupt-names"sv) || interrupts.size() != 4)
|
||||
return ENOTSUP; // TODO: Support the interrupt-names property.
|
||||
|
||||
// Index 1 is the interrupt for the EL1 physical timer. This driver currently only uses that timer.
|
||||
|
|
Loading…
Reference in a new issue