From: Jonathan Lemon Date: Wed, 16 Mar 2022 16:53:47 +0000 (-0700) Subject: ptp: ocp: Make debugfs variables the correct bitwidth X-Git-Tag: v6.6.17~7931^2~48 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2b341f7532d4f6c8b84206daad202a745962b844;p=platform%2Fkernel%2Flinux-rpi.git ptp: ocp: Make debugfs variables the correct bitwidth An earlier patch mistakenly changed these variables from u32 to u16, leading to unintended truncation. Restore the original logic. Fixes: a509a7c61e3b ("ptp: ocp: Add support for selectable SMA directions.") Reported-by: Dan Carpenter Signed-off-by: Jonathan Lemon Link: https://lore.kernel.org/r/20220316165347.599154-1-jonathan.lemon@gmail.com Signed-off-by: Jakub Kicinski --- diff --git a/drivers/ptp/ptp_ocp.c b/drivers/ptp/ptp_ocp.c index d8cefc8..d64a1ce 100644 --- a/drivers/ptp/ptp_ocp.c +++ b/drivers/ptp/ptp_ocp.c @@ -2983,11 +2983,12 @@ ptp_ocp_summary_show(struct seq_file *s, void *data) { struct device *dev = s->private; struct ptp_system_timestamp sts; - u16 sma_val[4][2], ctrl, val; struct ts_reg __iomem *ts_reg; struct timespec64 ts; struct ptp_ocp *bp; + u16 sma_val[4][2]; char *src, *buf; + u32 ctrl, val; bool on, map; int i;