|
@@ -241,18 +241,18 @@ static int pld_snoc_resume_noirq(struct device *dev)
|
|
|
}
|
|
|
|
|
|
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 19, 0))
|
|
|
-static int pld_update_hang_evt_data(struct icnss_uevent_fw_down_data *evt_data,
|
|
|
+static int pld_update_hang_evt_data(struct icnss_uevent_hang_data *evt_data,
|
|
|
struct pld_uevent_data *data)
|
|
|
{
|
|
|
if (!evt_data || !data)
|
|
|
return -EINVAL;
|
|
|
|
|
|
- data->fw_down.hang_event_data = evt_data->hang_event_data;
|
|
|
- data->fw_down.hang_event_data_len = evt_data->hang_event_data_len;
|
|
|
+ data->hang_data.hang_event_data = evt_data->hang_event_data;
|
|
|
+ data->hang_data.hang_event_data_len = evt_data->hang_event_data_len;
|
|
|
return 0;
|
|
|
}
|
|
|
#else
|
|
|
-static int pld_update_hang_evt_data(struct icnss_uevent_fw_down_data *evt_data,
|
|
|
+static int pld_update_hang_evt_data(struct icnss_uevent_hang_data *evt_data,
|
|
|
struct pld_uevent_data *data)
|
|
|
{
|
|
|
return 0;
|
|
@@ -263,7 +263,8 @@ static int pld_snoc_uevent(struct device *dev,
|
|
|
struct icnss_uevent_data *uevent)
|
|
|
{
|
|
|
struct pld_context *pld_context;
|
|
|
- struct icnss_uevent_fw_down_data *uevent_data = NULL;
|
|
|
+ struct icnss_uevent_fw_down_data *fw_down_data = NULL;
|
|
|
+ struct icnss_uevent_hang_data *hang_data = NULL;
|
|
|
struct pld_uevent_data data = {0};
|
|
|
|
|
|
pld_context = pld_get_global_context();
|
|
@@ -283,10 +284,16 @@ static int pld_snoc_uevent(struct device *dev,
|
|
|
case ICNSS_UEVENT_FW_DOWN:
|
|
|
if (!uevent->data)
|
|
|
return -EINVAL;
|
|
|
- uevent_data = (struct icnss_uevent_fw_down_data *)uevent->data;
|
|
|
+ fw_down_data = (struct icnss_uevent_fw_down_data *)uevent->data;
|
|
|
data.uevent = PLD_FW_DOWN;
|
|
|
- data.fw_down.crashed = uevent_data->crashed;
|
|
|
- pld_update_hang_evt_data(uevent_data, &data);
|
|
|
+ data.fw_down.crashed = fw_down_data->crashed;
|
|
|
+ break;
|
|
|
+ case ICNSS_UEVENT_HANG_DATA:
|
|
|
+ if (!uevent->data)
|
|
|
+ return -EINVAL;
|
|
|
+ hang_data = (struct icnss_uevent_hang_data *)uevent->data;
|
|
|
+ data.uevent = PLD_FW_HANG_EVENT;
|
|
|
+ pld_update_hang_evt_data(hang_data, &data);
|
|
|
break;
|
|
|
default:
|
|
|
goto out;
|