edac: device: Use poll_msec from registered edac device instead of default
Use the poll_msec set by the driver that registreed an edac device to define the poll time for how often the edac_check callback function should be scheduled. CRs-fixed: 1001207 Change-Id: I973d7fb966cb9f6f9497510df5de000d4f8ffcba Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org> Signed-off-by: Abhimanyu Kapur <abhimany@codeaurora.org>
This commit is contained in:
parent
fe576e32e7
commit
4ea6a48201
1 changed files with 3 additions and 1 deletions
|
@ -411,6 +411,8 @@ void edac_device_workq_setup(struct edac_device_ctl_info *edac_dev,
|
||||||
* to used in the time period calculation
|
* to used in the time period calculation
|
||||||
* then calc the number of jiffies that represents
|
* then calc the number of jiffies that represents
|
||||||
*/
|
*/
|
||||||
|
if (!msec)
|
||||||
|
msec = 1000;
|
||||||
edac_dev->poll_msec = msec;
|
edac_dev->poll_msec = msec;
|
||||||
edac_dev->delay = msecs_to_jiffies(msec);
|
edac_dev->delay = msecs_to_jiffies(msec);
|
||||||
|
|
||||||
|
@ -530,7 +532,7 @@ int edac_device_add_device(struct edac_device_ctl_info *edac_dev)
|
||||||
* enable workq processing on this instance,
|
* enable workq processing on this instance,
|
||||||
* default = 1000 msec
|
* default = 1000 msec
|
||||||
*/
|
*/
|
||||||
edac_device_workq_setup(edac_dev, 1000);
|
edac_device_workq_setup(edac_dev, edac_dev->poll_msec);
|
||||||
} else {
|
} else {
|
||||||
edac_dev->op_state = OP_RUNNING_INTERRUPT;
|
edac_dev->op_state = OP_RUNNING_INTERRUPT;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue