FreeBSD Bugzilla – Attachment 193934 Details for
Bug 228694
[patch] unused argument in turnstile_unpend
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch that deletes unused argument
patch (text/plain), 3.81 KB, created by
Julian Pszczołowski
on 2018-06-02 15:39:43 UTC
(
hide
)
Description:
Patch that deletes unused argument
Filename:
MIME Type:
Creator:
Julian Pszczołowski
Created:
2018-06-02 15:39:43 UTC
Size:
3.81 KB
patch
obsolete
>diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c >index 4135786..c6bf923 100644 >--- a/sys/amd64/amd64/pmap.c >+++ b/sys/amd64/amd64/pmap.c >@@ -513,7 +513,7 @@ pmap_delayed_invl_finished(void) > pmap_invl_gen = invl_gen->gen; > if (ts != NULL) { > turnstile_broadcast(ts, TS_SHARED_QUEUE); >- turnstile_unpend(ts, TS_SHARED_LOCK); >+ turnstile_unpend(ts); > } > turnstile_chain_unlock(&invl_gen_ts); > } else { >diff --git a/sys/kern/kern_mutex.c b/sys/kern/kern_mutex.c >index 228840b..c3f566d 100644 >--- a/sys/kern/kern_mutex.c >+++ b/sys/kern/kern_mutex.c >@@ -1029,7 +1029,7 @@ __mtx_unlock_sleep(volatile uintptr_t *c, uintptr_t v) > * This turnstile is now no longer associated with the mutex. We can > * unlock the chain lock so a new turnstile may take it's place. > */ >- turnstile_unpend(ts, TS_EXCLUSIVE_LOCK); >+ turnstile_unpend(ts); > turnstile_chain_unlock(&m->lock_object); > } > >diff --git a/sys/kern/kern_rmlock.c b/sys/kern/kern_rmlock.c >index a826460..80f5400 100644 >--- a/sys/kern/kern_rmlock.c >+++ b/sys/kern/kern_rmlock.c >@@ -494,7 +494,7 @@ _rm_unlock_hard(struct thread *td,struct rm_priotracker *tracker) > ts = turnstile_lookup(&rm->lock_object); > > turnstile_signal(ts, TS_EXCLUSIVE_QUEUE); >- turnstile_unpend(ts, TS_EXCLUSIVE_LOCK); >+ turnstile_unpend(ts); > turnstile_chain_unlock(&rm->lock_object); > } else > mtx_unlock_spin(&rm_spinlock); >diff --git a/sys/kern/kern_rwlock.c b/sys/kern/kern_rwlock.c >index e9a02bd..9ec967b 100644 >--- a/sys/kern/kern_rwlock.c >+++ b/sys/kern/kern_rwlock.c >@@ -822,7 +822,7 @@ __rw_runlock_hard(struct rwlock *rw, struct thread *td, uintptr_t v > ts = turnstile_lookup(&rw->lock_object); > MPASS(ts != NULL); > turnstile_broadcast(ts, queue); >- turnstile_unpend(ts, TS_SHARED_LOCK); >+ turnstile_unpend(ts); > td->td_rw_rlocks--; > break; > } >@@ -1259,7 +1259,7 @@ __rw_wunlock_hard(volatile uintptr_t *c, uintptr_t v LOCK_FILE_LINE_ARG_DEF) > ts = turnstile_lookup(&rw->lock_object); > MPASS(ts != NULL); > turnstile_broadcast(ts, queue); >- turnstile_unpend(ts, TS_EXCLUSIVE_LOCK); >+ turnstile_unpend(ts); > turnstile_chain_unlock(&rw->lock_object); > } > >@@ -1405,7 +1405,7 @@ __rw_downgrade_int(struct rwlock *rw LOCK_FILE_LINE_ARG_DEF) > */ > if (rwait && !wwait) { > turnstile_broadcast(ts, TS_SHARED_QUEUE); >- turnstile_unpend(ts, TS_EXCLUSIVE_LOCK); >+ turnstile_unpend(ts); > } else > turnstile_disown(ts); > turnstile_chain_unlock(&rw->lock_object); >diff --git a/sys/kern/subr_turnstile.c b/sys/kern/subr_turnstile.c >index 98ef54e..e4ff9a7 100644 >--- a/sys/kern/subr_turnstile.c >+++ b/sys/kern/subr_turnstile.c >@@ -903,7 +903,7 @@ turnstile_broadcast(struct turnstile *ts, int queue) > * chain locked. > */ > void >-turnstile_unpend(struct turnstile *ts, int owner_type) >+turnstile_unpend(struct turnstile *ts) > { > TAILQ_HEAD( ,thread) pending_threads; > struct turnstile *nts; >diff --git a/sys/sys/turnstile.h b/sys/sys/turnstile.h >index 3843bbd..b2a14ea 100644 >--- a/sys/sys/turnstile.h >+++ b/sys/sys/turnstile.h >@@ -83,10 +83,6 @@ struct turnstile; > #define TS_EXCLUSIVE_QUEUE 0 > #define TS_SHARED_QUEUE 1 > >-/* The type of lock currently held. */ >-#define TS_EXCLUSIVE_LOCK TS_EXCLUSIVE_QUEUE >-#define TS_SHARED_LOCK TS_SHARED_QUEUE >- > void init_turnstiles(void); > void turnstile_adjust(struct thread *, u_char); > struct turnstile *turnstile_alloc(void); >@@ -102,7 +98,7 @@ struct thread *turnstile_head(struct turnstile *, int); > struct turnstile *turnstile_lookup(struct lock_object *); > int turnstile_signal(struct turnstile *, int); > struct turnstile *turnstile_trywait(struct lock_object *); >-void turnstile_unpend(struct turnstile *, int); >+void turnstile_unpend(struct turnstile *); > void turnstile_wait(struct turnstile *, struct thread *, int); > struct thread *turnstile_lock(struct turnstile *, struct lock_object **); > void turnstile_unlock(struct turnstile *, struct lock_object *);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 228694
: 193934