From: Aya Mahfouz Date: Tue, 10 Mar 2015 16:58:00 +0000 (+0200) Subject: staging: mt29f_spinand: remove pointer to pointer cast in function argument X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a511536f4b8815308d178740902826de9c628f59;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git staging: mt29f_spinand: remove pointer to pointer cast in function argument Removes unnecessary pointer to pointer cast on function arguments. It is worth noting that buf is already a u8 pointer. Issue detected and resolved using the following coccinelle script: @@ expression e; type t; identifier f; @@ f(..., -(t *) e ,...) Signed-off-by: Aya Mahfouz Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/mt29f_spinand/mt29f_spinand.c b/drivers/staging/mt29f_spinand/mt29f_spinand.c index 3b191fce45ec..7285c64bac24 100644 --- a/drivers/staging/mt29f_spinand/mt29f_spinand.c +++ b/drivers/staging/mt29f_spinand/mt29f_spinand.c @@ -770,7 +770,7 @@ static void spinand_cmdfunc(struct mtd_info *mtd, unsigned int command, break; case NAND_CMD_READID: state->buf_ptr = 0; - spinand_read_id(info->spi, (u8 *)state->buf); + spinand_read_id(info->spi, state->buf); break; case NAND_CMD_PARAM: state->buf_ptr = 0;