Page MenuHomeFreeBSD

Create proper FDT attachment for GICv2m
ClosedPublic

Authored by zbb on Jan 21 2016, 12:56 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Apr 30, 1:37 AM
Unknown Object (File)
Tue, Apr 30, 1:31 AM
Unknown Object (File)
Jan 24 2024, 5:54 PM
Unknown Object (File)
Dec 19 2023, 10:19 AM
Unknown Object (File)
Sep 28 2023, 11:11 PM
Unknown Object (File)
Sep 3 2023, 7:55 AM
Unknown Object (File)
Aug 22 2023, 10:12 PM
Unknown Object (File)
Aug 20 2023, 2:46 AM
Subscribers

Details

Summary

Avoid probing GICv2m to any parent bus/driver. Instead, match
GICv2m driver with FDT complatible strings.
The intention behind this is to have two different drivers named
"gic" (for example GICv2 and GICv3). This is not possible if
GICv2m always probes.
In addition, not every GIC has a MSI controller in the form of
GICv2m extension.

Test Plan

We don't have any machine with GICv2m so please test.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

zbb retitled this revision from to Create proper FDT attachment for GICv2m.
zbb updated this object.
zbb edited the test plan for this revision. (Show Details)
zbb added reviewers: andrew, imp, ian, wma.
zbb set the repository for this revision to rS FreeBSD src repository - subversion.
zbb added a subscriber: ARM.

Why do we want two drivers with the same name?

Why do we want two drivers with the same name?

We want one (type of) PIC driver and one MSI controller matched by the compatible string or whatever.
The name is strictly for the convenience reasons :-). For example for all PCI bridges you have 'pcib' name and still only one driver attaches.
In addition, this commit prevents from attaching GICv2m on platforms that do not have GICv2m.

In D5015#106472, @zbb wrote:

Why do we want two drivers with the same name?

We want one (type of) PIC driver and one MSI controller matched by the compatible string or whatever.
The name is strictly for the convenience reasons :-). For example for all PCI bridges you have 'pcib' name and still only one driver attaches.
In addition, this commit prevents from attaching GICv2m on platforms that do not have GICv2m.

But with pcib we have a common driver that attaches to it, this is not the case with the gic driver.

I'm not opposed to the change, querying the justification given in the summary, and why renaming the v3 driver is needed.

In D5015#106472, @zbb wrote:

Why do we want two drivers with the same name?

We want one (type of) PIC driver and one MSI controller matched by the compatible string or whatever.
The name is strictly for the convenience reasons :-). For example for all PCI bridges you have 'pcib' name and still only one driver attaches.
In addition, this commit prevents from attaching GICv2m on platforms that do not have GICv2m.

But with pcib we have a common driver that attaches to it, this is not the case with the gic driver.

I'm not opposed to the change, querying the justification given in the summary, and why renaming the v3 driver is needed.

OK. So the justification for the change is due to two reasons:

  1. To not attach giv2m on platforms that do not have v2m
  2. Change the driver's name to something more convenient.

Regarding 2. reason: when you attach gic_v3 you get something like this:

gic_v30
gic_v31
...

which may be somehow misleading (apart from the length of both names gic_v3 and gic_v3_its).
That is why we want to change the names to be short and clear. What do you think?

No objections here? Should I commit?

This revision was automatically updated to reflect the committed changes.