Lines Matching refs:where
56 static inline int vr41xx_pci_config_access(struct pci_dev *dev, int where)
65 if (PCI_SLOT(dev_fn) < 11 || PCI_SLOT(dev_fn) > 31 || where > 255)
70 (where & 0xfc),
77 if (bus > 255 || PCI_SLOT(dev_fn) > 31 || where > 255)
82 (where & 0xfc) |
90 static int vr41xx_pci_read_config_byte(struct pci_dev *dev, int where, u8 *val)
95 if (vr41xx_pci_config_access(dev, where) < 0)
99 *val = (u8)(data >> ((where & 3) << 3));
105 static int vr41xx_pci_read_config_word(struct pci_dev *dev, int where, u16 *val)
110 if (where & 1)
113 if (vr41xx_pci_config_access(dev, where) < 0)
117 *val = (u16)(data >> ((where & 2) << 3));
122 static int vr41xx_pci_read_config_dword(struct pci_dev *dev, int where, u32 *val)
125 if (where & 3)
128 if (vr41xx_pci_config_access(dev, where) < 0)
136 static int vr41xx_pci_write_config_byte(struct pci_dev *dev, int where, u8 val)
141 if (vr41xx_pci_config_access(dev, where) < 0)
145 shift = (where & 3) << 3;
154 static int vr41xx_pci_write_config_word(struct pci_dev *dev, int where, u16 val)
159 if (where & 1)
162 if (vr41xx_pci_config_access(dev, where) < 0)
166 shift = (where & 2) << 3;
174 static int vr41xx_pci_write_config_dword(struct pci_dev *dev, int where, u32 val)
176 if (where & 3)
179 if (vr41xx_pci_config_access(dev, where) < 0)