From: Jeongjun Park <hidden> Date: 2025-01-16 16:31:37
Change the if conditional statement in sxgbe_rx_ctxt_wbstatus() to a switch
conditional statement to improve readability, and also add processing for
cases where all conditions are not satisfied.
Signed-off-by: Jeongjun Park <redacted>
---
.../net/ethernet/samsung/sxgbe/sxgbe_desc.c | 43 +++++++++++++------
1 file changed, 30 insertions(+), 13 deletions(-)
From: Simon Horman <horms@kernel.org> Date: 2025-01-17 10:29:24
On Fri, Jan 17, 2025 at 01:03:14AM +0900, Jeongjun Park wrote:
quoted hunk
Change the if conditional statement in sxgbe_rx_ctxt_wbstatus() to a switch
conditional statement to improve readability, and also add processing for
cases where all conditions are not satisfied.
Signed-off-by: Jeongjun Park <redacted>
---
.../net/ethernet/samsung/sxgbe/sxgbe_desc.c | 43 +++++++++++++------
1 file changed, 30 insertions(+), 13 deletions(-)
Hi Jeongjun,
I was wondering if it would be best if the error message above should be
rate limited, or perhaps the callback enhanced to return an error in such
cases. But that depends on where sxgbe_rx_ctxt_wbstatus is called.
And I'm unable to find where the it called.
I see that sxgbe_rx_ctxt_wbstatus is registered as a get_rx_ctxt_tstamp_status
callback. But is the get_rx_ctxt_tstamp_status callback called anywhere?
From: Jeongjun Park <hidden> Date: 2025-02-19 14:47:41
Simon Horman [off-list ref] wrote:
On Fri, Jan 17, 2025 at 01:03:14AM +0900, Jeongjun Park wrote:
quoted
Change the if conditional statement in sxgbe_rx_ctxt_wbstatus() to a switch
conditional statement to improve readability, and also add processing for
cases where all conditions are not satisfied.
Signed-off-by: Jeongjun Park <redacted>
---
.../net/ethernet/samsung/sxgbe/sxgbe_desc.c | 43 +++++++++++++------
1 file changed, 30 insertions(+), 13 deletions(-)
Hi Jeongjun,
I was wondering if it would be best if the error message above should be
rate limited, or perhaps the callback enhanced to return an error in such
cases. But that depends on where sxgbe_rx_ctxt_wbstatus is called.
And I'm unable to find where the it called.
I see that sxgbe_rx_ctxt_wbstatus is registered as a get_rx_ctxt_tstamp_status
callback. But is the get_rx_ctxt_tstamp_status callback called anywhere?
Hello. Sorry for the late reply.
I still don't know exactly where sxgbe_rx_ctxt_wbstatus() is called. What I
do know is that I can't find a function that calls this function within the
Linux kernel. When I wrote this patch, I thought it would be good to refactor
this function, so I wrote the patch, but I didn't know exactly where
this function
was being used. I think it might be a function called from an external
kernel driver
written by Samsung itself.
Regards,
Jeongjun Park