gl518sm.c (5071860aba7fc69279ab822638ed2c2e4549f9fd) gl518sm.c (7bef559455fc71f66f8573cc1aafe1dd33966c1c)
1/*
2 * gl518sm.c - Part of lm_sensors, Linux kernel modules for hardware
3 * monitoring
4 * Copyright (C) 1998, 1999 Frodo Looijaard <frodol@dds.nl> and
5 * Kyosti Malkki <kmalkki@cc.hut.fi>
6 * Copyright (C) 2004 Hong-Gunn Chew <hglinux@gunnet.org> and
7 * Jean Delvare <khali@linux-fr.org>
8 *

--- 478 unchanged lines hidden (view full) ---

487
488static int gl518_detach_client(struct i2c_client *client)
489{
490 struct gl518_data *data = i2c_get_clientdata(client);
491 int err;
492
493 hwmon_device_unregister(data->class_dev);
494
1/*
2 * gl518sm.c - Part of lm_sensors, Linux kernel modules for hardware
3 * monitoring
4 * Copyright (C) 1998, 1999 Frodo Looijaard <frodol@dds.nl> and
5 * Kyosti Malkki <kmalkki@cc.hut.fi>
6 * Copyright (C) 2004 Hong-Gunn Chew <hglinux@gunnet.org> and
7 * Jean Delvare <khali@linux-fr.org>
8 *

--- 478 unchanged lines hidden (view full) ---

487
488static int gl518_detach_client(struct i2c_client *client)
489{
490 struct gl518_data *data = i2c_get_clientdata(client);
491 int err;
492
493 hwmon_device_unregister(data->class_dev);
494
495 if ((err = i2c_detach_client(client))) {
496 dev_err(&client->dev, "Client deregistration failed, "
497 "client not detached.\n");
495 if ((err = i2c_detach_client(client)))
498 return err;
496 return err;
499 }
500
501 kfree(data);
502 return 0;
503}
504
505/* Registers 0x07 to 0x0c are word-sized, others are byte-sized
506 GL518 uses a high-byte first convention, which is exactly opposite to
507 the usual practice. */

--- 109 unchanged lines hidden ---
497
498 kfree(data);
499 return 0;
500}
501
502/* Registers 0x07 to 0x0c are word-sized, others are byte-sized
503 GL518 uses a high-byte first convention, which is exactly opposite to
504 the usual practice. */

--- 109 unchanged lines hidden ---