diff options
Diffstat (limited to 'drivers/mtd/maps/pismo.c')
| -rw-r--r-- | drivers/mtd/maps/pismo.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/drivers/mtd/maps/pismo.c b/drivers/mtd/maps/pismo.c index c065d7995c0a..ecf68922da73 100644 --- a/drivers/mtd/maps/pismo.c +++ b/drivers/mtd/maps/pismo.c @@ -1,11 +1,8 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * PISMO memory driver - http://www.pismoworld.org/ * * For ARM Realview and Versatile platforms - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License. */ #include <linux/init.h> #include <linux/module.h> @@ -198,7 +195,7 @@ static void pismo_add_one(struct pismo_data *pismo, int i, } } -static int pismo_remove(struct i2c_client *client) +static void pismo_remove(struct i2c_client *client) { struct pismo_data *pismo = i2c_get_clientdata(client); int i; @@ -207,20 +204,16 @@ static int pismo_remove(struct i2c_client *client) platform_device_unregister(pismo->dev[i]); kfree(pismo); - - return 0; } -static int pismo_probe(struct i2c_client *client, - const struct i2c_device_id *id) +static int pismo_probe(struct i2c_client *client) { - struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent); struct pismo_pdata *pdata = client->dev.platform_data; struct pismo_eeprom eeprom; struct pismo_data *pismo; int ret, i; - if (!i2c_check_functionality(adapter, I2C_FUNC_I2C)) { + if (!i2c_check_functionality(client->adapter, I2C_FUNC_I2C)) { dev_err(&client->dev, "functionality mismatch\n"); return -EIO; } |
