Re: [PATCH 1/6] w35und: remove timer wrappers

Previous thread: 2.6.28-rc2 - strange (redundant) sysfs paths for SCSI by Andrey Borzenkov on Wednesday, October 29, 2008 - 2:05 pm. (2 messages)

Next thread: [PATCH 2/6] w35und: remove atomic op wrappers by Pekka J Enberg on Wednesday, October 29, 2008 - 2:10 pm. (2 messages)
To: Greg Kroah-Hartman <greg@...>
Cc: Pavel Machek <pavel@...>, <linux-kernel@...>
Date: Wednesday, October 29, 2008 - 2:10 pm

From: Pekka Enberg <penberg@cs.helsinki.fi>

This patch removes the OS_TIMER and related wrappers from driver code. The
patch also changes the code to use msecs_to_jiffies() for setting up
timer->expires.

Cc: Pavel Machek <pavel@suse.cz>
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi>
---
drivers/staging/winbond/bssdscpt.h | 2 +-
drivers/staging/winbond/linux/common.h | 19 -
drivers/staging/winbond/mds_f.h | 6 -
drivers/staging/winbond/mds_s.h | 3 +-
drivers/staging/winbond/rxisr.c | 29 +-
drivers/staging/winbond/scan_s.h | 3 +-
drivers/staging/winbond/sme_s.h | 3 +-
drivers/staging/winbond/wbhal.c | 586 ++++++++++++++++----------------
drivers/staging/winbond/wbhal_f.h | 2 -
drivers/staging/winbond/wbhal_s.h | 2 +-
10 files changed, 312 insertions(+), 343 deletions(-)

diff --git a/drivers/staging/winbond/bssdscpt.h b/drivers/staging/winbond/bssdscpt.h
index 6f557cb..90b5682 100644
--- a/drivers/staging/winbond/bssdscpt.h
+++ b/drivers/staging/winbond/bssdscpt.h
@@ -79,7 +79,7 @@ typedef struct BSSDescriptionElement
u16 wIndex; // THIS BSS element entry index

void* psadapter; // pointer to THIS adapter
- OS_TIMER nTimer; // MLME timer
+ struct timer_list timer; // MLME timer

// Authentication
u16 wAuthAlgo; // peer MAC MLME use Auth algorithm, default OPEN_AUTH
diff --git a/drivers/staging/winbond/linux/common.h b/drivers/staging/winbond/linux/common.h
index 42c23a8..521b68a 100644
--- a/drivers/staging/winbond/linux/common.h
+++ b/drivers/staging/winbond/linux/common.h
@@ -84,24 +84,5 @@
#define OS_MEMORY_CLEAR( _A, _S ) memset( (u8 *)_A,0,_S)
#define OS_MEMORY_COMPARE( _A, _B, _S ) (memcmp(_A,_B,_S)? 0 : 1) // Definition is reverse with Ndis 1: the same 0: different

-#define OS_TIMER struct timer_list
-#define OS_TIMER_INITIAL( _T, _F, _P ) \
-{ \
- init_timer( _T ); \
- (_T)->function = (void *)_F##_...

To: Pekka J Enberg <penberg@...>
Cc: Greg Kroah-Hartman <greg@...>, <linux-kernel@...>
Date: Wednesday, October 29, 2008 - 5:36 pm

It also moves LED handling function.

--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--

To: Pavel Machek <pavel@...>
Cc: Greg Kroah-Hartman <greg@...>, <linux-kernel@...>
Date: Wednesday, October 29, 2008 - 6:57 pm

Oh right. That's because I made all the timer functions static and
wanted to avoid a forward declaration.

Pekka
--

Previous thread: 2.6.28-rc2 - strange (redundant) sysfs paths for SCSI by Andrey Borzenkov on Wednesday, October 29, 2008 - 2:05 pm. (2 messages)

Next thread: [PATCH 2/6] w35und: remove atomic op wrappers by Pekka J Enberg on Wednesday, October 29, 2008 - 2:10 pm. (2 messages)