[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20181128194905.GE3095@unbuntlaptop>
Date: Wed, 28 Nov 2018 22:49:05 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Michael Straube <straube.linux@...il.com>
Cc: gregkh@...uxfoundation.org, devel@...verdev.osuosl.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/6] staging: rtl8188eu: use __func__ in
hal8188e_rate_adaptive.c
On Wed, Nov 28, 2018 at 06:29:01PM +0100, Michael Straube wrote:
> Use __func__ instead of hardcoded function names.
> Reported by checkpatch.
>
> Signed-off-by: Michael Straube <straube.linux@...il.com>
> ---
> .../rtl8188eu/hal/hal8188e_rate_adaptive.c | 36 ++++++++++---------
> 1 file changed, 20 insertions(+), 16 deletions(-)
>
> diff --git a/drivers/staging/rtl8188eu/hal/hal8188e_rate_adaptive.c b/drivers/staging/rtl8188eu/hal/hal8188e_rate_adaptive.c
> index 6dbd7d261f1e..02f423accee8 100644
> --- a/drivers/staging/rtl8188eu/hal/hal8188e_rate_adaptive.c
> +++ b/drivers/staging/rtl8188eu/hal/hal8188e_rate_adaptive.c
> @@ -127,10 +127,10 @@ static int odm_RateDown_8188E(struct odm_dm_struct *dm_odm,
> u8 i;
>
> ODM_RT_TRACE(dm_odm, ODM_COMP_RATE_ADAPTIVE,
> - ODM_DBG_TRACE, ("=====>odm_RateDown_8188E()\n"));
> + ODM_DBG_TRACE, ("=====>%s()\n", __func__));
This printk has no information that you couldn't get using ftrace.
> if (!pRaInfo) {
> ODM_RT_TRACE(dm_odm, ODM_COMP_RATE_ADAPTIVE, ODM_DBG_LOUD,
> - ("odm_RateDown_8188E(): pRaInfo is NULL\n"));
> + ("%s(): pRaInfo is NULL\n", __func__));
It pRaInfo is never NULL so this is dead code. A lot of this trace
output could just be deleted.
regards,
dan carpenter
Powered by blists - more mailing lists