[2.4.28] gcc34 fastcall mismatch fixes for rwsem-spinlock
PATCH 1/1 [2.4.28] gcc34 fastcall mismatch fixes for rwsem-spinlock
Kernel 2.4.28 fails to compile with gcc-3.4 when CONFIG_M386=y because of fastcall mismatches between include/linux/rwsem-spinlock.h and lib/rwsem-spinlock.c. This patch fixes that.
Signed-off-by Mikael Pettersson <[email protected]>
lib/rwsem-spinlock.c | 14 +++++++------- 1 files changed, 7 insertions(+), 7 deletions(-)
lib/rwsem-spinlock.c +7 -7
@@ -32,7 +32,7 @@ void rwsemtrace(struct rw_semaphore *sem/* * initialise the semaphore */ -void init_rwsem (struct rw_semaphore *sem) +void fastcall init_rwsem(struct rw_semaphore *sem) { sem->activity =0 ;spin_lock_init (&sem->wait_lock);
@@ -120,7 +120,7 @@ static inline struct rw_semaphore *__rws/* * get a read lock on the semaphore */ -void __down_read (struct rw_semaphore *sem) +void fastcall __down_read(struct rw_semaphore *sem) {struct rwsem_waiter waiter;struct task_struct *tsk;
@@ -166,7 +166,7 @@ void __down_read(struct rw_semaphore *se/* * trylock for reading -- returns 1 if successful, 0 if contention */ -int __down_read_trylock (struct rw_semaphore *sem) +int fastcall __down_read_trylock(struct rw_semaphore *sem) {int ret =0 ;rwsemtrace (sem,"Entering __down_read_trylock" );
@@ -189,7 +189,7 @@ int __down_read_trylock(struct rw_semaph* get a write lock on the semaphore * - note that we increment the waiting count anyway to indicate an exclusive lock */ -void __down_write (struct rw_semaphore *sem) +void fastcall __down_write(struct rw_semaphore *sem) {struct rwsem_waiter waiter;struct task_struct *tsk;
@@ -235,7 +235,7 @@ void __down_write(struct rw_semaphore *s/* * trylock for writing -- returns 1 if successful, 0 if contention */ -int __down_write_trylock (struct rw_semaphore *sem) +int fastcall __down_write_trylock(struct rw_semaphore *sem) {int ret =0 ;rwsemtrace (sem,"Entering __down_write_trylock" );
@@ -257,7 +257,7 @@ int __down_write_trylock(struct rw_semap/* * release a read lock on the semaphore */ -void __up_read (struct rw_semaphore *sem) +void fastcall __up_read(struct rw_semaphore *sem) {rwsemtrace (sem,"Entering __up_read" );
@@ -274,7 +274,7 @@ void __up_read(struct rw_semaphore *sem)/* * release a write lock on the semaphore */ -void __up_write (struct rw_semaphore *sem) +void fastcall __up_write(struct rw_semaphore *sem) {rwsemtrace (sem,"Entering __up_write" );