projects
/
wrapfs-2.6.35.y.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
08b751d
)
staging: r8192e_pci: Handle duplicate PCI ID 0x10ec:0x8192
author
Larry Finger
<Larry.Finger@lwfinger.net>
Sun, 19 Jun 2011 03:34:34 +0000
(22:34 -0500)
committer
Andi Kleen
<ak@linux.intel.com>
Mon, 1 Aug 2011 20:55:03 +0000
(13:55 -0700)
[ upstream commit
1c50bf7e415cf6ce9545dbecc2ac0d89d3916c53
]
conflict with rtl8192se
There are two devices with PCI ID 0x10ec:0x8192, namely RTL8192E and
RTL8192SE. The method of distinguishing them is by the revision ID
at offset 0x8 of the PCI configuration space. If the value is 0x10,
then the device uses rtl8192se for a driver.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
drivers/staging/rtl8192e/r8192E_core.c
patch
|
blob
|
history
diff --git
a/drivers/staging/rtl8192e/r8192E_core.c
b/drivers/staging/rtl8192e/r8192E_core.c
index eb41402d1d3716179e3761f5219da671b44750ee..ed028d677c7b7891a6dd4a1482ff06558b0f7eb3 100644
(file)
--- a/
drivers/staging/rtl8192e/r8192E_core.c
+++ b/
drivers/staging/rtl8192e/r8192E_core.c
@@
-6334,6
+6334,7
@@
static int __devinit rtl8192_pci_probe(struct pci_dev *pdev,
struct net_device *dev = NULL;
struct r8192_priv *priv= NULL;
u8 unit = 0;
+ u8 revisionid;
#ifdef CONFIG_RTL8192_IO_MAP
unsigned long pio_start, pio_len, pio_flags;
@@
-6423,6
+6424,11
@@
static int __devinit rtl8192_pci_probe(struct pci_dev *pdev,
pci_write_config_byte(pdev, 0x41, 0x00);
+ pci_read_config_byte(pdev, 0x08, &revisionid);
+ /* If the revisionid is 0x10, the device uses rtl8192se. */
+ if (pdev->device == 0x8192 && revisionid == 0x10)
+ goto fail1;
+
pci_read_config_byte(pdev, 0x05, &unit);
pci_write_config_byte(pdev, 0x05, unit & (~0x04));