Lines Matching refs:gpch

32 	struct rdc321x_gpio *gpch;  in rdc_gpio_get_value()  local
36 gpch = gpiochip_get_data(chip); in rdc_gpio_get_value()
37 reg = gpio < 32 ? gpch->reg1_data_base : gpch->reg2_data_base; in rdc_gpio_get_value()
39 spin_lock(&gpch->lock); in rdc_gpio_get_value()
40 pci_write_config_dword(gpch->sb_pdev, reg, in rdc_gpio_get_value()
41 gpch->data_reg[gpio < 32 ? 0 : 1]); in rdc_gpio_get_value()
42 pci_read_config_dword(gpch->sb_pdev, reg, &value); in rdc_gpio_get_value()
43 spin_unlock(&gpch->lock); in rdc_gpio_get_value()
51 struct rdc321x_gpio *gpch; in rdc_gpio_set_value_impl() local
54 gpch = gpiochip_get_data(chip); in rdc_gpio_set_value_impl()
57 gpch->data_reg[reg] |= 1 << (gpio & 0x1f); in rdc_gpio_set_value_impl()
59 gpch->data_reg[reg] &= ~(1 << (gpio & 0x1f)); in rdc_gpio_set_value_impl()
61 pci_write_config_dword(gpch->sb_pdev, in rdc_gpio_set_value_impl()
62 reg ? gpch->reg2_data_base : gpch->reg1_data_base, in rdc_gpio_set_value_impl()
63 gpch->data_reg[reg]); in rdc_gpio_set_value_impl()
70 struct rdc321x_gpio *gpch; in rdc_gpio_set_value() local
72 gpch = gpiochip_get_data(chip); in rdc_gpio_set_value()
73 spin_lock(&gpch->lock); in rdc_gpio_set_value()
75 spin_unlock(&gpch->lock); in rdc_gpio_set_value()
81 struct rdc321x_gpio *gpch; in rdc_gpio_config() local
85 gpch = gpiochip_get_data(chip); in rdc_gpio_config()
87 spin_lock(&gpch->lock); in rdc_gpio_config()
88 err = pci_read_config_dword(gpch->sb_pdev, gpio < 32 ? in rdc_gpio_config()
89 gpch->reg1_ctrl_base : gpch->reg2_ctrl_base, &reg); in rdc_gpio_config()
95 err = pci_write_config_dword(gpch->sb_pdev, gpio < 32 ? in rdc_gpio_config()
96 gpch->reg1_ctrl_base : gpch->reg2_ctrl_base, reg); in rdc_gpio_config()
103 spin_unlock(&gpch->lock); in rdc_gpio_config()