lkml.org 
[lkml]   [2005]   [Oct]   [2]   [last100]   RSS Feed
Views: [more markup]   [less markup]   [headers]   [forward]  
 
Messages in this thread
/
SubjectRe: Opterons and setting the pci bus master bit
FromBenjamin Herrenschmidt <>
DateSun, 02 Oct 2005 18:54:54 +1000
On Fri, 2005-09-30 at 13:32 -0400, linux-os (Dick Johnson) wrote:
>     pci_set_dma_mask(dev, 0xffffffffULL);    // 32 bit DMA only
>     pci_set_drvdata(dev, NULL);              // Harmless if unused
>     pci_set_power_state(dev, 0);             // Turn it ON
>     pci_set_master(dev);                     // Make bus-master
>     pci_set_mwi(dev);   // Check return, different code
>     pci_write_config_dword(dev, PCI_COMMAND, PCI_CONFIG_YOU_DEFINE);
> 
>    Typical bus-master PCI_CONFIG_YOU_DEFINE is:
>      (PCI_COMMAND_MEMORY|PCI_COMMAND_MASTER|PCI_COMMAND_SERR)

Actually the last one is slightly bogus for things like
memory/master/etc... you shouldn't bother about these if you do things
correctly and call ... pci_enable_device() which you forgot :)

Ben.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-10-02 07:00    [W:0.277 / U:0.590 seconds]
©2003-2008 Jasper Spaans