Re: [patch] Input: remove a duplicative NULL test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Friday, February 21, 2014 6:15 PM, fugang.duan@xxxxxxxxxxxxx wrote:
> 
> From: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> Data: Friday, February 21, 2014 4:55 PM
> 
> >To: Dmitry Torokhov
> >Cc: Paul Gortmaker; Jingoo Han; Duan Fugang-B38611; Benson Leung; Daniel Kurtz;
> >linux-input@xxxxxxxxxxxxxxx; kernel-janitors@xxxxxxxxxxxxxxx
> >Subject: [patch] Input: remove a duplicative NULL test
> >
> >"pdata" is non-NULL here.  We verified that at the start of the function.
> >
> >Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> >
> >diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c
> >b/drivers/input/touchscreen/atmel_mxt_ts.c
> >index a70400754e92..40abe90cc924 100644
> >--- a/drivers/input/touchscreen/atmel_mxt_ts.c
> >+++ b/drivers/input/touchscreen/atmel_mxt_ts.c
> >@@ -1146,7 +1146,7 @@ static int mxt_probe(struct i2c_client *client,
> > 		goto err_free_mem;
> > 	}
> >
> >-	data->is_tp = pdata && pdata->is_tp;
> >+	data->is_tp = pdata->is_tp;
> >
> > 	input_dev->name = (data->is_tp) ? "Atmel maXTouch Touchpad" :
> > 					  "Atmel maXTouch Touchscreen";
> >
> Agree, it is redundant. And if you have free time, you can convert the driver to support devicetree.
> 
> Acked-by: Fugang Duan <B38611@xxxxxxxxxxxxx>

Reviewed-by: Jingoo Han <jg1.han@xxxxxxxxxxx>

Best regards,
Jingoo Han
ÿ淸º{.nÇ+돴윯돪†+%듚ÿ깁負¥Šwÿº{.nÇ+돴¤z받쀸Úž+h?â왲^n‡r⊆¦zË곷h솳鈺Ú&{àz요z받쀺+€Ê+zf"·hš닱~넮녬iÿÿï곴ÿ묎çz_溫æj:+v돣þ)山øm





[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux