* [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
@ 2023-05-17 2:27 wuych
2023-05-17 3:17 ` Jakub Kicinski
0 siblings, 1 reply; 6+ messages in thread
From: wuych @ 2023-05-17 2:27 UTC (permalink / raw)
To: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, kuba, pabeni
Cc: netdev, linux-kernel, kernel-janitors, wuych
Pointer variables of void * type do not require type cast.
Signed-off-by: wuych <yunchuan@nfschina.com>
---
drivers/net/ethernet/brocade/bna/bnad.c | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/drivers/net/ethernet/brocade/bna/bnad.c b/drivers/net/ethernet/brocade/bna/bnad.c
index d6d90f9722a7..31191b520b58 100644
--- a/drivers/net/ethernet/brocade/bna/bnad.c
+++ b/drivers/net/ethernet/brocade/bna/bnad.c
@@ -1037,8 +1037,7 @@ bnad_cb_ccb_destroy(struct bnad *bnad, struct bna_ccb *ccb)
static void
bnad_cb_tx_stall(struct bnad *bnad, struct bna_tx *tx)
{
- struct bnad_tx_info *tx_info =
- (struct bnad_tx_info *)tx->priv;
+ struct bnad_tx_info *tx_info = tx->priv;
struct bna_tcb *tcb;
u32 txq_id;
int i;
@@ -1056,7 +1055,7 @@ bnad_cb_tx_stall(struct bnad *bnad, struct bna_tx *tx)
static void
bnad_cb_tx_resume(struct bnad *bnad, struct bna_tx *tx)
{
- struct bnad_tx_info *tx_info = (struct bnad_tx_info *)tx->priv;
+ struct bnad_tx_info *tx_info = tx->priv;
struct bna_tcb *tcb;
u32 txq_id;
int i;
@@ -1133,7 +1132,7 @@ bnad_tx_cleanup(struct delayed_work *work)
static void
bnad_cb_tx_cleanup(struct bnad *bnad, struct bna_tx *tx)
{
- struct bnad_tx_info *tx_info = (struct bnad_tx_info *)tx->priv;
+ struct bnad_tx_info *tx_info = tx->priv;
struct bna_tcb *tcb;
int i;
@@ -1149,7 +1148,7 @@ bnad_cb_tx_cleanup(struct bnad *bnad, struct bna_tx *tx)
static void
bnad_cb_rx_stall(struct bnad *bnad, struct bna_rx *rx)
{
- struct bnad_rx_info *rx_info = (struct bnad_rx_info *)rx->priv;
+ struct bnad_rx_info *rx_info = rx->priv;
struct bna_ccb *ccb;
struct bnad_rx_ctrl *rx_ctrl;
int i;
@@ -1208,7 +1207,7 @@ bnad_rx_cleanup(void *work)
static void
bnad_cb_rx_cleanup(struct bnad *bnad, struct bna_rx *rx)
{
- struct bnad_rx_info *rx_info = (struct bnad_rx_info *)rx->priv;
+ struct bnad_rx_info *rx_info = rx->priv;
struct bna_ccb *ccb;
struct bnad_rx_ctrl *rx_ctrl;
int i;
@@ -1231,7 +1230,7 @@ bnad_cb_rx_cleanup(struct bnad *bnad, struct bna_rx *rx)
static void
bnad_cb_rx_post(struct bnad *bnad, struct bna_rx *rx)
{
- struct bnad_rx_info *rx_info = (struct bnad_rx_info *)rx->priv;
+ struct bnad_rx_info *rx_info = rx->priv;
struct bna_ccb *ccb;
struct bna_rcb *rcb;
struct bnad_rx_ctrl *rx_ctrl;
--
2.30.2
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
2023-05-17 2:27 [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions wuych
@ 2023-05-17 3:17 ` Jakub Kicinski
2023-05-17 5:14 ` yunchuan
0 siblings, 1 reply; 6+ messages in thread
From: Jakub Kicinski @ 2023-05-17 3:17 UTC (permalink / raw)
To: wuych
Cc: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, pabeni,
netdev, linux-kernel, kernel-janitors
On Wed, 17 May 2023 10:27:05 +0800 wuych wrote:
> Pointer variables of void * type do not require type cast.
What tool are you using to find these.
How many of such patches will it take to clean up the entire tree?
--
pw-bot: reject
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
2023-05-17 3:17 ` Jakub Kicinski
@ 2023-05-17 5:14 ` yunchuan
2023-05-17 15:18 ` Jakub Kicinski
0 siblings, 1 reply; 6+ messages in thread
From: yunchuan @ 2023-05-17 5:14 UTC (permalink / raw)
To: Jakub Kicinski
Cc: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, pabeni,
netdev, linux-kernel, kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 408 bytes --]
在 2023/5/17 11:17, Jakub Kicinski 写道:
> On Wed, 17 May 2023 10:27:05 +0800 wuych wrote:
>> Pointer variables of void * type do not require type cast.
> What tool are you using to find these.
> How many of such patches will it take to clean up the entire tree?
I use the scripts I found on the kernel Newbies to find these.
website: https://kernelnewbies.org/KernelJanitors/Todo/VoidPointerConvs
[-- Attachment #2: type-convs.pl --]
[-- Type: application/x-perl, Size: 1175 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
2023-05-17 5:14 ` yunchuan
@ 2023-05-17 15:18 ` Jakub Kicinski
2023-05-19 1:38 ` yunchuan
0 siblings, 1 reply; 6+ messages in thread
From: Jakub Kicinski @ 2023-05-17 15:18 UTC (permalink / raw)
To: yunchuan
Cc: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, pabeni,
netdev, linux-kernel, kernel-janitors
On Wed, 17 May 2023 13:14:11 +0800 yunchuan wrote:
> 在 2023/5/17 11:17, Jakub Kicinski 写道:
> > On Wed, 17 May 2023 10:27:05 +0800 wuych wrote:
> >> Pointer variables of void * type do not require type cast.
> > What tool are you using to find these.
> > How many of such patches will it take to clean up the entire tree?
>
> I use the scripts I found on the kernel Newbies to find these.
>
> website: https://kernelnewbies.org/KernelJanitors/Todo/VoidPointerConvs
How many of such patches will it take to clean up all of net/ and drivers/net ?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
2023-05-17 15:18 ` Jakub Kicinski
@ 2023-05-19 1:38 ` yunchuan
2023-05-19 2:46 ` Jakub Kicinski
0 siblings, 1 reply; 6+ messages in thread
From: yunchuan @ 2023-05-19 1:38 UTC (permalink / raw)
To: Jakub Kicinski
Cc: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, pabeni,
netdev, linux-kernel, kernel-janitors
在 2023/5/17 23:18, Jakub Kicinski 写道:
> On Wed, 17 May 2023 13:14:11 +0800 yunchuan wrote:
>> 在 2023/5/17 11:17, Jakub Kicinski 写道:
>>> On Wed, 17 May 2023 10:27:05 +0800 wuych wrote:
>>>> Pointer variables of void * type do not require type cast.
>>> What tool are you using to find these.
>>> How many of such patches will it take to clean up the entire tree?
>> I use the scripts I found on the kernel Newbies to find these.
>>
>> website: https://kernelnewbies.org/KernelJanitors/Todo/VoidPointerConvs
> How many of such patches will it take to clean up all of net/ and drivers/net ?
I have identified 48 areas that need to be modified using the script,
and have not yet confirmed whether all of them need to be modified.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions
2023-05-19 1:38 ` yunchuan
@ 2023-05-19 2:46 ` Jakub Kicinski
0 siblings, 0 replies; 6+ messages in thread
From: Jakub Kicinski @ 2023-05-19 2:46 UTC (permalink / raw)
To: yunchuan
Cc: rmody, skalluru, GR-Linux-NIC-Dev, davem, edumazet, pabeni,
netdev, linux-kernel, kernel-janitors
On Fri, 19 May 2023 09:38:49 +0800 yunchuan wrote:
> >> website: https://kernelnewbies.org/KernelJanitors/Todo/VoidPointerConvs
> > How many of such patches will it take to clean up all of net/ and drivers/net ?
>
> I have identified 48 areas that need to be modified using the script,
> and have not yet confirmed whether all of them need to be modified.
Once you have worked thru all - please send the changes in series of
10 patches at a time.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-05-19 2:46 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-05-17 2:27 [PATCH net-next] net: bna: bnad: Remove unnecessary (void*) conversions wuych
2023-05-17 3:17 ` Jakub Kicinski
2023-05-17 5:14 ` yunchuan
2023-05-17 15:18 ` Jakub Kicinski
2023-05-19 1:38 ` yunchuan
2023-05-19 2:46 ` Jakub Kicinski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).