diff options
author | Jiri Pirko <jiri@nvidia.com> | 2024-01-30 15:08:30 +0300 |
---|---|---|
committer | Paolo Abeni <pabeni@redhat.com> | 2024-02-01 17:39:44 +0300 |
commit | e2ca9e75849e63eab6544549b6888595997e8153 (patch) | |
tree | eac6f96bd7b363da6717b2ed7e8bdcc94947b881 /drivers/ptp/ptp_ocp.c | |
parent | cf4f0f1e1c465da7c1f6bc89c3ff50bf42f0ab02 (diff) | |
download | linux-e2ca9e75849e63eab6544549b6888595997e8153.tar.xz |
dpll: extend lock_status_get() op by status error and expose to user
Pass additional argunent status_error over lock_status_get()
so drivers can fill it up. In case they do, expose the value over
previously introduced attribute to user. Do it only in case the
current lock_status is either "unlocked" or "holdover".
Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Acked-by: Vadim Fedorenko <vadim.fedorenko@linux.dev>
Reviewed-by: Simon Horman <horms@kernel.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'drivers/ptp/ptp_ocp.c')
-rw-r--r-- | drivers/ptp/ptp_ocp.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/ptp/ptp_ocp.c b/drivers/ptp/ptp_ocp.c index 5f858e426bbd..9507681e0d12 100644 --- a/drivers/ptp/ptp_ocp.c +++ b/drivers/ptp/ptp_ocp.c @@ -4209,10 +4209,11 @@ ptp_ocp_detach(struct ptp_ocp *bp) device_unregister(&bp->dev); } -static int ptp_ocp_dpll_lock_status_get(const struct dpll_device *dpll, - void *priv, - enum dpll_lock_status *status, - struct netlink_ext_ack *extack) +static int +ptp_ocp_dpll_lock_status_get(const struct dpll_device *dpll, void *priv, + enum dpll_lock_status *status, + enum dpll_lock_status_error *status_error, + struct netlink_ext_ack *extack) { struct ptp_ocp *bp = priv; |