ipmi_ssif: Remove usecount handling
authorCorey Minyard <cminyard@mvista.com>
Fri, 6 Apr 2018 03:09:36 +0000 (22:09 -0500)
committerCorey Minyard <cminyard@mvista.com>
Wed, 18 Apr 2018 15:23:02 +0000 (10:23 -0500)
Now that we can handle hot remove there is no need for usecounts
for interfaces.

Signed-off-by: Corey Minyard <cminyard@mvista.com>
drivers/char/ipmi/ipmi_ssif.c

index 0f3dd94..8c72f27 100644 (file)
@@ -1094,25 +1094,6 @@ static void request_events(void *send_info)
        }
 }
 
-static int inc_usecount(void *send_info)
-{
-       struct ssif_info *ssif_info = send_info;
-
-       if (!i2c_get_adapter(i2c_adapter_id(ssif_info->client->adapter)))
-               return -ENODEV;
-
-       i2c_use_client(ssif_info->client);
-       return 0;
-}
-
-static void dec_usecount(void *send_info)
-{
-       struct ssif_info *ssif_info = send_info;
-
-       i2c_release_client(ssif_info->client);
-       i2c_put_adapter(ssif_info->client->adapter);
-}
-
 static int ssif_start_processing(void            *send_info,
                                 struct ipmi_smi *intf)
 {
@@ -1707,8 +1688,6 @@ static int ssif_probe(struct i2c_client *client, const struct i2c_device_id *id)
        ssif_info->handlers.get_smi_info = get_smi_info;
        ssif_info->handlers.sender = sender;
        ssif_info->handlers.request_events = request_events;
-       ssif_info->handlers.inc_usecount = inc_usecount;
-       ssif_info->handlers.dec_usecount = dec_usecount;
 
        {
                unsigned int thread_num;