Message ID | 1367814240-8959-9-git-send-email-sachin.kamat@linaro.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Dear Sachin Kamat, > Commit 0998d06310 (device-core: Ensure drvdata = NULL when no > driver is bound) removes the need to set driver data field to > NULL. > > Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> > Cc: Marek Vasut <marek.vasut@gmail.com> It does make sense. btw. if you're up to cleaning this up, you can also introduce some devm_input_device_allocate() and switch kzalloc() to devm_kzalloc etc. > --- > drivers/input/keyboard/matrix_keypad.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/input/keyboard/matrix_keypad.c > b/drivers/input/keyboard/matrix_keypad.c index 71d7719..90ff73a 100644 > --- a/drivers/input/keyboard/matrix_keypad.c > +++ b/drivers/input/keyboard/matrix_keypad.c > @@ -549,8 +549,6 @@ static int matrix_keypad_remove(struct platform_device > *pdev) input_unregister_device(keypad->input_dev); > kfree(keypad); > > - platform_set_drvdata(pdev, NULL); > - > return 0; > } Best regards, Marek Vasut -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/input/keyboard/matrix_keypad.c b/drivers/input/keyboard/matrix_keypad.c index 71d7719..90ff73a 100644 --- a/drivers/input/keyboard/matrix_keypad.c +++ b/drivers/input/keyboard/matrix_keypad.c @@ -549,8 +549,6 @@ static int matrix_keypad_remove(struct platform_device *pdev) input_unregister_device(keypad->input_dev); kfree(keypad); - platform_set_drvdata(pdev, NULL); - return 0; }
Commit 0998d06310 (device-core: Ensure drvdata = NULL when no driver is bound) removes the need to set driver data field to NULL. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Cc: Marek Vasut <marek.vasut@gmail.com> --- drivers/input/keyboard/matrix_keypad.c | 2 -- 1 file changed, 2 deletions(-)