History

edac: fix local pci_write_bits32

Fix the edac local pci_write_bits32 to properly note the 'escape' mask if all ones in a 32-bit word. Currently no consumer of this function uses that mask, so there is no danger to existing code.

Jeff Haran committed 17 years ago

Commit e6da46b1 parent a7665b01 file · +10 −2Browse files

Unified · Split

drivers/edac/edac_core.h+10−2
@@ -767,11 +767,19 @@ static inline void pci_write_bits16(struct pci_dev *pdev, int offset, · 766 unmodified lines
767767 pci_write_config_word(pdev, offset, value);
768768 }
769769
770−/* write all or some bits in a dword-register*/
770+/*
771+ * pci_write_bits32
772+ *
773+ * edac local routine to do pci_write_config_dword, but adds
774+ * a mask parameter. If mask is all ones, ignore the mask.
775+ * Otherwise utilize the mask to isolate specified bits
776+ *
777+ * write all or some bits in a dword-register
778+ */
771779 static inline void pci_write_bits32(struct pci_dev *pdev, int offset,
772780 u32 value, u32 mask)
773781 {
774− if (mask != 0xffff) {
782+ if (mask != 0xffffffff) {
775783 u32 buf;
776784
777785 pci_read_config_dword(pdev, offset, &buf);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t