Skip to content

Commit b4ac75a

Browse files
committed
Merge branch 'fix-a-couple-recent-instances-of-wincompatible-function-pointer-types-strict-from-mode_get-implementations'
Nathan Chancellor says: ==================== Fix a couple recent instances of -Wincompatible-function-pointer-types-strict from ->mode_get() implementations This series fixes a couple of instances of -Wincompatible-function-pointer-types-strict that were introduced by a recent series that added a new type of ops, struct dpll_device_ops, along with implementations of the callback ->mode_get() that had a mismatched mode type. This warning is not currently enabled for any build but I am planning on submitting a patch to add it to W=1 to prevent new instances of the warning from popping up while we try and fix the existing instances in other drivers. This series is based on current net-next but if they need to go into individual maintainer trees, please feel free to take the patches individually. ==================== Link: https://lore.kernel.org/r/20231002-net-wifpts-dpll_mode_get-v1-0-a356a16413cf@kernel.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2 parents 78cac6f + f4ecb3d commit b4ac75a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

drivers/net/ethernet/mellanox/mlx5/core/dpll.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,8 @@ static int mlx5_dpll_device_lock_status_get(const struct dpll_device *dpll,
121121
}
122122

123123
static int mlx5_dpll_device_mode_get(const struct dpll_device *dpll,
124-
void *priv,
125-
u32 *mode, struct netlink_ext_ack *extack)
124+
void *priv, enum dpll_mode *mode,
125+
struct netlink_ext_ack *extack)
126126
{
127127
*mode = DPLL_MODE_MANUAL;
128128
return 0;

drivers/ptp/ptp_ocp.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4255,7 +4255,7 @@ static int ptp_ocp_dpll_state_get(const struct dpll_pin *pin, void *pin_priv,
42554255
}
42564256

42574257
static int ptp_ocp_dpll_mode_get(const struct dpll_device *dpll, void *priv,
4258-
u32 *mode, struct netlink_ext_ack *extack)
4258+
enum dpll_mode *mode, struct netlink_ext_ack *extack)
42594259
{
42604260
*mode = DPLL_MODE_AUTOMATIC;
42614261
return 0;

0 commit comments

Comments
 (0)