summaryrefslogtreecommitdiffstats
path: root/include/soc/fsl
diff options
context:
space:
mode:
authorMadalin Bucur <madalin.bucur@nxp.com>2018-11-21 12:41:08 +0100
committerDavid S. Miller <davem@davemloft.net>2018-11-23 20:17:06 +0100
commit5c664ace8cdfd947d293b97871a4f1e4bedca5b9 (patch)
treea358e07f4e94a5425390e3abea87c009cd176047 /include/soc/fsl
parentsoc: fsl: qbman: read ithresh from HW (diff)
downloadlinux-5c664ace8cdfd947d293b97871a4f1e4bedca5b9.tar.xz
linux-5c664ace8cdfd947d293b97871a4f1e4bedca5b9.zip
soc/qman: add return value to interrupt coalesce changing APIs
Check that the values received by the portal interrupt coalesce change APIs are in range. Signed-off-by: Madalin Bucur <madalin.bucur@nxp.com> Signed-off-by: Roy Pledge <roy.pledge@nxp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/soc/fsl')
-rw-r--r--include/soc/fsl/qman.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/soc/fsl/qman.h b/include/soc/fsl/qman.h
index 56877660d5ba..5cc7af06c1ba 100644
--- a/include/soc/fsl/qman.h
+++ b/include/soc/fsl/qman.h
@@ -1205,8 +1205,10 @@ void qman_dqrr_get_ithresh(struct qman_portal *portal, u8 *ithresh);
* qman_dqrr_set_ithresh - Set coalesce interrupt threshold
* @portal: portal to set the new value on
* @ithresh: new threshold value
+ *
+ * Returns 0 on success, or a negative error code.
*/
-void qman_dqrr_set_ithresh(struct qman_portal *portal, u8 ithresh);
+int qman_dqrr_set_ithresh(struct qman_portal *portal, u8 ithresh);
/**
* qman_dqrr_get_iperiod - Get coalesce interrupt period
@@ -1219,7 +1221,9 @@ void qman_portal_get_iperiod(struct qman_portal *portal, u32 *iperiod);
* qman_dqrr_set_iperiod - Set coalesce interrupt period
* @portal: portal to set the new value on
* @ithresh: new period value
+ *
+ * Returns 0 on success, or a negative error code.
*/
-void qman_portal_set_iperiod(struct qman_portal *portal, u32 iperiod);
+int qman_portal_set_iperiod(struct qman_portal *portal, u32 iperiod);
#endif /* __FSL_QMAN_H */