diff options
author | Muhammad Ghias <mghias@connecttech.com> | 2012-10-16 17:03:35 -0400 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2012-11-15 11:25:54 -0500 |
commit | e4bc6c06569a90512169d98a11b3eb2ec18da4ae (patch) | |
tree | 7ddb8472d888133cb8ab5d7067774da869259189 /drivers/net/can | |
parent | 702ed3c1a9dfe4dfe112f13542d0c9d689f5008b (diff) |
can: sja1000: plx_pci: add support for Connect Tech Inc's Canpro/104-Plus Opto CAN board
Patch adds support for CANpro/104-Plus Opto CAN board. Board uses PLX9030
bridge and two NXP SJA1000 CAN controllers. Patch is generated and tested with
kernel 3.6.1.
Signed-off-by: Muhammad Ghias <mghias@connecttech.com>
Acked-by: Wolfgang Grandegger <wg@grandegger.com>
[mkl: minor adjustments to commit message]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/net/can')
-rw-r--r-- | drivers/net/can/sja1000/Kconfig | 1 | ||||
-rw-r--r-- | drivers/net/can/sja1000/plx_pci.c | 19 |
2 files changed, 20 insertions, 0 deletions
diff --git a/drivers/net/can/sja1000/Kconfig b/drivers/net/can/sja1000/Kconfig index 03df9a8f2bbf..559be87a0904 100644 --- a/drivers/net/can/sja1000/Kconfig +++ b/drivers/net/can/sja1000/Kconfig | |||
@@ -93,6 +93,7 @@ config CAN_PLX_PCI | |||
93 | - Marathon CAN-bus-PCI card (http://www.marathon.ru/) | 93 | - Marathon CAN-bus-PCI card (http://www.marathon.ru/) |
94 | - TEWS TECHNOLOGIES TPMC810 card (http://www.tews.com/) | 94 | - TEWS TECHNOLOGIES TPMC810 card (http://www.tews.com/) |
95 | - IXXAT Automation PC-I 04/PCI card (http://www.ixxat.com/) | 95 | - IXXAT Automation PC-I 04/PCI card (http://www.ixxat.com/) |
96 | - Connect Tech Inc. CANpro/104-Plus Opto (CRG001) card (http://www.connecttech.com) | ||
96 | 97 | ||
97 | config CAN_TSCAN1 | 98 | config CAN_TSCAN1 |
98 | tristate "TS-CAN1 PC104 boards" | 99 | tristate "TS-CAN1 PC104 boards" |
diff --git a/drivers/net/can/sja1000/plx_pci.c b/drivers/net/can/sja1000/plx_pci.c index 8bc95982840f..dc04407aa217 100644 --- a/drivers/net/can/sja1000/plx_pci.c +++ b/drivers/net/can/sja1000/plx_pci.c | |||
@@ -44,6 +44,7 @@ MODULE_SUPPORTED_DEVICE("Adlink PCI-7841/cPCI-7841, " | |||
44 | "esd CAN-PCI/CPCI/PCI104/200, " | 44 | "esd CAN-PCI/CPCI/PCI104/200, " |
45 | "esd CAN-PCI/PMC/266, " | 45 | "esd CAN-PCI/PMC/266, " |
46 | "esd CAN-PCIe/2000, " | 46 | "esd CAN-PCIe/2000, " |
47 | "Connect Tech Inc. CANpro/104-Plus Opto (CRG001), " | ||
47 | "IXXAT PC-I 04/PCI") | 48 | "IXXAT PC-I 04/PCI") |
48 | MODULE_LICENSE("GPL v2"); | 49 | MODULE_LICENSE("GPL v2"); |
49 | 50 | ||
@@ -131,6 +132,9 @@ struct plx_pci_card { | |||
131 | #define TEWS_PCI_VENDOR_ID 0x1498 | 132 | #define TEWS_PCI_VENDOR_ID 0x1498 |
132 | #define TEWS_PCI_DEVICE_ID_TMPC810 0x032A | 133 | #define TEWS_PCI_DEVICE_ID_TMPC810 0x032A |
133 | 134 | ||
135 | #define CTI_PCI_VENDOR_ID 0x12c4 | ||
136 | #define CTI_PCI_DEVICE_ID_CRG001 0x0900 | ||
137 | |||
134 | static void plx_pci_reset_common(struct pci_dev *pdev); | 138 | static void plx_pci_reset_common(struct pci_dev *pdev); |
135 | static void plx_pci_reset_marathon(struct pci_dev *pdev); | 139 | static void plx_pci_reset_marathon(struct pci_dev *pdev); |
136 | static void plx9056_pci_reset_common(struct pci_dev *pdev); | 140 | static void plx9056_pci_reset_common(struct pci_dev *pdev); |
@@ -222,6 +226,14 @@ static struct plx_pci_card_info plx_pci_card_info_tews __devinitdata = { | |||
222 | /* based on PLX9030 */ | 226 | /* based on PLX9030 */ |
223 | }; | 227 | }; |
224 | 228 | ||
229 | static struct plx_pci_card_info plx_pci_card_info_cti __devinitdata = { | ||
230 | "Connect Tech Inc. CANpro/104-Plus Opto (CRG001)", 2, | ||
231 | PLX_PCI_CAN_CLOCK, PLX_PCI_OCR, PLX_PCI_CDR, | ||
232 | {0, 0x00, 0x00}, { {2, 0x000, 0x80}, {2, 0x100, 0x80} }, | ||
233 | &plx_pci_reset_common | ||
234 | /* based on PLX9030 */ | ||
235 | }; | ||
236 | |||
225 | static DEFINE_PCI_DEVICE_TABLE(plx_pci_tbl) = { | 237 | static DEFINE_PCI_DEVICE_TABLE(plx_pci_tbl) = { |
226 | { | 238 | { |
227 | /* Adlink PCI-7841/cPCI-7841 */ | 239 | /* Adlink PCI-7841/cPCI-7841 */ |
@@ -300,6 +312,13 @@ static DEFINE_PCI_DEVICE_TABLE(plx_pci_tbl) = { | |||
300 | 0, 0, | 312 | 0, 0, |
301 | (kernel_ulong_t)&plx_pci_card_info_tews | 313 | (kernel_ulong_t)&plx_pci_card_info_tews |
302 | }, | 314 | }, |
315 | { | ||
316 | /* Connect Tech Inc. CANpro/104-Plus Opto (CRG001) card */ | ||
317 | PCI_VENDOR_ID_PLX, PCI_DEVICE_ID_PLX_9030, | ||
318 | CTI_PCI_VENDOR_ID, CTI_PCI_DEVICE_ID_CRG001, | ||
319 | 0, 0, | ||
320 | (kernel_ulong_t)&plx_pci_card_info_cti | ||
321 | }, | ||
303 | { 0,} | 322 | { 0,} |
304 | }; | 323 | }; |
305 | MODULE_DEVICE_TABLE(pci, plx_pci_tbl); | 324 | MODULE_DEVICE_TABLE(pci, plx_pci_tbl); |