aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Borkmann <danborkmann@iogearbox.net>2012-04-18 17:55:08 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-04-19 22:09:18 -0400
commit73eb94a094e54cb81c41c64e59eb5d6a05ecb045 (patch)
tree50424ae9af086c44b3d5b072b5875fdd1e1b2a29
parentb4161f0bb5f815ca6d8108062b8e3b650c18fe39 (diff)
xilinx_hwicap: add support for virtex6 FPGAs
This patch adds support for the virtex6 FPGA to the xilinx_hwicap driver. Tested on a Xilinx ML605 board. The patch is against the latest linus-tree. Signed-off-by: Ariane Keller <ariane.keller@tik.ee.ethz.ch> Signed-off-by: Daniel Borkmann <daniel.borkmann@tik.ee.ethz.ch> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/char/xilinx_hwicap/xilinx_hwicap.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/drivers/char/xilinx_hwicap/xilinx_hwicap.c b/drivers/char/xilinx_hwicap/xilinx_hwicap.c
index 31ba11ca75e1..2c5d15beea35 100644
--- a/drivers/char/xilinx_hwicap/xilinx_hwicap.c
+++ b/drivers/char/xilinx_hwicap/xilinx_hwicap.c
@@ -167,6 +167,7 @@ static const struct config_registers v4_config_registers = {
167 .BOOTSTS = UNIMPLEMENTED, 167 .BOOTSTS = UNIMPLEMENTED,
168 .CTL_1 = UNIMPLEMENTED, 168 .CTL_1 = UNIMPLEMENTED,
169}; 169};
170
170static const struct config_registers v5_config_registers = { 171static const struct config_registers v5_config_registers = {
171 .CRC = 0, 172 .CRC = 0,
172 .FAR = 1, 173 .FAR = 1,
@@ -192,6 +193,31 @@ static const struct config_registers v5_config_registers = {
192 .CTL_1 = 19, 193 .CTL_1 = 19,
193}; 194};
194 195
196static const struct config_registers v6_config_registers = {
197 .CRC = 0,
198 .FAR = 1,
199 .FDRI = 2,
200 .FDRO = 3,
201 .CMD = 4,
202 .CTL = 5,
203 .MASK = 6,
204 .STAT = 7,
205 .LOUT = 8,
206 .COR = 9,
207 .MFWR = 10,
208 .FLR = UNIMPLEMENTED,
209 .KEY = UNIMPLEMENTED,
210 .CBC = 11,
211 .IDCODE = 12,
212 .AXSS = 13,
213 .C0R_1 = 14,
214 .CSOB = 15,
215 .WBSTAR = 16,
216 .TIMER = 17,
217 .BOOTSTS = 22,
218 .CTL_1 = 24,
219};
220
195/** 221/**
196 * hwicap_command_desync - Send a DESYNC command to the ICAP port. 222 * hwicap_command_desync - Send a DESYNC command to the ICAP port.
197 * @drvdata: a pointer to the drvdata. 223 * @drvdata: a pointer to the drvdata.
@@ -744,6 +770,8 @@ static int __devinit hwicap_of_probe(struct platform_device *op,
744 regs = &v4_config_registers; 770 regs = &v4_config_registers;
745 } else if (!strcmp(family, "virtex5")) { 771 } else if (!strcmp(family, "virtex5")) {
746 regs = &v5_config_registers; 772 regs = &v5_config_registers;
773 } else if (!strcmp(family, "virtex6")) {
774 regs = &v6_config_registers;
747 } 775 }
748 } 776 }
749 return hwicap_setup(&op->dev, id ? *id : -1, &res, config, 777 return hwicap_setup(&op->dev, id ? *id : -1, &res, config,
@@ -785,6 +813,8 @@ static int __devinit hwicap_drv_probe(struct platform_device *pdev)
785 regs = &v4_config_registers; 813 regs = &v4_config_registers;
786 } else if (!strcmp(family, "virtex5")) { 814 } else if (!strcmp(family, "virtex5")) {
787 regs = &v5_config_registers; 815 regs = &v5_config_registers;
816 } else if (!strcmp(family, "virtex6")) {
817 regs = &v6_config_registers;
788 } 818 }
789 } 819 }
790 820