Lines Matching refs:mc9s

33 	struct mc9s08dz60 *mc9s = gpiochip_get_data(gc);  in mc9s08dz60_get_value()  local
36 value = i2c_smbus_read_byte_data(mc9s->client, reg); in mc9s08dz60_get_value()
41 static int mc9s08dz60_set(struct mc9s08dz60 *mc9s, unsigned offset, int val) in mc9s08dz60_set() argument
47 value = i2c_smbus_read_byte_data(mc9s->client, reg); in mc9s08dz60_set()
54 return i2c_smbus_write_byte_data(mc9s->client, reg, value); in mc9s08dz60_set()
63 struct mc9s08dz60 *mc9s = gpiochip_get_data(gc); in mc9s08dz60_set_value() local
65 mc9s08dz60_set(mc9s, offset, val); in mc9s08dz60_set_value()
71 struct mc9s08dz60 *mc9s = gpiochip_get_data(gc); in mc9s08dz60_direction_output() local
73 return mc9s08dz60_set(mc9s, offset, val); in mc9s08dz60_direction_output()
79 struct mc9s08dz60 *mc9s; in mc9s08dz60_probe() local
81 mc9s = devm_kzalloc(&client->dev, sizeof(*mc9s), GFP_KERNEL); in mc9s08dz60_probe()
82 if (!mc9s) in mc9s08dz60_probe()
85 mc9s->chip.label = client->name; in mc9s08dz60_probe()
86 mc9s->chip.base = -1; in mc9s08dz60_probe()
87 mc9s->chip.parent = &client->dev; in mc9s08dz60_probe()
88 mc9s->chip.owner = THIS_MODULE; in mc9s08dz60_probe()
89 mc9s->chip.ngpio = GPIO_NUM; in mc9s08dz60_probe()
90 mc9s->chip.can_sleep = true; in mc9s08dz60_probe()
91 mc9s->chip.get = mc9s08dz60_get_value; in mc9s08dz60_probe()
92 mc9s->chip.set = mc9s08dz60_set_value; in mc9s08dz60_probe()
93 mc9s->chip.direction_output = mc9s08dz60_direction_output; in mc9s08dz60_probe()
94 mc9s->client = client; in mc9s08dz60_probe()
95 i2c_set_clientdata(client, mc9s); in mc9s08dz60_probe()
97 return devm_gpiochip_add_data(&client->dev, &mc9s->chip, mc9s); in mc9s08dz60_probe()