Explorar el Código

[phantom] Fix P3 B1 silicon bug workaround

Commit f58cc3f introduced a temporary workaround for a bug in current
prototype silicon, but failed to apply it to all eight PCI functions
within the device.
tags/v0.9.4
Michael Brown hace 15 años
padre
commit
cb6fea0690
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3
    1
      src/drivers/net/phantom/phantom.c

+ 3
- 1
src/drivers/net/phantom/phantom.c Ver fichero

@@ -1861,12 +1861,14 @@ static int phantom_probe ( struct pci_device *pci,
1861 1861
 	 * B2 will have this fixed; remove this hack when B1 is no
1862 1862
 	 * longer in use.
1863 1863
 	 */
1864
-	{
1864
+	for ( i = 0 ; i < 8 ; i++ ) {
1865 1865
 		uint32_t temp;
1866
+		pci->devfn = PCI_DEVFN ( PCI_SLOT ( pci->devfn ), i );
1866 1867
 		pci_read_config_dword ( pci, 0xc8, &temp );
1867 1868
 		pci_read_config_dword ( pci, 0xc8, &temp );
1868 1869
 		pci_write_config_dword ( pci, 0xc8, 0xf1000 );
1869 1870
 	}
1871
+	pci->devfn = PCI_DEVFN ( PCI_SLOT ( pci->devfn ), 0 );
1870 1872
 
1871 1873
 	/* Allocate dummy DMA buffer and perform initial hardware handshake */
1872 1874
 	phantom->dma_buf = malloc_dma ( sizeof ( *(phantom->dma_buf) ),

Loading…
Cancelar
Guardar