diff options
Diffstat (limited to 'drivers/rtc/rtc-rk808.c')
-rw-r--r-- | drivers/rtc/rtc-rk808.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/drivers/rtc/rtc-rk808.c b/drivers/rtc/rtc-rk808.c index 1fb864d4ef83..2316b0343b03 100644 --- a/drivers/rtc/rtc-rk808.c +++ b/drivers/rtc/rtc-rk808.c @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * RTC driver for Rockchip RK808 * @@ -5,15 +6,6 @@ * * Author: Chris Zhong <zyw@rock-chips.com> * Author: Zhang Qing <zhangqing@rock-chips.com> - * - * This program is free software; you can redistribute it and/or modify it - * under the terms and conditions of the GNU General Public License, - * version 2, as published by the Free Software Foundation. - * - * This program is distributed in the hope it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. */ #include <linux/module.h> @@ -336,8 +328,7 @@ static const struct rtc_class_ops rk808_rtc_ops = { /* Turn off the alarm if it should not be a wake source. */ static int rk808_rtc_suspend(struct device *dev) { - struct platform_device *pdev = to_platform_device(dev); - struct rk808_rtc *rk808_rtc = dev_get_drvdata(&pdev->dev); + struct rk808_rtc *rk808_rtc = dev_get_drvdata(dev); if (device_may_wakeup(dev)) enable_irq_wake(rk808_rtc->irq); @@ -350,8 +341,7 @@ static int rk808_rtc_suspend(struct device *dev) */ static int rk808_rtc_resume(struct device *dev) { - struct platform_device *pdev = to_platform_device(dev); - struct rk808_rtc *rk808_rtc = dev_get_drvdata(&pdev->dev); + struct rk808_rtc *rk808_rtc = dev_get_drvdata(dev); if (device_may_wakeup(dev)) disable_irq_wake(rk808_rtc->irq); |