Commit 345be427 authored by Nathan Chancellor's avatar Nathan Chancellor Committed by Rafael J. Wysocki

thermal: netlink: Fix parameter type of thermal_genl_cpu_capability_event() stub

When building with CONFIG_THERMAL_NETLINK=n, there is a spew of warnings
along the lines of:

  In file included from drivers/thermal/thermal_core.c:27:
  In file included from drivers/thermal/thermal_core.h:15:
  drivers/thermal/thermal_netlink.h:113:71: warning: declaration of 'struct cpu_capability' will not be visible outside of this function [-Wvisibility]
  static inline int thermal_genl_cpu_capability_event(int count, struct cpu_capability *caps)
                                                                        ^
  1 warning generated.

'struct cpu_capability' is not forward declared anywhere in the header.
As it turns out, this should really be 'struct thermal_genl_cpu_caps',
which silences the warning and makes the parameter types of the stub
match the full function.

Fixes: e4b1eb24 ("thermal: netlink: Add a new event to notify CPU capabilities change")
Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: default avatarNathan Chancellor <nathan@kernel.org>
Reviewed-by: default avatarSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent bd30cdfd
......@@ -110,7 +110,7 @@ static inline int thermal_genl_sampling_temp(int id, int temp)
return 0;
}
static inline int thermal_genl_cpu_capability_event(int count, struct cpu_capability *caps)
static inline int thermal_genl_cpu_capability_event(int count, struct thermal_genl_cpu_caps *caps)
{
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment