mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 1/5] w35und: make wb35_probe() and wb35_disconnect() funtions static
@ 2008-10-22 16:05 Pekka J Enberg
  2008-10-23  9:46 ` Pavel Machek
  0 siblings, 1 reply; 2+ messages in thread
From: Pekka J Enberg @ 2008-10-22 16:05 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: Pavel Machek, linux-kernel

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

The wb35_probe() and wb35_disconnect() functions are only used in wbusb.c so
make them static and remove them from a header file.

Cc: Pavel Machek <pavel@suse.cz>
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi>
---
 drivers/staging/winbond/linux/wbusb.c   |    6 ++----
 drivers/staging/winbond/linux/wbusb_f.h |    4 ----
 2 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/drivers/staging/winbond/linux/wbusb.c b/drivers/staging/winbond/linux/wbusb.c
index b4be0d8..4b989c5 100644
--- a/drivers/staging/winbond/linux/wbusb.c
+++ b/drivers/staging/winbond/linux/wbusb.c
@@ -173,9 +173,7 @@ static const struct ieee80211_ops wbsoft_ops = {
 struct wbsoft_priv {
 };
 
-
-// Usb kernel subsystem will call this function when a new device is plugged into.
-int wb35_probe(struct usb_interface *intf, const struct usb_device_id *id_table)
+static int wb35_probe(struct usb_interface *intf, const struct usb_device_id *id_table)
 {
 	struct wb35_adapter *adapter;
 	PWBUSB		pWbUsb;
@@ -329,7 +327,7 @@ int wb35_close(struct net_device *netdev)
 	return 0;
 }
 
-void wb35_disconnect(struct usb_interface *intf)
+static void wb35_disconnect(struct usb_interface *intf)
 {
 	struct wb35_adapter * adapter = usb_get_intfdata(intf);
 	usb_set_intfdata(intf, NULL);
diff --git a/drivers/staging/winbond/linux/wbusb_f.h b/drivers/staging/winbond/linux/wbusb_f.h
index 5225fa4..0402f66 100644
--- a/drivers/staging/winbond/linux/wbusb_f.h
+++ b/drivers/staging/winbond/linux/wbusb_f.h
@@ -18,10 +18,6 @@ void WbUsb_destroy(phw_data_t pHwData);
 unsigned char WbWLanInitialize(struct wb35_adapter *adapter);
 #define	WbUsb_Stop( _A )
 
-int wb35_probe(struct usb_interface *intf,const struct usb_device_id *id_table);
-void wb35_disconnect(struct usb_interface *intf);
-
-
 #define WbUsb_CheckForHang( _P )
 #define WbUsb_DetectStart( _P, _I )
 
-- 
1.5.3.7


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH 1/5] w35und: make wb35_probe() and wb35_disconnect() funtions static
  2008-10-22 16:05 [PATCH 1/5] w35und: make wb35_probe() and wb35_disconnect() funtions static Pekka J Enberg
@ 2008-10-23  9:46 ` Pavel Machek
  0 siblings, 0 replies; 2+ messages in thread
From: Pavel Machek @ 2008-10-23  9:46 UTC (permalink / raw)
  To: Pekka J Enberg; +Cc: Greg Kroah-Hartman, linux-kernel

On Wed 2008-10-22 19:05:54, Pekka J Enberg wrote:
> From: Pekka Enberg <penberg@cs.helsinki.fi>
> 
> The wb35_probe() and wb35_disconnect() functions are only used in wbusb.c so
> make them static and remove them from a header file.
> 
> Cc: Pavel Machek <pavel@suse.cz>
> Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi>

ACK.

> ---
>  drivers/staging/winbond/linux/wbusb.c   |    6 ++----
>  drivers/staging/winbond/linux/wbusb_f.h |    4 ----
>  2 files changed, 2 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/staging/winbond/linux/wbusb.c b/drivers/staging/winbond/linux/wbusb.c
> index b4be0d8..4b989c5 100644
> --- a/drivers/staging/winbond/linux/wbusb.c
> +++ b/drivers/staging/winbond/linux/wbusb.c
> @@ -173,9 +173,7 @@ static const struct ieee80211_ops wbsoft_ops = {
>  struct wbsoft_priv {
>  };
>  
> -
> -// Usb kernel subsystem will call this function when a new device is plugged into.
> -int wb35_probe(struct usb_interface *intf, const struct usb_device_id *id_table)
> +static int wb35_probe(struct usb_interface *intf, const struct usb_device_id *id_table)
>  {
>  	struct wb35_adapter *adapter;
>  	PWBUSB		pWbUsb;
> @@ -329,7 +327,7 @@ int wb35_close(struct net_device *netdev)
>  	return 0;
>  }
>  
> -void wb35_disconnect(struct usb_interface *intf)
> +static void wb35_disconnect(struct usb_interface *intf)
>  {
>  	struct wb35_adapter * adapter = usb_get_intfdata(intf);
>  	usb_set_intfdata(intf, NULL);
> diff --git a/drivers/staging/winbond/linux/wbusb_f.h b/drivers/staging/winbond/linux/wbusb_f.h
> index 5225fa4..0402f66 100644
> --- a/drivers/staging/winbond/linux/wbusb_f.h
> +++ b/drivers/staging/winbond/linux/wbusb_f.h
> @@ -18,10 +18,6 @@ void WbUsb_destroy(phw_data_t pHwData);
>  unsigned char WbWLanInitialize(struct wb35_adapter *adapter);
>  #define	WbUsb_Stop( _A )
>  
> -int wb35_probe(struct usb_interface *intf,const struct usb_device_id *id_table);
> -void wb35_disconnect(struct usb_interface *intf);
> -
> -
>  #define WbUsb_CheckForHang( _P )
>  #define WbUsb_DetectStart( _P, _I )
>  

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

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2008-10-23  9:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-10-22 16:05 [PATCH 1/5] w35und: make wb35_probe() and wb35_disconnect() funtions static Pekka J Enberg
2008-10-23  9:46 ` Pavel Machek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®