Lines Matching refs:xra

52 	struct xra1403 *xra = gpiochip_get_data(chip);  in xra1403_direction_input()  local
54 return regmap_update_bits(xra->regmap, to_reg(XRA_GCR, offset), in xra1403_direction_input()
62 struct xra1403 *xra = gpiochip_get_data(chip); in xra1403_direction_output() local
64 ret = regmap_update_bits(xra->regmap, to_reg(XRA_GCR, offset), in xra1403_direction_output()
69 ret = regmap_update_bits(xra->regmap, to_reg(XRA_OCR, offset), in xra1403_direction_output()
79 struct xra1403 *xra = gpiochip_get_data(chip); in xra1403_get_direction() local
81 ret = regmap_read(xra->regmap, to_reg(XRA_GCR, offset), &val); in xra1403_get_direction()
95 struct xra1403 *xra = gpiochip_get_data(chip); in xra1403_get() local
97 ret = regmap_read(xra->regmap, to_reg(XRA_GSR, offset), &val); in xra1403_get()
107 struct xra1403 *xra = gpiochip_get_data(chip); in xra1403_set() local
109 ret = regmap_update_bits(xra->regmap, to_reg(XRA_OCR, offset), in xra1403_set()
120 struct xra1403 *xra = gpiochip_get_data(chip); in xra1403_dbg_show() local
132 regmap_read(xra->regmap, reg, &value[reg]); in xra1403_dbg_show()
152 struct xra1403 *xra; in xra1403_probe() local
156 xra = devm_kzalloc(&spi->dev, sizeof(*xra), GFP_KERNEL); in xra1403_probe()
157 if (!xra) in xra1403_probe()
165 xra->chip.direction_input = xra1403_direction_input; in xra1403_probe()
166 xra->chip.direction_output = xra1403_direction_output; in xra1403_probe()
167 xra->chip.get_direction = xra1403_get_direction; in xra1403_probe()
168 xra->chip.get = xra1403_get; in xra1403_probe()
169 xra->chip.set = xra1403_set; in xra1403_probe()
171 xra->chip.dbg_show = xra1403_dbg_show; in xra1403_probe()
173 xra->chip.ngpio = 16; in xra1403_probe()
174 xra->chip.label = "xra1403"; in xra1403_probe()
176 xra->chip.base = -1; in xra1403_probe()
177 xra->chip.can_sleep = true; in xra1403_probe()
178 xra->chip.parent = &spi->dev; in xra1403_probe()
179 xra->chip.owner = THIS_MODULE; in xra1403_probe()
181 xra->regmap = devm_regmap_init_spi(spi, &xra1403_regmap_cfg); in xra1403_probe()
182 if (IS_ERR(xra->regmap)) { in xra1403_probe()
183 ret = PTR_ERR(xra->regmap); in xra1403_probe()
188 return devm_gpiochip_add_data(&spi->dev, &xra->chip, xra); in xra1403_probe()