Commit 881321b6 authored by Vladimir Oltean's avatar Vladimir Oltean Committed by David S. Miller

net: mscc: ocelot: make ocelot_init_timestamp take a const struct ptp_clock_info

It is a good measure to ensure correctness if the structures that are
meant to remain constant are only processed by functions that thake
constant arguments.
Signed-off-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
Reviewed-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ccfdbab5
...@@ -300,7 +300,8 @@ int ocelot_ptp_enable(struct ptp_clock_info *ptp, ...@@ -300,7 +300,8 @@ int ocelot_ptp_enable(struct ptp_clock_info *ptp,
} }
EXPORT_SYMBOL(ocelot_ptp_enable); EXPORT_SYMBOL(ocelot_ptp_enable);
int ocelot_init_timestamp(struct ocelot *ocelot, struct ptp_clock_info *info) int ocelot_init_timestamp(struct ocelot *ocelot,
const struct ptp_clock_info *info)
{ {
struct ptp_clock *ptp_clock; struct ptp_clock *ptp_clock;
int i; int i;
......
...@@ -53,6 +53,7 @@ int ocelot_ptp_verify(struct ptp_clock_info *ptp, unsigned int pin, ...@@ -53,6 +53,7 @@ int ocelot_ptp_verify(struct ptp_clock_info *ptp, unsigned int pin,
enum ptp_pin_function func, unsigned int chan); enum ptp_pin_function func, unsigned int chan);
int ocelot_ptp_enable(struct ptp_clock_info *ptp, int ocelot_ptp_enable(struct ptp_clock_info *ptp,
struct ptp_clock_request *rq, int on); struct ptp_clock_request *rq, int on);
int ocelot_init_timestamp(struct ocelot *ocelot, struct ptp_clock_info *info); int ocelot_init_timestamp(struct ocelot *ocelot,
const struct ptp_clock_info *info);
int ocelot_deinit_timestamp(struct ocelot *ocelot); int ocelot_deinit_timestamp(struct ocelot *ocelot);
#endif #endif
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