Re: Help: DGE-560T not recognized by Linux

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

 



On Mon, Feb 20, 2006 at 12:43:41PM +0100, Willy Tarreau wrote:
> Today, I had the *exact* same problem on one server equipped with the same
> card. I tried the patch above which did not change anything. However, I
> finally fixed it by simply enabling ACPI. Then it always works with and
> without the patch above. I could not test marvell's driver because it does
> not build on 2.6.16-rc4, but strangely my previous kernel on this machine
> was a 2.6.12-rc4-mm2 patched with marvell's driver and with ACPI disabled.
> 
> So it seems that marvell's driver on 2.6.12 was able to access config space
> even without ACPI while sky2 on 2.6.16-rc4 cannot. I have no idea why,
> unfortunately.

Apparently Marvell's driver accesses PCIE configuration registers through
I/O ports specific to their hardware:

/*
 *	Macro PCI_C()
 *
 *	Use this macro to access PCI config register from the I/O space.
 *
 * para:
 *	pAC		Pointer to adapter context
 *	Addr	PCI configuration register to access.
 *			Values:	PCI_VENDOR_ID ... PCI_VPD_ADR_REG,
 *
 * usage	SK_IN16(IoC, PCI_C(pAC, PCI_VENDOR_ID), pVal);
 */
#define PCI_C(p, Addr)		\
	(((CHIP_ID_YUKON_2(p)) ? Y2_CFG_SPC : B7_CFG_SPC) + (Addr))

...

			/* clear any PEX errors */
			SK_OUT32(IoC, PCI_C(pAC, PEX_UNC_ERR_STAT), 0xffffffffUL);

			SK_IN16(IoC, PCI_C(pAC, PEX_LNK_STAT), &Word);

			pAC->GIni.GIPexWidth = (SK_U8)((Word & PEX_LS_LINK_WI_MSK) >> 4);

...

			SK_OUT8(IoC, B2_TST_CTRL1, TST_CFG_WRITE_ON);

			SK_OUT16(IoC, PCI_C(pAC, PEX_DEV_CTRL), Word);

			SK_OUT8(IoC, B2_TST_CTRL1, TST_CFG_WRITE_OFF);

...

		/* clear the interrupt */
		SK_OUT32(IoC, B2_TST_CTRL1, TST_CFG_WRITE_ON);
		SK_OUT32(IoC, PCI_C(pAC, PEX_UNC_ERR_STAT), 0xffffffffUL);
		SK_OUT32(IoC, B2_TST_CTRL1, TST_CFG_WRITE_OFF);

But sky2 uses standard pci_read_config_*, pci_write_config_* functions,
which require working MMCONFIG access.  Maybe sky2 should be changed to
use I/O space for access to PCIE-specific configuration registers.

Attachment: pgpRhZiya2kN5.pgp
Description: PGP signature


[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux