Skip to content

Commit

Permalink
Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/…
Browse files Browse the repository at this point in the history
…kernel/git/groeck/staging

* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging:
  hwmon/f71882fg: Set platform drvdata to NULL later
  hwmon/f71882fg: Fix a typo in a comment
  • Loading branch information
Linus Torvalds committed Mar 13, 2011
2 parents 0e5b88c + d9ebaa4 commit c9a816c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/hwmon/f71882fg.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#define SIO_F71858FG_LD_HWM 0x02 /* Hardware monitor logical device */
#define SIO_F71882FG_LD_HWM 0x04 /* Hardware monitor logical device */
#define SIO_UNLOCK_KEY 0x87 /* Key to enable Super-I/O */
#define SIO_LOCK_KEY 0xAA /* Key to diasble Super-I/O */
#define SIO_LOCK_KEY 0xAA /* Key to disable Super-I/O */

#define SIO_REG_LDSEL 0x07 /* Logical device select */
#define SIO_REG_DEVID 0x20 /* Device ID (2 bytes) */
Expand Down Expand Up @@ -2111,7 +2111,6 @@ static int f71882fg_remove(struct platform_device *pdev)
int nr_fans = (data->type == f71882fg) ? 4 : 3;
u8 start_reg = f71882fg_read8(data, F71882FG_REG_START);

platform_set_drvdata(pdev, NULL);
if (data->hwmon_dev)
hwmon_device_unregister(data->hwmon_dev);

Expand Down Expand Up @@ -2178,6 +2177,7 @@ static int f71882fg_remove(struct platform_device *pdev)
}
}

platform_set_drvdata(pdev, NULL);
kfree(data);

return 0;
Expand Down

0 comments on commit c9a816c

Please sign in to comment.