linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: Rachel Kim <rachel.kim@atmel.com>, Dean Lee <dean.lee@atmel.com>,
	Chris Park <chris.park@atmel.com>,
	devel@driverdev.osuosl.org, nicolas.ferre@atmel.com,
	Johnny Kim <johnny.kim@atmel.com>,
	linux-kernel@vger.kernel.org,
	Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
	Arnd Bergmann <arnd@arndb.de>
Subject: [PATCH v2 01/12] staging: wilc1000: remove time wrapper
Date: Mon,  1 Jun 2015 21:06:34 +0200	[thread overview]
Message-ID: <1433185605-2492600-2-git-send-email-arnd@arndb.de> (raw)
In-Reply-To: <1433185605-2492600-1-git-send-email-arnd@arndb.de>

The abstraction for time in this driver is completely
unused, so remove it.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/staging/wilc1000/Makefile         |   2 +-
 drivers/staging/wilc1000/wilc_osconfig.h  |   1 -
 drivers/staging/wilc1000/wilc_oswrapper.h |   5 -
 drivers/staging/wilc1000/wilc_platform.h  |  12 --
 drivers/staging/wilc1000/wilc_time.c      | 163 ------------------------
 drivers/staging/wilc1000/wilc_time.h      | 205 ------------------------------
 6 files changed, 1 insertion(+), 387 deletions(-)
 delete mode 100644 drivers/staging/wilc1000/wilc_time.c
 delete mode 100644 drivers/staging/wilc1000/wilc_time.h

diff --git a/drivers/staging/wilc1000/Makefile b/drivers/staging/wilc1000/Makefile
index 13e3ed8ef31e..44551ee3c697 100644
--- a/drivers/staging/wilc1000/Makefile
+++ b/drivers/staging/wilc1000/Makefile
@@ -27,7 +27,7 @@ ccflags-$(CONFIG_WILC1000_DYNAMICALLY_ALLOCATE_MEMROY) += -DWILC_NORMAL_ALLOC
 
 wilc1000-objs := wilc_wfi_netdevice.o wilc_wfi_cfgoperations.o linux_wlan.o linux_mon.o \
 			wilc_memory.o wilc_msgqueue.o wilc_semaphore.o wilc_sleep.o wilc_strutils.o \
-			wilc_time.o wilc_timer.o coreconfigurator.o host_interface.o \
+			wilc_timer.o coreconfigurator.o host_interface.o \
 			fifo_buffer.o wilc_sdio.o wilc_spi.o wilc_wlan_cfg.o wilc_debugfs.o
 
 wilc1000-$(CONFIG_WILC1000_SDIO) += linux_wlan_sdio.o
diff --git a/drivers/staging/wilc1000/wilc_osconfig.h b/drivers/staging/wilc1000/wilc_osconfig.h
index aa98ea5b423f..f3d3108de876 100644
--- a/drivers/staging/wilc1000/wilc_osconfig.h
+++ b/drivers/staging/wilc1000/wilc_osconfig.h
@@ -27,7 +27,6 @@
 /* #define CONFIG_WILC_FILE_OPERATIONS_FEATURE */
 /* #define CONFIG_WILC_FILE_OPERATIONS_STRING_API */
 /* #define CONFIG_WILC_FILE_OPERATIONS_PATH_API */
-#define CONFIG_WILC_TIME_FEATURE
 /* #define CONFIG_WILC_EVENT_FEATURE */
 /* #define CONFIG_WILC_EVENT_TIMEOUT */
 /* #define CONFIG_WILC_SOCKET_FEATURE */
diff --git a/drivers/staging/wilc1000/wilc_oswrapper.h b/drivers/staging/wilc1000/wilc_oswrapper.h
index 03a1ecf90625..728ce7cac85a 100644
--- a/drivers/staging/wilc1000/wilc_oswrapper.h
+++ b/drivers/staging/wilc1000/wilc_oswrapper.h
@@ -89,11 +89,6 @@ typedef WILC_Uint16 WILC_WideChar;
 #include "wilc_fileops.h"
 #endif
 
-/* Time operations */
-#ifdef CONFIG_WILC_TIME_FEATURE
-#include "wilc_time.h"
-#endif
-
 /* Event support */
 #ifdef CONFIG_WILC_EVENT_FEATURE
 #include "wilc_event.h"
diff --git a/drivers/staging/wilc1000/wilc_platform.h b/drivers/staging/wilc1000/wilc_platform.h
index 87e4eedcc914..35d9f8a917ce 100644
--- a/drivers/staging/wilc1000/wilc_platform.h
+++ b/drivers/staging/wilc1000/wilc_platform.h
@@ -73,18 +73,6 @@
 #error This feature is not supported by this OS
 #endif
 
-/* CONFIG_WILC_TIME_FEATURE is implemented */
-
-/* remove the following block when implementing its feature */
-#ifdef CONFIG_WILC_TIME_UTC_SINCE_1970
-#error This feature is not supported by this OS
-#endif
-
-/* remove the following block when implementing its feature */
-#ifdef CONFIG_WILC_TIME_CALENDER
-#error This feature is not supported by this OS
-#endif
-
 /* remove the following block when implementing its feature */
 #ifdef CONFIG_WILC_EVENT_FEATURE
 #error This feature is not supported by this OS
diff --git a/drivers/staging/wilc1000/wilc_time.c b/drivers/staging/wilc1000/wilc_time.c
deleted file mode 100644
index 27c252b462ac..000000000000
--- a/drivers/staging/wilc1000/wilc_time.c
+++ /dev/null
@@ -1,163 +0,0 @@
-
-#define _CRT_SECURE_NO_DEPRECATE
-#include "wilc_oswrapper.h"
-
-#ifdef CONFIG_WILC_TIME_FEATURE
-
-
-WILC_Uint32 WILC_TimeMsec(void)
-{
-	WILC_Uint32 u32Time = 0;
-	struct timespec current_time;
-
-	current_time = current_kernel_time();
-	u32Time = current_time.tv_sec * 1000;
-	u32Time += current_time.tv_nsec / 1000000;
-
-
-	return u32Time;
-}
-
-
-#ifdef CONFIG_WILC_EXTENDED_TIME_OPERATIONS
-
-/**
- *  @brief
- *  @details    function returns the implementation's best approximation to the
- *                              processor time used by the process since the beginning of an
- *                              implementation-dependent time related only to the process invocation.
- *  @return             WILC_Uint32
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_Uint32 WILC_Clock()
-{
-
-}
-
-
-/**
- *  @brief
- *  @details    The difftime() function computes the difference between two calendar
- *                              times (as returned by WILC_GetTime()): time1 - time0.
- *  @param[in]  WILC_Time time1
- *  @param[in]  WILC_Time time0
- *  @return             WILC_Double
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_Double WILC_DiffTime(WILC_Time time1, WILC_Time time0)
-{
-
-}
-
-
-
-/**
- *  @brief
- *  @details    The gmtime() function converts the time in seconds since
- *                              the Epoch pointed to by timer into a broken-down time,
- *                              expressed as Coordinated Universal Time (UTC).
- *  @param[in]  const WILC_Time* timer
- *  @return             WILC_tm*
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_tm *WILC_GmTime(const WILC_Time *timer)
-{
-
-}
-
-
-/**
- *  @brief
- *  @details    The localtime() function converts the time in seconds since
- *                              the Epoch pointed to by timer into a broken-down time, expressed
- *                              as a local time. The function corrects for the timezone and any
- *                              seasonal time adjustments. Local timezone information is used as
- *                              though localtime() calls tzset().
- *  @param[in]  const WILC_Time* timer
- *  @return             WILC_tm*
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_tm *WILC_LocalTime(const WILC_Time *timer)
-{
-
-}
-
-
-/**
- *  @brief
- *  @details    The mktime() function converts the broken-down time,
- *                              expressed as local time, in the structure pointed to by timeptr,
- *                              into a time since the Epoch value with the same encoding as that
- *                              of the values returned by time(). The original values of the tm_wday
- *                              and tm_yday components of the structure are ignored, and the original
- *                              values of the other components are not restricted to the ranges described
- *                              in the <time.h> entry.
- *  @param[in]  WILC_tm* timer
- *  @return             WILC_Time
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_Time WILC_MkTime(WILC_tm *timer)
-{
-
-}
-
-
-/**
- *  @brief
- *  @details    The strftime() function places bytes into the array
- *                              pointed to by s as controlled by the string pointed to by format.
- *  @param[in]  WILC_Char* s
- *  @param[in]	WILC_Uint32 maxSize
- *  @param[in]	const WILC_Char* format
- *  @param[in]	const WILC_tm* timptr
- *  @return             WILC_Uint32
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_Uint32 WILC_StringFormatTime(WILC_Char *s,
-				  WILC_Uint32 maxSize,
-				  const WILC_Char *format,
-				  const WILC_tm *timptr)
-{
-
-}
-
-
-/**
- *  @brief              The WILC_GetTime() function returns the value of time in seconds since the Epoch.
- *  @details    The tloc argument points to an area where the return value is also stored.
- *                              If tloc is a null pointer, no value is stored.
- *  @param[in]  WILC_Time* tloc
- *  @return             WILC_Time
- *  @note
- *  @author		remil
- *  @date		11 Nov 2010
- *  @version		1.0
- */
-WILC_Time WILC_GetTime(WILC_Time *tloc)
-{
-
-}
-
-
-#endif
-#endif
-
-
diff --git a/drivers/staging/wilc1000/wilc_time.h b/drivers/staging/wilc1000/wilc_time.h
deleted file mode 100644
index 787df7ded75c..000000000000
--- a/drivers/staging/wilc1000/wilc_time.h
+++ /dev/null
@@ -1,205 +0,0 @@
-#ifndef __WILC_TIME_H__
-#define __WILC_TIME_H__
-
-/*!
-*  @file		wilc_time.h
-*  @brief		Time retrival functionality
-*  @author		syounan
-*  @sa			wilc_oswrapper.h top level OS wrapper file
-*  @date		2 Sep 2010
-*  @version		1.0
-*/
-
-#ifndef CONFIG_WILC_TIME_FEATURE
-#error the feature CONFIG_WILC_TIME_FEATURE must be supported to include this file
-#endif
-
-/*!
-*  @struct 		WILC_ThreadAttrs
-*  @brief		Thread API options
-*  @author		syounan
-*  @date		2 Sep 2010
-*  @version		1.0
-*/
-typedef struct {
-	/* a dummy type to prevent compile errors on empty structure*/
-	WILC_Uint8 dummy;
-} tstrWILC_TimeAttrs;
-
-typedef struct {
-	/*!< current year */
-	WILC_Uint16	u16Year;
-	/*!< current month */
-	WILC_Uint8	u8Month;
-	/*!< current day */
-	WILC_Uint8	u8Day;
-
-	/*!< current hour (in 24H format) */
-	WILC_Uint8	u8Hour;
-	/*!< current minute */
-	WILC_Uint8	u8Miute;
-	/*!< current second */
-	WILC_Uint8	u8Second;
-
-} tstrWILC_TimeCalender;
-
-/*!
-*  @brief		returns the number of msec elapsed since system start up
-*  @return		number of msec elapsed singe system start up
-*  @note		since this returned value is 32 bit, the caller must handle
-				wraparounds in values every about 49 of continous operations
-*  @author		syounan
-*  @date		2 Sep 2010
-*  @version		1.0
-*/
-WILC_Uint32 WILC_TimeMsec(void);
-
-
-
-#ifdef CONFIG_WILC_EXTENDED_TIME_OPERATIONS
-/**
-*  @brief
-*  @details 	function returns the implementation's best approximation to the
-				processor time used by the process since the beginning of an
-				implementation-dependent time related only to the process invocation.
-*  @return 		WILC_Uint32
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_Uint32 WILC_Clock();
-
-/**
-*  @brief
-*  @details 	The difftime() function computes the difference between two calendar
-				times (as returned by WILC_GetTime()): time1 - time0.
-*  @param[in] 	WILC_Time time1
-*  @param[in] 	WILC_Time time0
-*  @return 		WILC_Double
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_Double WILC_DiffTime(WILC_Time time1, WILC_Time time0);
-
-/**
-*  @brief
-*  @details 	The gmtime() function converts the time in seconds since
-				the Epoch pointed to by timer into a broken-down time,
-				expressed as Coordinated Universal Time (UTC).
-*  @param[in] 	const WILC_Time* timer
-*  @return 		WILC_tm*
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_tm *WILC_GmTime(const WILC_Time *timer);
-
-
-/**
-*  @brief
-*  @details 	The localtime() function converts the time in seconds since
-				the Epoch pointed to by timer into a broken-down time, expressed
-				as a local time. The function corrects for the timezone and any
-				seasonal time adjustments. Local timezone information is used as
-				though localtime() calls tzset().
-*  @param[in] 	const WILC_Time* timer
-*  @return 		WILC_tm*
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_tm *WILC_LocalTime(const WILC_Time *timer);
-
-
-/**
-*  @brief
-*  @details 	The mktime() function converts the broken-down time,
-				expressed as local time, in the structure pointed to by timeptr,
-				into a time since the Epoch value with the same encoding as that
-				of the values returned by time(). The original values of the tm_wday
-				and tm_yday components of the structure are ignored, and the original
-				values of the other components are not restricted to the ranges described
-				in the <time.h> entry.
-*  @param[in] 	WILC_tm* timer
-*  @return 		WILC_Time
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_Time WILC_MkTime(WILC_tm *timer);
-
-
-/**
-*  @brief
-*  @details 	The strftime() function places bytes into the array
-				pointed to by s as controlled by the string pointed to by format.
-*  @param[in] 	WILC_Char* s
-*  @param[in]	WILC_Uint32 maxSize
-*  @param[in]	const WILC_Char* format
-*  @param[in]	const WILC_tm* timptr
-*  @return 		WILC_Uint32
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_Uint32 WILC_StringFormatTime(WILC_Char *s,
-								WILC_Uint32 maxSize,
-								const WILC_Char *format,
-								const WILC_tm *timptr);
-
-
-/**
-*  @brief 		The WILC_GetTime() function returns the value of time in seconds since the Epoch.
-*  @details 	The tloc argument points to an area where the return value is also stored.
-				If tloc is a null pointer, no value is stored.
-*  @param[in] 	WILC_Time* tloc
-*  @return 		WILC_Time
-*  @note
-*  @author		remil
-*  @date		11 Nov 2010
-*  @version		1.0
-*/
-WILC_Time WILC_GetTime(WILC_Time *tloc);
-
-#endif
-
-#ifdef CONFIG_WILC_TIME_UTC_SINCE_1970
-
-/*!
-*  @brief		returns the number of seconds elapsed since 1970 (in UTC)
-*  @param[in]	pstrAttrs Optional attributes, NULL for default
-*  @return		number of seconds elapsed since 1970 (in UTC)
-*  @sa			tstrWILC_TimeAttrs
-*  @author		syounan
-*  @date		2 Sep 2010
-*  @version		1.0
-*/
-WILC_Uint32 WILC_TimeUtcSince1970(tstrWILC_TimeAttrs *pstrAttrs);
-
-#endif
-
-#ifdef CONFIG_WILC_TIME_CALENDER
-
-/*!
-*  @brief		gets the current calender time
-*  @return		number of seconds elapsed since 1970 (in UTC)
-*  @param[out]	ptstrCalender calender structure to be filled with time
-*  @param[in]	pstrAttrs Optional attributes, NULL for default
-*  @sa			WILC_ThreadAttrs
-*  @author		syounan
-*  @date		2 Sep 2010
-*  @version		1.0
-*/
-WILC_ErrNo WILC_TimeCalender(tstrWILC_TimeCalender *ptstrCalender,
-	tstrWILC_TimeAttrs *pstrAttrs);
-
-#endif
-
-#endif
-- 
2.1.0.rc2


  reply	other threads:[~2015-06-01 19:08 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-01 19:06 [PATCH v3 00/12] wilc1000: dead code removal and other cleanup Arnd Bergmann
2015-06-01 19:06 ` Arnd Bergmann [this message]
2015-06-01 19:06 ` [PATCH v2 02/12] staging: wilc1000: remove unused string functions Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 03/12] staging: wilc1000: simplify msgqueue code Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 04/12] staging: wilc1000: remove unused memory handling code Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 05/12] staging: wilc1000: simplify semaphore wrapper Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 06/12] staging: wilc1000: clean up sleep wrapper Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 07/12] staging: wilc1000: clean up timer feature Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 08/12] staging: wilc1000: remove unused OS abstraction features Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 09/12] staging: wilc1000: remove EXPORT_SYMTAB Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 10/12] staging: wilc1000: remove semaphore wrapper Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 11/12] staging: wilc1000: fix const cast warnings Arnd Bergmann
2015-06-01 19:06 ` [PATCH v2 12/12] staging: wilc1000: fix compiler warnings Arnd Bergmann
2015-06-02  4:53 ` [PATCH v3 00/12] wilc1000: dead code removal and other cleanup Greg KH
2015-06-02  5:20   ` Greg KH
2015-06-02  6:23     ` Johnny Kim

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1433185605-2492600-2-git-send-email-arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=chris.park@atmel.com \
    --cc=dean.lee@atmel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=johnny.kim@atmel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nicolas.ferre@atmel.com \
    --cc=rachel.kim@atmel.com \
    --cc=sudipm.mukherjee@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).