[PATCH 03/11] staging: comedi: jr3_pci: Reset all DSPs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The various JR3 PCI models have from 1 to 4 DSPs, one per subdevice.
Prior to loading the firmware to all the DSPs, the initialization code
in `jr3_pci_auto_attach()` resets the first DSP.  As far as I can tell,
it should reset all of them.  Change it to do so.

Signed-off-by: Ian Abbott <abbotti@xxxxxxxxx>
---
 drivers/staging/comedi/drivers/jr3_pci.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/comedi/drivers/jr3_pci.c b/drivers/staging/comedi/drivers/jr3_pci.c
index eb0a095efe9c..c5bff9a85727 100644
--- a/drivers/staging/comedi/drivers/jr3_pci.c
+++ b/drivers/staging/comedi/drivers/jr3_pci.c
@@ -736,7 +736,8 @@ static int jr3_pci_auto_attach(struct comedi_device *dev,
 	}
 
 	/* Reset DSP card */
-	writel(0, &devpriv->iobase->channel[0].reset);
+	for (i = 0; i < dev->n_subdevices; i++)
+		writel(0, &devpriv->iobase->channel[i].reset);
 
 	ret = comedi_load_firmware(dev, &comedi_to_pci_dev(dev)->dev,
 				   "comedi/jr3pci.idm",
-- 
2.11.0

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux