Commit 20f43535 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] isdn-debug-build-fix

When pr_debug() is enabled:

drivers/isdn/sc/command.c: In function 'command':
drivers/isdn/sc/command.c:107: error: 'commands' undeclared (first use in this function)
drivers/isdn/sc/command.c:107: error: (Each undeclared identifier is reported only once
drivers/isdn/sc/command.c:107: error: for each function it appears in.)
drivers/isdn/sc/command.c:122: warning: format '%x' expects type 'unsigned int', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'dial':
drivers/isdn/sc/command.c:199: warning: format '%d' expects type 'int', but argument 4 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'answer':
drivers/isdn/sc/command.c:221: warning: format '%s' expects type 'char *', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'hangup':
drivers/isdn/sc/command.c:244: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'setl2':
drivers/isdn/sc/command.c:265: error: 'l2protos' undeclared (first use in this function)
drivers/isdn/sc/command.c: In function 'setl3':
drivers/isdn/sc/command.c:297: error: 'l3protos' undeclared (first use in this function)
drivers/isdn/sc/command.c:297: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'acceptb':
drivers/isdn/sc/command.c:315: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'clreaz':
drivers/isdn/sc/command.c:330: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'
drivers/isdn/sc/command.c: In function 'seteaz':
drivers/isdn/sc/command.c:345: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'

Cc: Zach Brown <zach.brown@oracle.com>
Acked-by: default avatarKarsten Keil <kkeil@suse.de>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 42d3fb5a
...@@ -103,9 +103,6 @@ int command(isdn_ctrl *cmd) ...@@ -103,9 +103,6 @@ int command(isdn_ctrl *cmd)
return -ENODEV; return -ENODEV;
} }
pr_debug("%s: Received %s command from Link Layer\n",
sc_adapter[card]->devicename, commands[cmd->command]);
/* /*
* Dispatch the command * Dispatch the command
*/ */
...@@ -118,7 +115,7 @@ int command(isdn_ctrl *cmd) ...@@ -118,7 +115,7 @@ int command(isdn_ctrl *cmd)
memcpy(&cmdptr, cmd->parm.num, sizeof(unsigned long)); memcpy(&cmdptr, cmd->parm.num, sizeof(unsigned long));
if (copy_from_user(&ioc, (scs_ioctl __user *)cmdptr, if (copy_from_user(&ioc, (scs_ioctl __user *)cmdptr,
sizeof(scs_ioctl))) { sizeof(scs_ioctl))) {
pr_debug("%s: Failed to verify user space 0x%x\n", pr_debug("%s: Failed to verify user space 0x%lx\n",
sc_adapter[card]->devicename, cmdptr); sc_adapter[card]->devicename, cmdptr);
return -EFAULT; return -EFAULT;
} }
...@@ -195,7 +192,7 @@ static int dial(int card, unsigned long channel, setup_parm setup) ...@@ -195,7 +192,7 @@ static int dial(int card, unsigned long channel, setup_parm setup)
strlen(Phone), strlen(Phone),
(unsigned int *) Phone); (unsigned int *) Phone);
pr_debug("%s: Dialing %s on channel %d\n", pr_debug("%s: Dialing %s on channel %lu\n",
sc_adapter[card]->devicename, Phone, channel+1); sc_adapter[card]->devicename, Phone, channel+1);
return status; return status;
...@@ -217,7 +214,7 @@ static int answer(int card, unsigned long channel) ...@@ -217,7 +214,7 @@ static int answer(int card, unsigned long channel)
} }
indicate_status(card, ISDN_STAT_BCONN,channel,NULL); indicate_status(card, ISDN_STAT_BCONN,channel,NULL);
pr_debug("%s: Answered incoming call on channel %s\n", pr_debug("%s: Answered incoming call on channel %lu\n",
sc_adapter[card]->devicename, channel+1); sc_adapter[card]->devicename, channel+1);
return 0; return 0;
} }
...@@ -240,7 +237,7 @@ static int hangup(int card, unsigned long channel) ...@@ -240,7 +237,7 @@ static int hangup(int card, unsigned long channel)
(unsigned char) channel+1, (unsigned char) channel+1,
0, 0,
NULL); NULL);
pr_debug("%s: Sent HANGUP message to channel %d\n", pr_debug("%s: Sent HANGUP message to channel %lu\n",
sc_adapter[card]->devicename, channel+1); sc_adapter[card]->devicename, channel+1);
return status; return status;
} }
...@@ -260,9 +257,6 @@ static int setl2(int card, unsigned long arg) ...@@ -260,9 +257,6 @@ static int setl2(int card, unsigned long arg)
protocol = arg >> 8; protocol = arg >> 8;
channel = arg & 0xff; channel = arg & 0xff;
sc_adapter[card]->channel[channel].l2_proto = protocol; sc_adapter[card]->channel[channel].l2_proto = protocol;
pr_debug("%s: Level 2 protocol for channel %d set to %s from %d\n",
sc_adapter[card]->devicename, channel+1,
l2protos[sc_adapter[card]->channel[channel].l2_proto],protocol);
/* /*
* check that the adapter is also set to the correct protocol * check that the adapter is also set to the correct protocol
...@@ -293,8 +287,6 @@ static int setl3(int card, unsigned long channel) ...@@ -293,8 +287,6 @@ static int setl3(int card, unsigned long channel)
} }
sc_adapter[card]->channel[channel].l3_proto = protocol; sc_adapter[card]->channel[channel].l3_proto = protocol;
pr_debug("%s: Level 3 protocol for channel %d set to %s\n",
sc_adapter[card]->devicename, channel+1, l3protos[protocol]);
return 0; return 0;
} }
...@@ -311,7 +303,7 @@ static int acceptb(int card, unsigned long channel) ...@@ -311,7 +303,7 @@ static int acceptb(int card, unsigned long channel)
return -ENOBUFS; return -ENOBUFS;
} }
pr_debug("%s: B-Channel connection accepted on channel %d\n", pr_debug("%s: B-Channel connection accepted on channel %lu\n",
sc_adapter[card]->devicename, channel+1); sc_adapter[card]->devicename, channel+1);
indicate_status(card, ISDN_STAT_BCONN, channel, NULL); indicate_status(card, ISDN_STAT_BCONN, channel, NULL);
return 0; return 0;
...@@ -326,7 +318,7 @@ static int clreaz(int card, unsigned long arg) ...@@ -326,7 +318,7 @@ static int clreaz(int card, unsigned long arg)
strcpy(sc_adapter[card]->channel[arg].eazlist, ""); strcpy(sc_adapter[card]->channel[arg].eazlist, "");
sc_adapter[card]->channel[arg].eazclear = 1; sc_adapter[card]->channel[arg].eazclear = 1;
pr_debug("%s: EAZ List cleared for channel %d\n", pr_debug("%s: EAZ List cleared for channel %lu\n",
sc_adapter[card]->devicename, arg+1); sc_adapter[card]->devicename, arg+1);
return 0; return 0;
} }
...@@ -340,7 +332,7 @@ static int seteaz(int card, unsigned long arg, char *num) ...@@ -340,7 +332,7 @@ static int seteaz(int card, unsigned long arg, char *num)
strcpy(sc_adapter[card]->channel[arg].eazlist, num); strcpy(sc_adapter[card]->channel[arg].eazlist, num);
sc_adapter[card]->channel[arg].eazclear = 0; sc_adapter[card]->channel[arg].eazclear = 0;
pr_debug("%s: EAZ list for channel %d set to: %s\n", pr_debug("%s: EAZ list for channel %lu set to: %s\n",
sc_adapter[card]->devicename, arg+1, sc_adapter[card]->devicename, arg+1,
sc_adapter[card]->channel[arg].eazlist); sc_adapter[card]->channel[arg].eazlist);
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment