Re: [PATCH for-next v5 08/10] RDMA/rxe: Implement invalidate MW operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 4/29/2021 1:12 AM, Zhu Yanjun wrote:
On Thu, Apr 29, 2021 at 11:32 AM Pearson, Robert B
<rpearsonhpe@xxxxxxxxx> wrote:

On 4/28/2021 10:20 PM, Zhu Yanjun wrote:
On Thu, Apr 29, 2021 at 11:07 AM Pearson, Robert B
<rpearsonhpe@xxxxxxxxx> wrote:
On 4/28/2021 7:54 PM, Zhu Yanjun wrote:
Adding a prefix makes debug easy. This can help filter the functions.
And a prefix can help us to verify the location of the function.

Zhu Yanjun
For comparison here are all the subroutine names from a well known
driver file. As you can see, 100% of the non static subroutines *do*
have mlx5 in their name but the majority of the static ones *do not*,
and these are by definition not shared anywhere else but this file. This
is representative of the typical style in linux-rdma.
With perf or ftrace debug tools, a lot of functions will pop out.
A prefix can help the developer to locate the functions source code easily.
And a prefix can help the developer filter the functions conveniently.

This is why I recommend a prefix.

Zhu Yanjun
Yes, I can tell. We're still debating this. Obviously the developers of
mr.c don't entirely agree and I don't either. There are places where it
makes sense but the code is ugly IMHO. I think you should let developers
A prefix can make code easy to debug, then easy to maintain. This is
not ugly code.^o^
On the contrary, it is beautiful code. ^o^

write in the style they are most effective with, especially in the
context of a local static subroutine which have a very narrow scope.
Even though the local static functions still possibly appear in kernel
debug tools,
it is necessary to add a prefix to make it easy to locate and filter.
This can make maintenance
easy.

Zhu Yanjun

Bob

OK, I'll try.

Bob




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux