Skip to content

Commit

Permalink
drivers/misc/bmp085.c: free initmem memory
Browse files Browse the repository at this point in the history
Free the memory that is used only at init

Signed-off-by: Shubhrajyoti Datta <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Shubhrajyoti Datta authored and torvalds committed Mar 23, 2011
1 parent 4a7de63 commit 45bff2e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/misc/bmp085.c
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ static int bmp085_init_client(struct i2c_client *client)
return status;
}

static int bmp085_probe(struct i2c_client *client,
static int __devinit bmp085_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
struct bmp085_data *data;
Expand Down Expand Up @@ -438,7 +438,7 @@ static int bmp085_probe(struct i2c_client *client,
return err;
}

static int bmp085_remove(struct i2c_client *client)
static int __devexit bmp085_remove(struct i2c_client *client)
{
sysfs_remove_group(&client->dev.kobj, &bmp085_attr_group);
kfree(i2c_get_clientdata(client));
Expand All @@ -458,7 +458,7 @@ static struct i2c_driver bmp085_driver = {
},
.id_table = bmp085_id,
.probe = bmp085_probe,
.remove = bmp085_remove,
.remove = __devexit_p(bmp085_remove),

.detect = bmp085_detect,
.address_list = normal_i2c
Expand Down

0 comments on commit 45bff2e

Please sign in to comment.