jz4740_wdt.c (3c53c6255d598db7084c5c3d7553d7200e857818) | jz4740_wdt.c (9ee644c9326cd5ad5080408820075465b51c9c16) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-or-later 2/* 3 * Copyright (C) 2010, Paul Cercueil <paul@crapouillou.net> 4 * JZ4740 Watchdog driver 5 */ 6 7#include <linux/module.h> 8#include <linux/moduleparam.h> --- 173 unchanged lines hidden (view full) --- 182 return PTR_ERR(drvdata->base); 183 184 drvdata->rtc_clk = devm_clk_get(dev, "rtc"); 185 if (IS_ERR(drvdata->rtc_clk)) { 186 dev_err(dev, "cannot find RTC clock\n"); 187 return PTR_ERR(drvdata->rtc_clk); 188 } 189 | 1// SPDX-License-Identifier: GPL-2.0-or-later 2/* 3 * Copyright (C) 2010, Paul Cercueil <paul@crapouillou.net> 4 * JZ4740 Watchdog driver 5 */ 6 7#include <linux/module.h> 8#include <linux/moduleparam.h> --- 173 unchanged lines hidden (view full) --- 182 return PTR_ERR(drvdata->base); 183 184 drvdata->rtc_clk = devm_clk_get(dev, "rtc"); 185 if (IS_ERR(drvdata->rtc_clk)) { 186 dev_err(dev, "cannot find RTC clock\n"); 187 return PTR_ERR(drvdata->rtc_clk); 188 } 189 |
190 ret = devm_watchdog_register_device(dev, &drvdata->wdt); 191 if (ret < 0) 192 return ret; 193 194 return 0; | 190 return devm_watchdog_register_device(dev, &drvdata->wdt); |
195} 196 197static struct platform_driver jz4740_wdt_driver = { 198 .probe = jz4740_wdt_probe, 199 .driver = { 200 .name = "jz4740-wdt", 201 .of_match_table = of_match_ptr(jz4740_wdt_of_matches), 202 }, 203}; 204 205module_platform_driver(jz4740_wdt_driver); 206 207MODULE_AUTHOR("Paul Cercueil <paul@crapouillou.net>"); 208MODULE_DESCRIPTION("jz4740 Watchdog Driver"); 209MODULE_LICENSE("GPL"); 210MODULE_ALIAS("platform:jz4740-wdt"); | 191} 192 193static struct platform_driver jz4740_wdt_driver = { 194 .probe = jz4740_wdt_probe, 195 .driver = { 196 .name = "jz4740-wdt", 197 .of_match_table = of_match_ptr(jz4740_wdt_of_matches), 198 }, 199}; 200 201module_platform_driver(jz4740_wdt_driver); 202 203MODULE_AUTHOR("Paul Cercueil <paul@crapouillou.net>"); 204MODULE_DESCRIPTION("jz4740 Watchdog Driver"); 205MODULE_LICENSE("GPL"); 206MODULE_ALIAS("platform:jz4740-wdt"); |