| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Spreadtrum pin controller driver |
|---|
| 3 | 4 | * Copyright (C) 2017 Spreadtrum - http://www.spreadtrum.com |
|---|
| 4 | | - * |
|---|
| 5 | | - * This program is free software; you can redistribute it and/or |
|---|
| 6 | | - * modify it under the terms of the GNU General Public License |
|---|
| 7 | | - * version 2 as published by the Free Software Foundation. |
|---|
| 8 | | - * |
|---|
| 9 | | - * This program is distributed in the hope that it will be useful, but |
|---|
| 10 | | - * WITHOUT ANY WARRANTY; without even the implied warranty of |
|---|
| 11 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|---|
| 12 | | - * General Public License for more details. |
|---|
| 13 | 5 | */ |
|---|
| 14 | 6 | |
|---|
| 15 | 7 | #include <linux/module.h> |
|---|
| .. | .. |
|---|
| 948 | 940 | static struct platform_driver sprd_pinctrl_driver = { |
|---|
| 949 | 941 | .driver = { |
|---|
| 950 | 942 | .name = "sprd-pinctrl", |
|---|
| 951 | | - .owner = THIS_MODULE, |
|---|
| 952 | 943 | .of_match_table = sprd_pinctrl_of_match, |
|---|
| 953 | 944 | }, |
|---|
| 954 | 945 | .probe = sprd_pinctrl_probe, |
|---|
| 955 | 946 | .remove = sprd_pinctrl_remove, |
|---|
| 956 | 947 | .shutdown = sprd_pinctrl_shutdown, |
|---|
| 957 | 948 | }; |
|---|
| 958 | | - |
|---|
| 959 | | -static int sprd_pinctrl_init(void) |
|---|
| 960 | | -{ |
|---|
| 961 | | - return platform_driver_register(&sprd_pinctrl_driver); |
|---|
| 962 | | -} |
|---|
| 963 | | -module_init(sprd_pinctrl_init); |
|---|
| 964 | | - |
|---|
| 965 | | -static void sprd_pinctrl_exit(void) |
|---|
| 966 | | -{ |
|---|
| 967 | | - platform_driver_unregister(&sprd_pinctrl_driver); |
|---|
| 968 | | -} |
|---|
| 969 | | -module_exit(sprd_pinctrl_exit); |
|---|
| 949 | +module_platform_driver(sprd_pinctrl_driver); |
|---|
| 970 | 950 | |
|---|
| 971 | 951 | MODULE_DESCRIPTION("SPREADTRUM Pin Controller Driver"); |
|---|
| 972 | 952 | MODULE_AUTHOR("Baolin Wang <baolin.wang@spreadtrum.com>"); |
|---|