Skip to contentSkip to conversation

lockdep: Remove unused parameter in add_lock_to_list() function

PATCH New Tahsin Erdogan 2 participants 2 messages Nov 8, 2016 – Nov 12, 2016 Locking primitives

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lockdep: Remove unused parameter in add_lock_to_list() function

class parameter is not used, remove it.

---
 kernel/locking/lockdep.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
kernel/locking/lockdep.c +5 -5
index 589d763a49b3..e74b438c850b 100644
@@ -840,9 +840,9 @@ static struct lock_list *alloc_list_entry(void)
 /*
  * Add a new dependency to the head of the list:
  */
-static int add_lock_to_list(struct lock_class *class, struct lock_class *this,
-			    struct list_head *head, unsigned long ip,
-			    int distance, struct stack_trace *trace)
+static int add_lock_to_list(struct lock_class *this, struct list_head *head,
+			    unsigned long ip, int distance,
+			    struct stack_trace *trace)
 {
 	struct lock_list *entry;
 	/*
@@ -1869,14 +1869,14 @@ check_prev_add(struct task_struct *curr, struct held_lock *prev,
 	 * Ok, all validations passed, add the new lock
 	 * to the previous lock's dependency list:
 	 */
-	ret = add_lock_to_list(hlock_class(prev), hlock_class(next),
+	ret = add_lock_to_list(hlock_class(next),
 			       &hlock_class(prev)->locks_after,
 			       next->acquire_ip, distance, &trace);
 
 	if (!ret)
 		return 0;
 
-	ret = add_lock_to_list(hlock_class(next), hlock_class(prev),
+	ret = add_lock_to_list(hlock_class(prev),
 			       &hlock_class(next)->locks_before,
 			       next->acquire_ip, distance, &trace);
 	if (!ret)
Signature · 1 line
2.8.0.rc3.226.g39d4020
#1 lore raw

[tip:locking/core] locking/lockdep: Remove unused parameter from the add_lock_to_list() function

locking/lockdep: Remove unused parameter from the add_lock_to_list() function
Commit-ID:  83f06168ef15da5dc735c7ea14fae67609ed9538
Gitweb:     http://git.kernel.org/tip/83f06168ef15da5dc735c7ea14fae67609ed9538
Author:     Tahsin Erdogan <[email protected]>
AuthorDate: Tue, 8 Nov 2016 00:02:07 -0800
Committer:  Ingo Molnar <[email protected]>
CommitDate: Fri, 11 Nov 2016 08:25:20 +0100

locking/lockdep: Remove unused parameter from the add_lock_to_list() function

The 'class' parameter is not used, remove it. n

---
 kernel/locking/lockdep.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
kernel/locking/lockdep.c +5 -5
index 589d763..e74b438 100644
@@ -840,9 +840,9 @@ static struct lock_list *alloc_list_entry(void)
 /*
  * Add a new dependency to the head of the list:
  */
-static int add_lock_to_list(struct lock_class *class, struct lock_class *this,
-			    struct list_head *head, unsigned long ip,
-			    int distance, struct stack_trace *trace)
+static int add_lock_to_list(struct lock_class *this, struct list_head *head,
+			    unsigned long ip, int distance,
+			    struct stack_trace *trace)
 {
 	struct lock_list *entry;
 	/*
@@ -1869,14 +1869,14 @@ check_prev_add(struct task_struct *curr, struct held_lock *prev,
 	 * Ok, all validations passed, add the new lock
 	 * to the previous lock's dependency list:
 	 */
-	ret = add_lock_to_list(hlock_class(prev), hlock_class(next),
+	ret = add_lock_to_list(hlock_class(next),
 			       &hlock_class(prev)->locks_after,
 			       next->acquire_ip, distance, &trace);
 
 	if (!ret)
 		return 0;
 
-	ret = add_lock_to_list(hlock_class(next), hlock_class(prev),
+	ret = add_lock_to_list(hlock_class(prev),
 			       &hlock_class(next)->locks_before,
 			       next->acquire_ip, distance, &trace);
 	if (!ret)