- /* We can fill in the remaining client fields */
- strlcpy(new_client->name, names[kind - 1], I2C_NAME_SIZE);
+ strlcpy(info->type, names[kind - 1], I2C_NAME_SIZE);
+
+ return 0;
+}
+
+static int lm87_probe(struct i2c_client *new_client,
+ const struct i2c_device_id *id)
+{
+ struct lm87_data *data;
+ int err;
+
+ data = kzalloc(sizeof(struct lm87_data), GFP_KERNEL);
+ if (!data) {
+ err = -ENOMEM;
+ goto exit;
+ }
+
+ i2c_set_clientdata(new_client, data);