Re: [PATCH 1/3] amd_sfh: Extend driver capabilities for multi-generation support

2 messages, 2 authors, 2021-06-22 · open the first message on its own page

Re: [PATCH 1/3] amd_sfh: Extend driver capabilities for multi-generation support

From: Dylan MacKenzie <hidden>
Date: 2021-06-22 04:46:29

+static void amd_stop_sensor_v2(struct amd_mp2_dev *privdata, u16 sensor_idx)
+{
+ union sfh_cmd_base cmd_base;
+
+ cmd_base.ul = 0;
+ cmd_base.cmd_v2.cmd_id = DISABLE_SENSOR;
+ cmd_base.cmd_v2.period = 0;
+ cmd_base.cmd_v2.sensor_id = sensor_idx;
+ cmd_base.cmd_v2.length  = 16;
+
+ writeq(0x0, privdata->mmio + AMD_C2P_MSG2);
That should be AMD_C2P_MSG1, no? The new hardware has no param register.

Re: [PATCH 1/3] amd_sfh: Extend driver capabilities for multi-generation support

From: Basavaraj Natikar <hidden>
Date: 2021-06-22 05:14:30

Hi

Thanks for the review.

On 6/22/2021 10:16 AM, Dylan MacKenzie wrote:
[CAUTION: External Email]
quoted
+static void amd_stop_sensor_v2(struct amd_mp2_dev *privdata, u16 sensor_idx)
+{
+ union sfh_cmd_base cmd_base;
+
+ cmd_base.ul = 0;
+ cmd_base.cmd_v2.cmd_id = DISABLE_SENSOR;
+ cmd_base.cmd_v2.period = 0;
+ cmd_base.cmd_v2.sensor_id = sensor_idx;
+ cmd_base.cmd_v2.length  = 16;
+
+ writeq(0x0, privdata->mmio + AMD_C2P_MSG2);
That should be AMD_C2P_MSG1, no? The new hardware has no param register.
As per our firmware spec to stop the sensor from streaming the data,
1. Clear the dram address using AMD_C2P_MSG2 register.
2. Send DISABLE_SENSOR using AMD_C2P_MSG0 register.

This what precisely above function does.

Thanks,

Basavaraj
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help