hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/drivers/misc/cardreader/rts5209.c
....@@ -1,19 +1,7 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /* Driver for Realtek PCI-Express card reader
23 *
34 * Copyright(c) 2009-2013 Realtek Semiconductor Corp. All rights reserved.
4
- *
5
- * This program is free software; you can redistribute it and/or modify it
6
- * under the terms of the GNU General Public License as published by the
7
- * Free Software Foundation; either version 2, or (at your option) any
8
- * later version.
9
- *
10
- * This program is distributed in the hope that it will be useful, but
11
- * WITHOUT ANY WARRANTY; without even the implied warranty of
12
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
- * General Public License for more details.
14
- *
15
- * You should have received a copy of the GNU General Public License along
16
- * with this program; if not, see <http://www.gnu.org/licenses/>.
175 *
186 * Author:
197 * Wei WANG <wei_wang@realsil.com.cn>
....@@ -35,9 +23,10 @@
3523
3624 static void rts5209_fetch_vendor_settings(struct rtsx_pcr *pcr)
3725 {
26
+ struct pci_dev *pdev = pcr->pci;
3827 u32 reg;
3928
40
- rtsx_pci_read_config_dword(pcr, PCR_SETTING_REG1, &reg);
29
+ pci_read_config_dword(pdev, PCR_SETTING_REG1, &reg);
4130 pcr_dbg(pcr, "Cfg 0x%x: 0x%x\n", PCR_SETTING_REG1, reg);
4231
4332 if (rts5209_vendor_setting1_valid(reg)) {
....@@ -46,7 +35,7 @@
4635 pcr->aspm_en = rts5209_reg_to_aspm(reg);
4736 }
4837
49
- rtsx_pci_read_config_dword(pcr, PCR_SETTING_REG2, &reg);
38
+ pci_read_config_dword(pdev, PCR_SETTING_REG2, &reg);
5039 pcr_dbg(pcr, "Cfg 0x%x: 0x%x\n", PCR_SETTING_REG2, reg);
5140
5241 if (rts5209_vendor_setting2_valid(reg)) {