public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Martin Dalecki <dalecki@evision-ventures.com>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [PATCH] 2.5.21 kill warnings 8/19
Date: Mon, 10 Jun 2002 13:38:34 +0200	[thread overview]
Message-ID: <3D048FBA.9010900@evision-ventures.com> (raw)
In-Reply-To: <Pine.LNX.4.33.0206082235240.4635-100000@penguin.transmeta.com>

[-- Attachment #1: Type: text/plain, Size: 82 bytes --]

- Fix improper __FUNCTION__ usage in irda_device.
- Whitepsace cleanup there too.

[-- Attachment #2: warn-2.5.21-8.diff --]
[-- Type: text/plain, Size: 9339 bytes --]

diff -urN linux-2.5.21/net/irda/irda_device.c linux/net/irda/irda_device.c
--- linux-2.5.21/net/irda/irda_device.c	2002-06-09 07:29:50.000000000 +0200
+++ linux/net/irda/irda_device.c	2002-06-09 20:11:02.000000000 +0200
@@ -1,5 +1,5 @@
 /*********************************************************************
- *                
+ *
  * Filename:      irda_device.c
  * Version:       0.9
  * Description:   Utility functions used by the device drivers
@@ -8,25 +8,25 @@
  * Created at:    Sat Oct  9 09:22:27 1999
  * Modified at:   Sun Jan 23 17:41:24 2000
  * Modified by:   Dag Brattli <dagb@cs.uit.no>
- * 
+ *
  *     Copyright (c) 1999-2000 Dag Brattli, All Rights Reserved.
  *     Copyright (c) 2000-2001 Jean Tourrilhes <jt@hpl.hp.com>
- *     
- *     This program is free software; you can redistribute it and/or 
- *     modify it under the terms of the GNU General Public License as 
- *     published by the Free Software Foundation; either version 2 of 
+ *
+ *     This program is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of
  *     the License, or (at your option) any later version.
- * 
+ *
  *     This program is distributed in the hope that it will be useful,
  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  *     GNU General Public License for more details.
- * 
- *     You should have received a copy of the GNU General Public License 
- *     along with this program; if not, write to the Free Software 
- *     Foundation, Inc., 59 Temple Place, Suite 330, Boston, 
+ *
+ *     You should have received a copy of the GNU General Public License
+ *     along with this program; if not, write to the Free Software
+ *     Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  *     MA 02111-1307 USA
- *     
+ *
  ********************************************************************/
 
 #include <linux/config.h>
@@ -83,7 +83,7 @@
 #ifdef CONFIG_IRDA_DEBUG
 static const char *task_state[] = {
 	"IRDA_TASK_INIT",
-	"IRDA_TASK_DONE", 
+	"IRDA_TASK_DONE",
 	"IRDA_TASK_WAIT",
 	"IRDA_TASK_WAIT1",
 	"IRDA_TASK_WAIT2",
@@ -97,7 +97,7 @@
 static void irda_task_timer_expired(void *data);
 
 #ifdef CONFIG_PROC_FS
-int irda_device_proc_read(char *buf, char **start, off_t offset, int len, 
+int irda_device_proc_read(char *buf, char **start, off_t offset, int len,
 			  int unused);
 
 #endif /* CONFIG_PROC_FS */
@@ -106,21 +106,19 @@
 {
 	dongles = hashbin_new(HB_GLOBAL);
 	if (dongles == NULL) {
-		printk(KERN_WARNING 
-		       "IrDA: Can't allocate dongles hashbin!\n");
+		printk(KERN_WARNING "IrDA: Can't allocate dongles hashbin!\n");
 		return -ENOMEM;
 	}
 
 	tasks = hashbin_new(HB_GLOBAL);
 	if (tasks == NULL) {
-		printk(KERN_WARNING 
-		       "IrDA: Can't allocate tasks hashbin!\n");
+		printk(KERN_WARNING "IrDA: Can't allocate tasks hashbin!\n");
 		return -ENOMEM;
 	}
 
-	/* 
+	/*
 	 * Call the init function of the device drivers that has not been
-	 * compiled as a module 
+	 * compiled as a module
 	 */
 #ifdef CONFIG_IRTTY_SIR
 	irtty_init();
@@ -156,10 +154,10 @@
 	litelink_init();
 #endif
 #ifdef CONFIG_OLD_BELKIN
- 	old_belkin_init();
+	old_belkin_init();
 #endif
 #ifdef CONFIG_EP7211_IR
- 	ep7211_ir_init();
+	ep7211_ir_init();
 #endif
 	return 0;
 }
@@ -178,7 +176,7 @@
  *    Called when we have detected that another station is transmiting
  *    in contention mode.
  */
-void irda_device_set_media_busy(struct net_device *dev, int status) 
+void irda_device_set_media_busy(struct net_device *dev, int status)
 {
 	struct irlap_cb *self;
 
@@ -203,15 +201,15 @@
 }
 
 int irda_device_set_dtr_rts(struct net_device *dev, int dtr, int rts)
-{	
+{
 	struct if_irda_req req;
 	int ret;
 
 	IRDA_DEBUG(2, __FUNCTION__ "()\n");
 
 	if (!dev->do_ioctl) {
-		ERROR(__FUNCTION__ "(), do_ioctl not impl. by "
-		      "device driver\n");
+		ERROR("%s: do_ioctl not impl. by device driver\n",
+				__FUNCTION__);
 		return -1;
 	}
 
@@ -224,15 +222,15 @@
 }
 
 int irda_device_change_speed(struct net_device *dev, __u32 speed)
-{	
+{
 	struct if_irda_req req;
 	int ret;
 
 	IRDA_DEBUG(2, __FUNCTION__ "()\n");
 
 	if (!dev->do_ioctl) {
-		ERROR(__FUNCTION__ "(), do_ioctl not impl. by "
-		      "device driver\n");
+		ERROR("%s: do_ioctl not impl. by device driver\n",
+				__FUNCTION__);
 		return -1;
 	}
 
@@ -257,8 +255,8 @@
 	IRDA_DEBUG(2, __FUNCTION__ "()\n");
 
 	if (!dev->do_ioctl) {
-		ERROR(__FUNCTION__ "(), do_ioctl not impl. by "
-		      "device driver\n");
+		ERROR("%s: do_ioctl not impl. by device driver\n",
+				__FUNCTION__);
 		return -1;
 	}
 
@@ -279,7 +277,7 @@
 static void __irda_task_delete(struct irda_task *task)
 {
 	del_timer(&task->timer);
-	
+
 	kfree(task);
 }
 
@@ -314,14 +312,14 @@
 	do {
 		timeout = task->function(task);
 		if (count++ > 100) {
-			ERROR(__FUNCTION__ "(), error in task handler!\n");
+			ERROR("%s: error in task handler!\n", __FUNCTION__);
 			irda_task_delete(task);
 			return TRUE;
-		}			
+		}
 	} while ((timeout == 0) && (task->state != IRDA_TASK_DONE));
 
 	if (timeout < 0) {
-		ERROR(__FUNCTION__ "(), Error executing task!\n");
+		ERROR("%s: Error executing task!\n", __FUNCTION__);
 		irda_task_delete(task);
 		return TRUE;
 	}
@@ -346,14 +344,14 @@
 				/* Kick parent task */
 				irda_task_kick(task->parent);
 			}
-		}		
+		}
 		irda_task_delete(task);
 	} else if (timeout > 0) {
-		irda_start_timer(&task->timer, timeout, (void *) task, 
+		irda_start_timer(&task->timer, timeout, (void *) task,
 				 irda_task_timer_expired);
 		finished = FALSE;
 	} else {
-		IRDA_DEBUG(0, __FUNCTION__ 
+		IRDA_DEBUG(0, __FUNCTION__
 			   "(), not finished, and no timeout!\n");
 		finished = FALSE;
 	}
@@ -367,7 +365,7 @@
  *    This function registers and tries to execute tasks that may take some
  *    time to complete. We do it this hairy way since we may have been
  *    called from interrupt context, so it's not possible to use
- *    schedule_timeout() 
+ *    schedule_timeout()
  * Two important notes :
  *	o Make sure you irda_task_delete(task); in case you delete the
  *	  calling instance.
@@ -375,9 +373,9 @@
  *	  want to lock within the task handler.
  * Jean II
  */
-struct irda_task *irda_task_execute(void *instance, 
-				    IRDA_TASK_CALLBACK function, 
-				    IRDA_TASK_CALLBACK finished, 
+struct irda_task *irda_task_execute(void *instance,
+				    IRDA_TASK_CALLBACK function,
+				    IRDA_TASK_CALLBACK finished,
 				    struct irda_task *parent, void *param)
 {
 	struct irda_task *task;
@@ -394,7 +392,7 @@
 	task->function = function;
 	task->finished = finished;
 	task->parent   = parent;
-	task->param    = param;	
+	task->param    = param;
 	task->magic    = IRDA_TASK_MAGIC;
 
 	init_timer(&task->timer);
@@ -433,7 +431,7 @@
  *    This function should be used by low level device drivers in a similar way
  *    as ether_setup() is used by normal network device drivers
  */
-int irda_device_setup(struct net_device *dev) 
+int irda_device_setup(struct net_device *dev)
 {
 	ASSERT(dev != NULL, return -1;);
 
@@ -445,7 +443,7 @@
 
         dev->type            = ARPHRD_IRDA;
         dev->tx_queue_len    = 8; /* Window size + 1 s-frame */
- 
+
 	memset(dev->broadcast, 0xff, 4);
 
 	dev->mtu = 2048;
@@ -491,7 +489,7 @@
 	sprintf(modname, "irda-dongle-%d", type);
 	request_module(modname);
 	}
-#endif /* CONFIG_KMOD */
+#endif
 
 	if (!(reg = hashbin_find(dongles, type, NULL))) {
 		ERROR("IrDA: Unable to find requested dongle\n");
@@ -514,9 +512,6 @@
 
 /*
  * Function irda_device_dongle_cleanup (dongle)
- *
- *    
- *
  */
 int irda_device_dongle_cleanup(dongle_t *dongle)
 {
@@ -531,21 +526,18 @@
 
 /*
  * Function irda_device_register_dongle (dongle)
- *
- *    
- *
  */
 int irda_device_register_dongle(struct dongle_reg *new)
 {
 	/* Check if this dongle has been registred before */
 	if (hashbin_find(dongles, new->type, NULL)) {
-		MESSAGE(__FUNCTION__ "(), Dongle already registered\n");
+		MESSAGE("%s: Dongle already registered\n", __FUNCTION__);
                 return 0;
         }
-	
+
 	/* Insert IrDA dongle into hashbin */
 	hashbin_insert(dongles, (irda_queue_t *) new, new->type, NULL);
-	
+
         return 0;
 }
 
@@ -561,7 +553,7 @@
 
 	node = hashbin_remove(dongles, dongle->type, NULL);
 	if (!node) {
-		ERROR(__FUNCTION__ "(), dongle not found!\n");
+		ERROR("%s: dongle not found!\n", __FUNCTION__);
 		return;
 	}
 }
@@ -574,22 +566,22 @@
  *    driver to find out which modes it support.
  */
 int irda_device_set_mode(struct net_device* dev, int mode)
-{	
+{
 	struct if_irda_req req;
 	int ret;
 
 	IRDA_DEBUG(0, __FUNCTION__ "()\n");
 
 	if (!dev->do_ioctl) {
-		ERROR(__FUNCTION__ "(), set_raw_mode not impl. by "
-		      "device driver\n");
+		ERROR("%s: set_raw_mode not impl. by device driver\n",
+				__FUNCTION__);
 		return -1;
 	}
-	
+
 	req.ifr_mode = mode;
 
 	ret = dev->do_ioctl(dev, (struct ifreq *) &req, SIOCSMODE);
-	
+
 	return ret;
 }
 
@@ -602,9 +594,9 @@
 void setup_dma(int channel, char *buffer, int count, int mode)
 {
 	unsigned long flags;
-	
+
 	flags = claim_dma_lock();
-	
+
 	disable_dma(channel);
 	clear_dma_ff(channel);
 	set_dma_mode(channel, mode);

  parent reply	other threads:[~2002-06-10 12:37 UTC|newest]

Thread overview: 99+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-09  5:42 Linux 2.5.21 Linus Torvalds
2002-06-09  7:10 ` 2.5.21 -- suspend.h:58: parse error before "__nosavedata" Miles Lane
2002-06-09  8:40   ` Skip Ford
2002-06-09 13:37 ` [PATCH] 2.5.20 IDE 86 Martin Dalecki
2002-06-09 13:39 ` [PATCH] 2.5.20 locks.h Martin Dalecki
2002-06-10 11:19 ` [PATCH] 2.5.21 "I can't get no compilation" Martin Dalecki
2002-06-10 12:32   ` Anton Altaparmakov
2002-06-10 11:54     ` Martin Dalecki
2002-06-10 13:08       ` Anton Altaparmakov
2002-06-10 11:21 ` [PATCH] 2.5.21 kill warnings 1/19 Martin Dalecki
2002-06-10 11:23 ` [PATCH] 2.5.21 kill warnings 2/19 Martin Dalecki
2002-06-10 11:24 ` [PATCH] 2.5.21 kill warnings 3/19 Martin Dalecki
2002-06-10 11:26 ` [PATCH] 2.5.21 kill warnings 4/19 Martin Dalecki
2002-06-10 18:46   ` Maksim (Max) Krasnyanskiy
2002-06-10 18:57     ` Thomas 'Dent' Mirlacher
2002-06-10 19:08       ` Roland Dreier
2002-06-10 19:14         ` Thomas 'Dent' Mirlacher
2002-06-10 19:19       ` Tom Rini
2002-06-10 19:30         ` Andrew Morton
2002-06-10 19:44           ` Tom Rini
2002-06-10 19:51             ` Andrew Morton
2002-06-10 20:03               ` Thunder from the hill
2002-06-10 20:08                 ` Tom Rini
2002-06-10 20:14                   ` Andrew Morton
2002-06-10 21:01                   ` Maksim (Max) Krasnyanskiy
2002-06-10 21:11                     ` Tom Rini
2002-06-10 21:34                       ` Thunder from the hill
2002-06-10 20:10                 ` Thunder from the hill
2002-06-10 20:15                   ` Tom Rini
2002-06-10 20:05               ` Tom Rini
2002-06-10 20:18                 ` Thomas 'Dent' Mirlacher
2002-06-10 19:46           ` Thunder from the hill
2002-06-10 20:00             ` Andrew Morton
2002-06-11  6:12           ` Martin Dalecki
2002-06-10 21:51     ` Neil Booth
2002-06-10 22:42       ` Maksim (Max) Krasnyanskiy
2002-06-11  6:10     ` Martin Dalecki
2002-06-13 12:01     ` Martin Dalecki
2002-06-11  0:40   ` Greg KH
2002-06-11  6:33     ` Martin Dalecki
2002-06-11  6:38       ` Greg KH
2002-06-11  8:26       ` Russell King
2002-06-11  8:34         ` Martin Dalecki
2002-06-11  9:06           ` Russell King
2002-06-11  9:09             ` Martin Dalecki
2002-06-11  9:28               ` Russell King
2002-06-11  9:42                 ` Martin Dalecki
2002-06-11 10:36                   ` Russell King
2002-06-11 11:06   ` Pavel Machek
2002-06-10 11:28 ` [PATCH] 2.5.21 kill warnings 5/19 Martin Dalecki
2002-06-10 22:24   ` William Lee Irwin III
2002-06-10 22:35     ` Russell King
2002-06-11  0:38   ` Greg KH
2002-06-10 11:35 ` [PATCH] 2.5.21 kill warnings 6/19 Martin Dalecki
2002-06-16 11:05   ` Adrian Bunk
2002-06-10 11:37 ` [PATCH] 2.5.21 kill warnings 7/19 Martin Dalecki
2002-06-10 11:38 ` Martin Dalecki [this message]
2002-06-10 11:39 ` [PATCH] 2.5.21 kill warnings 9/19 Martin Dalecki
2002-06-10 11:40 ` [PATCH] 2.5.21 kill warnings 10/19 Martin Dalecki
2002-06-10 11:42 ` [PATCH] 2.5.21 kill warnings 11/19 Martin Dalecki
2002-06-10 11:43 ` [PATCH] 2.5.21 kill warnings 12/19 Martin Dalecki
2002-06-10 11:44 ` [PATCH] 2.5.21 kill warnings 13/19 Martin Dalecki
2002-06-10 11:45 ` [PATCH] 2.5.21 kill warinigs 14/19 Martin Dalecki
2002-06-10 18:47   ` Ingo Oeser
2002-06-11  8:07     ` Martin Dalecki
2002-06-11 11:59     ` Dave Jones
2002-06-10 11:46 ` [PATCH] 2.5.21 kill warnings 15/19 Martin Dalecki
2002-06-10 11:48 ` [PATCH] 2.5.21 kill warnings 16/19 Martin Dalecki
2002-06-10 11:49 ` [PATCH] 2.5.21 kill warnings 17/19 Martin Dalecki
2002-06-10 11:49 ` [PATCH] 2.5.21 kill warnings 18/19 Martin Dalecki
2002-06-10 11:50 ` [PATCH] 2.5.21 kill warnings 19/19 Martin Dalecki
2002-06-10 11:59 ` [REVERT] 2.5.21 s390/block/xpram.c Martin Dalecki
2002-06-11  7:46 ` [PATCH] 2.5.21 IDE 87 Martin Dalecki
2002-06-11 19:02   ` John Weber
2002-06-12  7:00     ` Martin Dalecki
2002-06-13  1:25       ` John Weber
2002-06-12 17:39   ` Brad Heilbrun
2002-06-12 10:50 ` [PATCH] 2.5.21 inline abuse Martin Dalecki
2002-06-13 12:45   ` Richard Zidlicky
2002-06-13  9:51 ` [PATCH] 2.5.21 IDE 88 Martin Dalecki
2002-06-14 11:06 ` [PATCH] 2.5.21 IDE 89 Martin Dalecki
2002-06-14 11:08 ` [PATCH] 2.5.21 IDE 90 Martin Dalecki
2002-06-14 14:02 ` [PATCH] 2.5.21 IDE 91 Martin Dalecki
2002-06-14 15:17   ` Jens Axboe
2002-06-14 15:42     ` John Weber
2002-06-14 15:43     ` Dave Jones
2002-06-14 16:06       ` Bartlomiej Zolnierkiewicz
2002-06-14 16:33         ` Martin Dalecki
2002-06-14 17:56       ` Linus Torvalds
2002-06-14 15:56     ` Benjamin LaHaise
2002-06-14 16:04       ` Dave Jones
2002-06-14 17:23         ` Martin Dalecki
2002-06-14 16:09       ` Bartlomiej Zolnierkiewicz
2002-06-14 16:15     ` Martin Dalecki
2002-06-15  8:15       ` Jens Axboe
2002-06-14 16:43     ` Linus Torvalds
2002-06-14 16:47       ` Martin Dalecki
2002-06-15  8:19       ` Jens Axboe
2002-06-16 18:36 ` [PATCH] 2.5.21 ide 92 Martin Dalecki

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=3D048FBA.9010900@evision-ventures.com \
    --to=dalecki@evision-ventures.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.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