Skip to content

Commit 60f4010

Browse files
JoePerchesdavem330
authored andcommitted
alx: Remove casts of pointer to same type
Casting a pointer to a pointer of the same type is pointless, so remove these unnecessary casts. Done via coccinelle script: $ cat typecast_2.cocci @@ type T; T *foo; @@ - (T *)foo + foo Signed-off-by: Joe Perches <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 41ced61 commit 60f4010

File tree

1 file changed

+1
-1
lines changed
  • drivers/net/ethernet/atheros/alx

1 file changed

+1
-1
lines changed

drivers/net/ethernet/atheros/alx/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -535,7 +535,7 @@ static int alx_alloc_descriptors(struct alx_priv *alx)
535535
if (!alx->descmem.virt)
536536
goto out_free;
537537

538-
alx->txq.tpd = (void *)alx->descmem.virt;
538+
alx->txq.tpd = alx->descmem.virt;
539539
alx->txq.tpd_dma = alx->descmem.dma;
540540

541541
/* alignment requirement for next block */

0 commit comments

Comments
 (0)