match: make kdbus_match_db_remove() void
authorDaniel Mack <daniel@zonque.org>
Thu, 11 Sep 2014 15:34:52 +0000 (17:34 +0200)
committerDaniel Mack <daniel@zonque.org>
Thu, 11 Sep 2014 15:41:38 +0000 (17:41 +0200)
handle.c
match.c
match.h

index 7376c561a4afde20c40892d0c0c7b73fbd1ba806..639f476595408d77ff440d142c58119db8e4a359 100644 (file)
--- a/handle.c
+++ b/handle.c
@@ -621,7 +621,7 @@ static long kdbus_handle_ioctl_ep_connected(struct file *file, unsigned int cmd,
                if (ret < 0)
                        break;
 
-               ret = kdbus_match_db_remove(conn, p);
+               kdbus_match_db_remove(conn, p);
                break;
 
        case KDBUS_CMD_MSG_SEND: {
diff --git a/match.c b/match.c
index 48b86ca1ceb0a65d44b31357a0041dd7aefa05d8..6582b2ded076716dadf1103a1a32073046008759 100644 (file)
--- a/match.c
+++ b/match.c
@@ -491,8 +491,8 @@ exit_free:
  *
  * Return: 0 on success, negative errno on failure.
  */
-int kdbus_match_db_remove(struct kdbus_conn *conn,
-                         struct kdbus_cmd_match *cmd)
+void kdbus_match_db_remove(struct kdbus_conn *conn,
+                          struct kdbus_cmd_match *cmd)
 {
        struct kdbus_match_entry *entry, *tmp;
        struct kdbus_match_db *db = conn->match_db;
@@ -502,6 +502,4 @@ int kdbus_match_db_remove(struct kdbus_conn *conn,
                if (entry->cookie == cmd->cookie)
                        kdbus_match_entry_free(entry);
        mutex_unlock(&db->entries_lock);
-
-       return 0;
 }
diff --git a/match.h b/match.h
index 1dde3791f4fba48e10fc92cd1c1845c0d333ddcd..674db5bab4b0bde40426c0eb56ea34f379e9672e 100644 (file)
--- a/match.h
+++ b/match.h
@@ -21,8 +21,8 @@ int kdbus_match_db_new(struct kdbus_match_db **db);
 void kdbus_match_db_free(struct kdbus_match_db *db);
 int kdbus_match_db_add(struct kdbus_conn *conn,
                       struct kdbus_cmd_match *cmd);
-int kdbus_match_db_remove(struct kdbus_conn *conn,
-                         struct kdbus_cmd_match *cmd);
+void kdbus_match_db_remove(struct kdbus_conn *conn,
+                          struct kdbus_cmd_match *cmd);
 bool kdbus_match_db_match_kmsg(struct kdbus_match_db *db,
                               struct kdbus_conn *conn_src,
                               struct kdbus_kmsg *kmsg);