Skip to content

Conversation

akky16
Copy link
Collaborator

@akky16 akky16 commented Jun 4, 2025

APML modules patches to support Venice.
APML Alert_L module support for Venice.

akky16 and others added 10 commits June 2, 2025 17:32
* From Venice SBRMI device ID is 1, instead of checking each device
  PID, we should check for the  Instance ID.

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
* From Venice SBTSI device ID is 0, instead of checking each device
  PID, we should check for the Instance ID.

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
…A, Fam:0x50

- SBRMI/TSI devices for new APML has PID as per below description.
[11:0]  Additional ID: 0x118
[15:12] SB-TSI(0x0)
[31:16] [16]: DIE_ID, [25:24]: SOCKET ID
                sock 0 die 0: 0x0
                sock 0 die 1: 0x1
                sock 1 die 0: 0x100
                sock 1 die 1: 0x101
[32]: PID type select, it is 0 now to select fixed vendor value;
[47:33]: Manufacture ID, MIPI alliance has allocated the value for each company, AMD should be 0x0112

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
…A, Fam:0x50

- PID for SBRMI devices in Fam:0x1A, Fam:0x50 is defines as:

[11:0]  Additional ID:		0x118
[15:12]	SB-TSI(0x0)/SB-RMI(0x1)
[31:16]	[16]: DIE_ID, [25:24]: SOCKET ID
		sock 0 die 0:		0x0
		sock 0 die 1:		0x1
		sock 1 die 0:		0x100
		sock 1 die 1:		0x101
[32]: PID type select, it is 0 now to select fixed vendor value;
[47:33]: Manufacture ID, MIPI alliance has allocated the value for each company, AMD should be 0x0112

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
- Extra info, part of PID is standard and should not be change.
  This device id will be used by other drivers, which can break.

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
…umber

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
…id number

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
Processors from AMD provide APML ALERT_L for BMC users to
monitor events.
APML Alert_L is asserted in multiple events,
- Machine Check Exception occurs within the system
- The processor alerts the SBI on system fatal error event
- Set by hardware as a result of a 0x71/0x72/0x73 command completion
- Set by firmware to indicate the completion of a mailbox operation
- High/Low Temperature Alert

APML Alert_L module define uevents to notify registered userspace processes
of the alert event.

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
Signed-off-by: sathya priya kumar <[email protected]>
-Add alertl node for morocco and congo platforms

Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
Signed-off-by: Sathya Priya Kumar <[email protected]>
Reviewed-by: Naveen Krishna Chatradhi <[email protected]>
Signed-off-by: Akshay Gupta <[email protected]>
Signed-off-by: sathya priya kumar <[email protected]>
@akky16 akky16 requested review from nchatrad and srgovard June 4, 2025 10:04
static const struct i3c_device_id sbrmi_i3c_id[] = {
I3C_DEVICE_EXTRA_INFO(0, 0x000, 0x1118, NULL), /* P0 - IOD0 - SBRMI */
I3C_DEVICE_EXTRA_INFO(0, 0x100, 0x1118, NULL), /* P1 - IOD0 - SBRMI */
I3C_DEVICE_EXTRA_INFO(0, 0x000, 0x118, NULL), /* P0 - IOD0 - SBRMI */
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sbrmi ID is 0x1118 for Venice. pls check

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i3c_device_match_id function is defined in file drivers/i3c/device.c where the manu_id, partid, ext_info are extracted and matched.
ext_info is assigned in file, drivers/i3c/device.c as
ext_info = I3C_PID_EXTRA_INFO(devinfo.pid);

where I3C_PID_EXTRA_INFO is defined in file "include/linux/i3c/device.h" as
#define I3C_PID_EXTRA_INFO(pid) ((pid) & GENMASK_ULL(11, 0))

ext_info is 12 bit value, the bits [15:12] are the instance ID, which is not part of ext_info

I3C_DEVICE_EXTRA_INFO(0, 0x000, 0x1118, NULL), /* P0 - IOD0 - SBRMI */
I3C_DEVICE_EXTRA_INFO(0, 0x100, 0x1118, NULL), /* P1 - IOD0 - SBRMI */
I3C_DEVICE_EXTRA_INFO(0x112, 0x0, 0x2, NULL),
I3C_DEVICE_EXTRA_INFO(0x112, 0x0, 0x118, NULL), /* Socket:0, IOD:0 */
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sbrmi additional id is 0x1118 not 0x118.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change works on top of the DMA patches where the OR instance ID is removed.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i3c_device_match_id function is defined in file drivers/i3c/device.c where the manu_id, partid, ext_info are extracted and matched.
ext_info is assigned in file, drivers/i3c/device.c as
ext_info = I3C_PID_EXTRA_INFO(devinfo.pid);

where I3C_PID_EXTRA_INFO is defined in file "include/linux/i3c/device.h" as
#define I3C_PID_EXTRA_INFO(pid) ((pid) & GENMASK_ULL(11, 0))

ext_info is 12 bit value, the bits [15:12] are the instance ID, which is not part of ext_info

sbtsi = <&sbtsi_p0_iod0>;
};
};

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add Alert_L node for socket 1.
You can get the LTPI GPIO number from the PR #139

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in PR #143

@srgovard
Copy link
Collaborator

Akshay, Can you please seperate this PR into multiple PRs

  • one for ALERT_L addition
  • one for SBTSI patch
  • one for SBRMI patch

@nchatrad
Copy link
Collaborator

@srgovard split the PR #135 into
#141 for sbtsi
#142 for sbrmi
#143 for alert_l

@nchatrad
Copy link
Collaborator

Hi @srgovard This PR and the DMA patch from https://ontrack-internal.amd.com/browse/FWDEV-126844 into the linux-aspeed are modifying the same files. please sequence them appropriately.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants