History

ARM: 8838/1: drivers: amba: Updates to component identification for driver matching.

The CoreSight specification (ARM IHI 0029E), updates the ID register requirements for components on an AMBA bus, to cover both traditional ARM Primecell type devices, and newer CoreSight and other components. The Peripheral ID (PID) / Component ID (CID) pair is extended in certain cases to uniquely identify components. CoreSight components related to a single function can share Peripheral ID values, and must be further identified using a Unique Component Identifier (UCI). e.g. the ETM, CTI, PMU and Debug hardware of the A35 all share the same PID. Bits 15:12 of the CID are defined to be the device class. Class 0xF remains for PrimeCell and legacy components. Class 0x9 defines the component as CoreSight (CORESIGHT_CID above) Class 0x0, 0x1, 0xB, 0xE define components that do not have driver support at present. Class 0x2-0x8,0xA and 0xD-0xD are presently reserved. The specification futher defines which classes of device use the standard CID/PID pair, and when additional ID registers are required. This patch introduces the amba_cs_uci_id structure which will be used in all coresight drivers for indentification via the private data pointer in the amba_id structure. Existing drivers that currently use the amba_id->data pointer for private data are updated to use the amba_cs_uci_id->data pointer. Macros and inline functions are added to simplify this code.

Mike Leach committed 7 years ago

Commit e85fa281 parent de9c0d45 files · +90 −63Browse files

Showing the changes to include/linux (1 of 5 files). Show all

Unified · Split

include/linux/amba/bus.h+33−0
@@ -25,6 +25,39 @@ · 24 unmodified lines
2525 #define AMBA_CID 0xb105f00d
2626 #define CORESIGHT_CID 0xb105900d
2727
28+/*
29+ * CoreSight Architecture specification updates the ID specification
30+ * for components on the AMBA bus. (ARM IHI 0029E)
31+ *
32+ * Bits 15:12 of the CID are the device class.
33+ *
34+ * Class 0xF remains for PrimeCell and legacy components. (AMBA_CID above)
35+ * Class 0x9 defines the component as CoreSight (CORESIGHT_CID above)
36+ * Class 0x0, 0x1, 0xB, 0xE define components that do not have driver support
37+ * at present.
38+ * Class 0x2-0x8,0xA and 0xD-0xD are presently reserved.
39+ *
40+ * Remaining CID bits stay as 0xb105-00d
41+ */
42+
43+/**
44+ * Class 0x9 components use additional values to form a Unique Component
45+ * Identifier (UCI), where peripheral ID values are identical for different
46+ * components. Passed to the amba bus code from the component driver via
47+ * the amba_id->data pointer.
48+ * @devarch : coresight devarch register value
49+ * @devarch_mask: mask bits used for matching. 0 indicates UCI not used.
50+ * @devtype : coresight device type value
51+ * @data : additional driver data. As we have usurped the original
52+ * pointer some devices may still need additional data
53+ */
54+struct amba_cs_uci_id {
55+ unsigned int devarch;
56+ unsigned int devarch_mask;
57+ unsigned int devtype;
58+ void *data;
59+};
60+
2861 struct clk;
2962
3063 struct amba_device {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t