staging: cxt1e1: fix pointer-integer size mismatch warning
PATCH 1/1 staging: cxt1e1: fix pointer-integer size mismatch warning
Fix the pointer-integer size mismatch warning below:
drivers/staging/cxt1e1/functions.c: In function ‘VMETRO_TRACE’:
drivers/staging/cxt1e1/functions.c:268:21: warning: cast from pointer
to integer of different size [-Wpointer-to-int-cast]
u_int32_t y = (u_int32_t) x;
^
--- drivers/staging/cxt1e1/functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/cxt1e1/functions.c +1 -1
@@ -265,7 +265,7 @@ extern ci_t *CI; /* dummy pointer to board ZERO's data */void VMETRO_TRACE (void *x) { -u_int32_t y = (u_int32_t ) x; +u_int32_t y = (u_int32_t )(uintptr_t ) x;pci_write_32 ((u_int32_t *) &CI ->cpldbase->leds, y); }
Signature · 1 line
1.8.3.2
Quoted 6 lines · SeongJae Park
Fix the pointer-integer size mismatch warning below:
drivers/staging/cxt1e1/functions.c: In function ‘VMETRO_TRACE’:
drivers/staging/cxt1e1/functions.c:268:21: warning: cast from pointer
to integer of different size [-Wpointer-to-int-cast]
u_int32_ty = (u_int32_t) x;
^
This function isn't called. Just delete it from here and also from the .h file.
regards,
dan carpenter
Quoted 11 lines · Dan Carpenter
Quoted 6 lines · SeongJae Park
Fix the pointer-integer size mismatch warning below:
drivers/staging/cxt1e1/functions.c: In function ‘VMETRO_TRACE’:
drivers/staging/cxt1e1/functions.c:268:21: warning: cast from pointer
to integer of different size [-Wpointer-to-int-cast]
u_int32_ty = (u_int32_t) x;
^This function isn't called. Just delete it from here and also from the .h file.
Nice review. Thank you for reviewing. I will upload new patch soon.
Quoted 3 lines
regards,
dan carpenter