aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/atm
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/atm')
-rw-r--r--drivers/atm/solos-pci.c29
1 files changed, 16 insertions, 13 deletions
diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c
index d7ad19d2603a..51eed679a059 100644
--- a/drivers/atm/solos-pci.c
+++ b/drivers/atm/solos-pci.c
@@ -531,34 +531,37 @@ static int flash_upgrade(struct solos_card *card, int chip)
531 int numblocks = 0; 531 int numblocks = 0;
532 int offset; 532 int offset;
533 533
534 if (chip == 0) { 534 switch (chip) {
535 case 0:
535 fw_name = "solos-FPGA.bin"; 536 fw_name = "solos-FPGA.bin";
536 blocksize = FPGA_BLOCK; 537 blocksize = FPGA_BLOCK;
537 } 538 break;
538 539 case 1:
539 if (chip == 1) {
540 fw_name = "solos-Firmware.bin"; 540 fw_name = "solos-Firmware.bin";
541 blocksize = SOLOS_BLOCK; 541 blocksize = SOLOS_BLOCK;
542 } 542 break;
543 543 case 2:
544 if (chip == 2){
545 if (card->fpga_version > LEGACY_BUFFERS){ 544 if (card->fpga_version > LEGACY_BUFFERS){
546 fw_name = "solos-db-FPGA.bin"; 545 fw_name = "solos-db-FPGA.bin";
547 blocksize = FPGA_BLOCK; 546 blocksize = FPGA_BLOCK;
548 } else { 547 } else {
549 dev_info(&card->dev->dev, "FPGA version doesn't support daughter board upgrades\n"); 548 dev_info(&card->dev->dev, "FPGA version doesn't support"
549 " daughter board upgrades\n");
550 return -EPERM; 550 return -EPERM;
551 } 551 }
552 } 552 break;
553 553 case 3:
554 if (chip == 3){
555 if (card->fpga_version > LEGACY_BUFFERS){ 554 if (card->fpga_version > LEGACY_BUFFERS){
556 fw_name = "solos-Firmware.bin"; 555 fw_name = "solos-Firmware.bin";
557 blocksize = SOLOS_BLOCK; 556 blocksize = SOLOS_BLOCK;
558 } else { 557 } else {
559 dev_info(&card->dev->dev, "FPGA version doesn't support daughter board upgrades\n"); 558 dev_info(&card->dev->dev, "FPGA version doesn't support"
560 return -EPERM; 559 " daughter board upgrades\n");
560 return -EPERM;
561 } 561 }
562 break;
563 default:
564 return -ENODEV;
562 } 565 }
563 566
564 if (request_firmware(&fw, fw_name, &card->dev->dev)) 567 if (request_firmware(&fw, fw_name, &card->dev->dev))