Am Dienstag, den 25.01.2011, 10:44 +0000 schrieb Joseph Kellermann:
Also I've found an issue: The default 'pci_set_subsystem' sets the subvendor/device id register# 0x2c. However, for a few devices in the RS690 the register is 0x4c respectively 0x50.
Moved 'pci_set_subsystem' to a weak function in 'pci_device.c'. So boards can add an override for the default function in mainboard/../override_df.c (or mainboard.c) and set it up too.
Given that these implement chipset specific behaviour (either the device requires writing to 0x4c instead of 0x2c or it doesn't), and that pci_dev_set_subsystem is always called indirectly (via function pointers in the respective chipset drivers), couldn't you just modify the chipset drivers to point to a different set_subsystem implementation where necessary?
It seems like the GFX function of RS690 is affected (just skimmed through the AMD docs, so others might also require such a change). In this case, it should work to change src/southbridge/amd/rs690/gfx.c to point lops.set_subsystem to your own implementation which does whatever their GFX device needs (write to 0x4c in extended config space in that case, if I understand the docs), no?
Hoping to receive a 'ack'. Signed-off-by: Josef Kellermann joseph.kellermann@heitec.de
If this change is actually required, I'll ack and commit it, but I'd like to understand your use case better first. We already have a layer of indirection in place, introducing another one will only create confusion down the road.
Regards, Patrick