Commit d8f447877b1cd40267a66c6d9fcd11464c859346
Committed by
Linus Torvalds
1 parent
4802f224a5
Exists in
smarc-imx_3.14.28_1.0.0_ga
and in
1 other branch
rtc: rtc-mc13xxx: remove unnecessary platform_set_drvdata()
The driver core clears the driver data to NULL after device_release or on probe failure, since commit 0998d063100 ("device-core: Ensure drvdata = NULL when no driver is bound"). Thus, it is not needed to manually clear the device driver data to NULL. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 1 changed file with 0 additions and 4 deletions Side-by-side Diff
drivers/rtc/rtc-mc13xxx.c
... | ... | @@ -370,8 +370,6 @@ |
370 | 370 | err_reset_irq_request: |
371 | 371 | |
372 | 372 | mc13xxx_unlock(mc13xxx); |
373 | - | |
374 | - platform_set_drvdata(pdev, NULL); | |
375 | 373 | } |
376 | 374 | |
377 | 375 | return ret; |
... | ... | @@ -388,8 +386,6 @@ |
388 | 386 | mc13xxx_irq_free(priv->mc13xxx, MC13XXX_IRQ_RTCRST, priv); |
389 | 387 | |
390 | 388 | mc13xxx_unlock(priv->mc13xxx); |
391 | - | |
392 | - platform_set_drvdata(pdev, NULL); | |
393 | 389 | |
394 | 390 | return 0; |
395 | 391 | } |