Skip to contentSkip to conversation

ACPI + 3c556 - the saga continues

DISCUSSION Yaroslav Rastrigin 2 participants 2 messages Jul 16, 2003 1 message not in the archive ACPI

lore
Share & tools
lore
#0 lore raw

Hi everyone.

Well, encouraged by utter silence on my questions (some of them were lame, I have to admit :-), I've continued my investigations.
Turns out, DSTD in my laptop (IBM ThinkPad T21) is somewhat screwed. I've hand-applied custom-DSDT patch
(I'm running 2.6.0-test1-ac1 + 20030714 ACPI rev.), and started playing with DSDT. To make long story short - my network card now kinda works with ACPI. What do I mean:
When I'm booting with ACPI enabled, lspci -vv shows correct values (Regions, IRQ and other info) for the NIC , but after loading NIC driver fails to read device configuration (loads garbage, 0xFF in every byte read from card's conf), and network doesnt work.
rmmod 3c59x, then I'm feeding
setpci -s 00:03.00 BASE_ADDRESS_0=0x1801
(PCI data was taken from good working APM boot),
modprobe 3c59x
and magically NIC is OK.
It turns out offending _INI code is:
/*
If (And (PAM1, 0x03))

{
	Store (0x00, C0LN)
}
If (And (PAM1, 0x30))
{
	Store (0x00, C4LN)
}
If (And (PAM2, 0x03))
{
	Store (0x00, C8LN)
}

*/
Where C?LN are defined as
CreateDWordField (_CRS, 0x68, C0LN)
CreateDWordField (_CRS, 0x82, C4LN)
CreateDWordField (_CRS, 0x9C, C8LN)

inside Device (PCI0)
and PAM?s are:
OperationRegion (X000, PCI_Config, 0x00, 0x0100)
Field (X000, DWordAcc, NoLock, Preserve)

{
                Offset (0x59),
                PAM0,   8,
                PAM1,   8,
                PAM2,   8,
		.....
}

(My DSDT can be found at
http://www.relex.ru/~yarick/acpi/DSDT.dsl
)

I'm not a PCI programming guru (yet ?), so new questions are:
what's going on here ? Where or how could I find which PCI registers are overwritten by aforementioned three Store's ? I think I could write custom _INI for my NIC, but could someone help me to start ?

And another question:
What conditions should be met for ACPI event to appear in /proc/acpi/event ? When I'm manually triggering LID microswitch ,f.e, I'm seeing lot's of ACPI activity in logs (with upped debug level), and I could see _LID method executed, but nothing appears in /proc/acpi/event, and I can't make acpid to suspend machine when LID is closed.
Moreover, there are no events in /proc/acpi/event at all, alhough ACPI subsystem notices and handles them. Did I screwed something in my setup , and if yes, then what to look for ?

With all the best, yarick at relex dot ru

-------------------------------------------------------
This SF.net email is sponsored by: VM Ware
With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here: http://www.vmware.com/wl/offer/345/0

A message that is not in the archive (sent off-list or not yet received): [email protected]

#2 lore raw

hello yaroslav..

Quoted 11 lines · Yaroslav Rastrigin

What conditions should be met for ACPI event to appear in /proc/acpi/event ?
When I'm manually triggering LID microswitch ,f.e, I'm seeing lot's of ACPI
activity in logs (with upped debug level), and I could see _LID method executed, but nothing appears in /proc/acpi/event, and I can't make acpid to suspend machine when LID is closed.
Moreover, there are no events in /proc/acpi/event at all, alhough ACPI subsystem notices and handles them. Did I screwed something in my setup , and
if yes, then what to look for ?

do you know of acpid? check
http://acpid.sourceforge.net
this daemon usually logs output from /proc/acpi/event to /var/log/acpid (among other things).

and how did you try to access p/a/event? a "tail -f" does not work, but "cat" does.

hth,
sebastian

Signature · 3 lines
::: sebastian henschel
::: kodeaffe
::: lynx -source http://www.kodeaffe.de/shensche.pub | gpg --import