Hidetoshi Seto wrote:
(2010/04/09 9:23), Kenji Kaneshige wrote:
How about changing ROOT_ERR_STATUS_MASK as follows instead of removing it.
#define ROOT_ERR_STATUS_MASK (PCI_ERR_ROOT_UNCOR_RCV | \
PCI_ERR_ROOT_MULTI_UNCOR_RCV | \
PCI_ERR_ROOT_COR_RCV | \
PCI_ERR_ROOT_MULTI_COR_RCV)
I did this change at first.
However this mask is used only once, and I thought it
would be painful for readers to force searching this macro
from kernel tree and to force having unmemorable information
"this is combination of 4 bits" that will never used again.
So I removed this alias and use bits directly.
I don't know which is preferred, changing or removing.
But IMHO renaming fuzzy ROOT_ERR_STATUS_MASK to something
like PCI_ERR_ROOT_ERR_RCV_MASK is also good if changing is
preferred.
How do you think?
I mis-understood that those four bits were all the status bits in the Root
Error Status Register defined in PCIe spec. So I thought it was natural to
have PCI_ERR_STATUS_MASK and use it to check all the status bits. This was
the reason of my suggestion.
But now I noticed that it is not a set of all the status bits, but a set
of bits to which aer interrupt hander is interested. It would be hard for
people to understand what PCI_ERR_ROOT_STATUS_MASK stands for. As a result,
I think your change is good.
By the way, do we need to check PCI_ERR_ROOT_MULTI_UNCOR_RCV and
PCI_ERR_ROOT_MULTI_COR_RCV here?
Thanks,
Kenji Kaneshige
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html