aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda/donauboe.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/irda/donauboe.c')
-rw-r--r--drivers/net/irda/donauboe.c68
1 files changed, 34 insertions, 34 deletions
diff --git a/drivers/net/irda/donauboe.c b/drivers/net/irda/donauboe.c
index 34ad189fff67..69d16b30323b 100644
--- a/drivers/net/irda/donauboe.c
+++ b/drivers/net/irda/donauboe.c
@@ -245,7 +245,7 @@ toshoboe_dumpregs (struct toshoboe_cb *self)
245{ 245{
246 __u32 ringbase; 246 __u32 ringbase;
247 247
248 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 248 IRDA_DEBUG (4, "%s()\n", __func__);
249 249
250 ringbase = INB (OBOE_RING_BASE0) << 10; 250 ringbase = INB (OBOE_RING_BASE0) << 10;
251 ringbase |= INB (OBOE_RING_BASE1) << 18; 251 ringbase |= INB (OBOE_RING_BASE1) << 18;
@@ -293,7 +293,7 @@ static void
293toshoboe_disablebm (struct toshoboe_cb *self) 293toshoboe_disablebm (struct toshoboe_cb *self)
294{ 294{
295 __u8 command; 295 __u8 command;
296 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 296 IRDA_DEBUG (4, "%s()\n", __func__);
297 297
298 pci_read_config_byte (self->pdev, PCI_COMMAND, &command); 298 pci_read_config_byte (self->pdev, PCI_COMMAND, &command);
299 command &= ~PCI_COMMAND_MASTER; 299 command &= ~PCI_COMMAND_MASTER;
@@ -305,7 +305,7 @@ toshoboe_disablebm (struct toshoboe_cb *self)
305static void 305static void
306toshoboe_stopchip (struct toshoboe_cb *self) 306toshoboe_stopchip (struct toshoboe_cb *self)
307{ 307{
308 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 308 IRDA_DEBUG (4, "%s()\n", __func__);
309 309
310 /*Disable interrupts */ 310 /*Disable interrupts */
311 OUTB (0x0, OBOE_IER); 311 OUTB (0x0, OBOE_IER);
@@ -350,7 +350,7 @@ toshoboe_setbaud (struct toshoboe_cb *self)
350 __u16 pconfig = 0; 350 __u16 pconfig = 0;
351 __u8 config0l = 0; 351 __u8 config0l = 0;
352 352
353 IRDA_DEBUG (2, "%s(%d/%d)\n", __FUNCTION__, self->speed, self->io.speed); 353 IRDA_DEBUG (2, "%s(%d/%d)\n", __func__, self->speed, self->io.speed);
354 354
355 switch (self->speed) 355 switch (self->speed)
356 { 356 {
@@ -482,7 +482,7 @@ toshoboe_setbaud (struct toshoboe_cb *self)
482static void 482static void
483toshoboe_enablebm (struct toshoboe_cb *self) 483toshoboe_enablebm (struct toshoboe_cb *self)
484{ 484{
485 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 485 IRDA_DEBUG (4, "%s()\n", __func__);
486 pci_set_master (self->pdev); 486 pci_set_master (self->pdev);
487} 487}
488 488
@@ -492,7 +492,7 @@ toshoboe_initring (struct toshoboe_cb *self)
492{ 492{
493 int i; 493 int i;
494 494
495 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 495 IRDA_DEBUG (4, "%s()\n", __func__);
496 496
497 for (i = 0; i < TX_SLOTS; ++i) 497 for (i = 0; i < TX_SLOTS; ++i)
498 { 498 {
@@ -550,7 +550,7 @@ toshoboe_startchip (struct toshoboe_cb *self)
550{ 550{
551 __u32 physaddr; 551 __u32 physaddr;
552 552
553 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 553 IRDA_DEBUG (4, "%s()\n", __func__);
554 554
555 toshoboe_initring (self); 555 toshoboe_initring (self);
556 toshoboe_enablebm (self); 556 toshoboe_enablebm (self);
@@ -824,7 +824,7 @@ toshoboe_probe (struct toshoboe_cb *self)
824#endif 824#endif
825 unsigned long flags; 825 unsigned long flags;
826 826
827 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 827 IRDA_DEBUG (4, "%s()\n", __func__);
828 828
829 if (request_irq (self->io.irq, toshoboe_probeinterrupt, 829 if (request_irq (self->io.irq, toshoboe_probeinterrupt,
830 self->io.irqflags, "toshoboe", (void *) self)) 830 self->io.irqflags, "toshoboe", (void *) self))
@@ -983,10 +983,10 @@ toshoboe_hard_xmit (struct sk_buff *skb, struct net_device *dev)
983 983
984 IRDA_ASSERT (self != NULL, return 0; ); 984 IRDA_ASSERT (self != NULL, return 0; );
985 985
986 IRDA_DEBUG (1, "%s.tx:%x(%x)%x\n", __FUNCTION__ 986 IRDA_DEBUG (1, "%s.tx:%x(%x)%x\n", __func__
987 ,skb->len,self->txpending,INB (OBOE_ENABLEH)); 987 ,skb->len,self->txpending,INB (OBOE_ENABLEH));
988 if (!cb->magic) { 988 if (!cb->magic) {
989 IRDA_DEBUG (2, "%s.Not IrLAP:%x\n", __FUNCTION__, cb->magic); 989 IRDA_DEBUG (2, "%s.Not IrLAP:%x\n", __func__, cb->magic);
990#ifdef DUMP_PACKETS 990#ifdef DUMP_PACKETS
991 _dumpbufs(skb->data,skb->len,'>'); 991 _dumpbufs(skb->data,skb->len,'>');
992#endif 992#endif
@@ -1015,7 +1015,7 @@ toshoboe_hard_xmit (struct sk_buff *skb, struct net_device *dev)
1015 { 1015 {
1016 self->new_speed = speed; 1016 self->new_speed = speed;
1017 IRDA_DEBUG (1, "%s: Queued TxDone scheduled speed change %d\n" , 1017 IRDA_DEBUG (1, "%s: Queued TxDone scheduled speed change %d\n" ,
1018 __FUNCTION__, speed); 1018 __func__, speed);
1019 /* if no data, that's all! */ 1019 /* if no data, that's all! */
1020 if (!skb->len) 1020 if (!skb->len)
1021 { 1021 {
@@ -1057,7 +1057,7 @@ toshoboe_hard_xmit (struct sk_buff *skb, struct net_device *dev)
1057 /* which we will add a wrong checksum to */ 1057 /* which we will add a wrong checksum to */
1058 1058
1059 mtt = toshoboe_makemttpacket (self, self->tx_bufs[self->txs], mtt); 1059 mtt = toshoboe_makemttpacket (self, self->tx_bufs[self->txs], mtt);
1060 IRDA_DEBUG (1, "%s.mtt:%x(%x)%d\n", __FUNCTION__ 1060 IRDA_DEBUG (1, "%s.mtt:%x(%x)%d\n", __func__
1061 ,skb->len,mtt,self->txpending); 1061 ,skb->len,mtt,self->txpending);
1062 if (mtt) 1062 if (mtt)
1063 { 1063 {
@@ -1101,7 +1101,7 @@ dumpbufs(skb->data,skb->len,'>');
1101 1101
1102 if (self->ring->tx[self->txs].control & OBOE_CTL_TX_HW_OWNS) 1102 if (self->ring->tx[self->txs].control & OBOE_CTL_TX_HW_OWNS)
1103 { 1103 {
1104 IRDA_DEBUG (0, "%s.ful:%x(%x)%x\n", __FUNCTION__ 1104 IRDA_DEBUG (0, "%s.ful:%x(%x)%x\n", __func__
1105 ,skb->len, self->ring->tx[self->txs].control, self->txpending); 1105 ,skb->len, self->ring->tx[self->txs].control, self->txpending);
1106 toshoboe_start_DMA(self, OBOE_CONFIG0H_ENTX); 1106 toshoboe_start_DMA(self, OBOE_CONFIG0H_ENTX);
1107 spin_unlock_irqrestore(&self->spinlock, flags); 1107 spin_unlock_irqrestore(&self->spinlock, flags);
@@ -1179,7 +1179,7 @@ toshoboe_interrupt (int irq, void *dev_id)
1179 if (self->ring->tx[i].control & OBOE_CTL_TX_HW_OWNS) 1179 if (self->ring->tx[i].control & OBOE_CTL_TX_HW_OWNS)
1180 self->txpending++; 1180 self->txpending++;
1181 } 1181 }
1182 IRDA_DEBUG (1, "%s.txd(%x)%x/%x\n", __FUNCTION__ 1182 IRDA_DEBUG (1, "%s.txd(%x)%x/%x\n", __func__
1183 ,irqstat,txp,self->txpending); 1183 ,irqstat,txp,self->txpending);
1184 1184
1185 txp = INB (OBOE_TXSLOT) & OBOE_SLOT_MASK; 1185 txp = INB (OBOE_TXSLOT) & OBOE_SLOT_MASK;
@@ -1209,7 +1209,7 @@ toshoboe_interrupt (int irq, void *dev_id)
1209 { 1209 {
1210 self->speed = self->new_speed; 1210 self->speed = self->new_speed;
1211 IRDA_DEBUG (1, "%s: Executed TxDone scheduled speed change %d\n", 1211 IRDA_DEBUG (1, "%s: Executed TxDone scheduled speed change %d\n",
1212 __FUNCTION__, self->speed); 1212 __func__, self->speed);
1213 toshoboe_setbaud (self); 1213 toshoboe_setbaud (self);
1214 } 1214 }
1215 1215
@@ -1224,7 +1224,7 @@ toshoboe_interrupt (int irq, void *dev_id)
1224 { 1224 {
1225 int len = self->ring->rx[self->rxs].len; 1225 int len = self->ring->rx[self->rxs].len;
1226 skb = NULL; 1226 skb = NULL;
1227 IRDA_DEBUG (3, "%s.rcv:%x(%x)\n", __FUNCTION__ 1227 IRDA_DEBUG (3, "%s.rcv:%x(%x)\n", __func__
1228 ,len,self->ring->rx[self->rxs].control); 1228 ,len,self->ring->rx[self->rxs].control);
1229 1229
1230#ifdef DUMP_PACKETS 1230#ifdef DUMP_PACKETS
@@ -1246,7 +1246,7 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1246 len -= 2; 1246 len -= 2;
1247 else 1247 else
1248 len = 0; 1248 len = 0;
1249 IRDA_DEBUG (1, "%s.SIR:%x(%x)\n", __FUNCTION__, len,enable); 1249 IRDA_DEBUG (1, "%s.SIR:%x(%x)\n", __func__, len,enable);
1250 } 1250 }
1251 1251
1252#ifdef USE_MIR 1252#ifdef USE_MIR
@@ -1256,7 +1256,7 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1256 len -= 2; 1256 len -= 2;
1257 else 1257 else
1258 len = 0; 1258 len = 0;
1259 IRDA_DEBUG (2, "%s.MIR:%x(%x)\n", __FUNCTION__, len,enable); 1259 IRDA_DEBUG (2, "%s.MIR:%x(%x)\n", __func__, len,enable);
1260 } 1260 }
1261#endif 1261#endif
1262 else if (enable & OBOE_ENABLEH_FIRON) 1262 else if (enable & OBOE_ENABLEH_FIRON)
@@ -1265,10 +1265,10 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1265 len -= 4; /*FIXME: check this */ 1265 len -= 4; /*FIXME: check this */
1266 else 1266 else
1267 len = 0; 1267 len = 0;
1268 IRDA_DEBUG (1, "%s.FIR:%x(%x)\n", __FUNCTION__, len,enable); 1268 IRDA_DEBUG (1, "%s.FIR:%x(%x)\n", __func__, len,enable);
1269 } 1269 }
1270 else 1270 else
1271 IRDA_DEBUG (0, "%s.?IR:%x(%x)\n", __FUNCTION__, len,enable); 1271 IRDA_DEBUG (0, "%s.?IR:%x(%x)\n", __func__, len,enable);
1272 1272
1273 if (len) 1273 if (len)
1274 { 1274 {
@@ -1289,7 +1289,7 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1289 { 1289 {
1290 printk (KERN_INFO 1290 printk (KERN_INFO
1291 "%s(), memory squeeze, dropping frame.\n", 1291 "%s(), memory squeeze, dropping frame.\n",
1292 __FUNCTION__); 1292 __func__);
1293 } 1293 }
1294 } 1294 }
1295 } 1295 }
@@ -1301,7 +1301,7 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1301 /* (SIR) data is splitted in several slots. */ 1301 /* (SIR) data is splitted in several slots. */
1302 /* we have to join all the received buffers received */ 1302 /* we have to join all the received buffers received */
1303 /*in a large buffer before checking CRC. */ 1303 /*in a large buffer before checking CRC. */
1304 IRDA_DEBUG (0, "%s.err:%x(%x)\n", __FUNCTION__ 1304 IRDA_DEBUG (0, "%s.err:%x(%x)\n", __func__
1305 ,len,self->ring->rx[self->rxs].control); 1305 ,len,self->ring->rx[self->rxs].control);
1306 } 1306 }
1307 1307
@@ -1329,7 +1329,7 @@ dumpbufs(self->rx_bufs[self->rxs],len,'<');
1329 if (irqstat & OBOE_INT_SIP) 1329 if (irqstat & OBOE_INT_SIP)
1330 { 1330 {
1331 self->int_sip++; 1331 self->int_sip++;
1332 IRDA_DEBUG (1, "%s.sip:%x(%x)%x\n", __FUNCTION__ 1332 IRDA_DEBUG (1, "%s.sip:%x(%x)%x\n", __func__
1333 ,self->int_sip,irqstat,self->txpending); 1333 ,self->int_sip,irqstat,self->txpending);
1334 } 1334 }
1335 return IRQ_HANDLED; 1335 return IRQ_HANDLED;
@@ -1343,7 +1343,7 @@ toshoboe_net_open (struct net_device *dev)
1343 unsigned long flags; 1343 unsigned long flags;
1344 int rc; 1344 int rc;
1345 1345
1346 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1346 IRDA_DEBUG (4, "%s()\n", __func__);
1347 1347
1348 self = netdev_priv(dev); 1348 self = netdev_priv(dev);
1349 1349
@@ -1381,7 +1381,7 @@ toshoboe_net_close (struct net_device *dev)
1381{ 1381{
1382 struct toshoboe_cb *self; 1382 struct toshoboe_cb *self;
1383 1383
1384 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1384 IRDA_DEBUG (4, "%s()\n", __func__);
1385 1385
1386 IRDA_ASSERT (dev != NULL, return -1; ); 1386 IRDA_ASSERT (dev != NULL, return -1; );
1387 self = (struct toshoboe_cb *) dev->priv; 1387 self = (struct toshoboe_cb *) dev->priv;
@@ -1426,7 +1426,7 @@ toshoboe_net_ioctl (struct net_device *dev, struct ifreq *rq, int cmd)
1426 1426
1427 IRDA_ASSERT (self != NULL, return -1; ); 1427 IRDA_ASSERT (self != NULL, return -1; );
1428 1428
1429 IRDA_DEBUG (5, "%s(), %s, (cmd=0x%X)\n", __FUNCTION__, dev->name, cmd); 1429 IRDA_DEBUG (5, "%s(), %s, (cmd=0x%X)\n", __func__, dev->name, cmd);
1430 1430
1431 /* Disable interrupts & save flags */ 1431 /* Disable interrupts & save flags */
1432 spin_lock_irqsave(&self->spinlock, flags); 1432 spin_lock_irqsave(&self->spinlock, flags);
@@ -1438,7 +1438,7 @@ toshoboe_net_ioctl (struct net_device *dev, struct ifreq *rq, int cmd)
1438 * speed, so we still must allow for speed change within 1438 * speed, so we still must allow for speed change within
1439 * interrupt context. 1439 * interrupt context.
1440 */ 1440 */
1441 IRDA_DEBUG (1, "%s(BANDWIDTH), %s, (%X/%ld\n", __FUNCTION__ 1441 IRDA_DEBUG (1, "%s(BANDWIDTH), %s, (%X/%ld\n", __func__
1442 ,dev->name, INB (OBOE_STATUS), irq->ifr_baudrate ); 1442 ,dev->name, INB (OBOE_STATUS), irq->ifr_baudrate );
1443 if (!in_interrupt () && !capable (CAP_NET_ADMIN)) { 1443 if (!in_interrupt () && !capable (CAP_NET_ADMIN)) {
1444 ret = -EPERM; 1444 ret = -EPERM;
@@ -1451,7 +1451,7 @@ toshoboe_net_ioctl (struct net_device *dev, struct ifreq *rq, int cmd)
1451 self->new_speed = irq->ifr_baudrate; 1451 self->new_speed = irq->ifr_baudrate;
1452 break; 1452 break;
1453 case SIOCSMEDIABUSY: /* Set media busy */ 1453 case SIOCSMEDIABUSY: /* Set media busy */
1454 IRDA_DEBUG (1, "%s(MEDIABUSY), %s, (%X/%x)\n", __FUNCTION__ 1454 IRDA_DEBUG (1, "%s(MEDIABUSY), %s, (%X/%x)\n", __func__
1455 ,dev->name, INB (OBOE_STATUS), capable (CAP_NET_ADMIN) ); 1455 ,dev->name, INB (OBOE_STATUS), capable (CAP_NET_ADMIN) );
1456 if (!capable (CAP_NET_ADMIN)) { 1456 if (!capable (CAP_NET_ADMIN)) {
1457 ret = -EPERM; 1457 ret = -EPERM;
@@ -1461,11 +1461,11 @@ toshoboe_net_ioctl (struct net_device *dev, struct ifreq *rq, int cmd)
1461 break; 1461 break;
1462 case SIOCGRECEIVING: /* Check if we are receiving right now */ 1462 case SIOCGRECEIVING: /* Check if we are receiving right now */
1463 irq->ifr_receiving = (INB (OBOE_STATUS) & OBOE_STATUS_RXBUSY) ? 1 : 0; 1463 irq->ifr_receiving = (INB (OBOE_STATUS) & OBOE_STATUS_RXBUSY) ? 1 : 0;
1464 IRDA_DEBUG (3, "%s(RECEIVING), %s, (%X/%x)\n", __FUNCTION__ 1464 IRDA_DEBUG (3, "%s(RECEIVING), %s, (%X/%x)\n", __func__
1465 ,dev->name, INB (OBOE_STATUS), irq->ifr_receiving ); 1465 ,dev->name, INB (OBOE_STATUS), irq->ifr_receiving );
1466 break; 1466 break;
1467 default: 1467 default:
1468 IRDA_DEBUG (1, "%s(?), %s, (cmd=0x%X)\n", __FUNCTION__, dev->name, cmd); 1468 IRDA_DEBUG (1, "%s(?), %s, (cmd=0x%X)\n", __func__, dev->name, cmd);
1469 ret = -EOPNOTSUPP; 1469 ret = -EOPNOTSUPP;
1470 } 1470 }
1471out: 1471out:
@@ -1492,7 +1492,7 @@ toshoboe_close (struct pci_dev *pci_dev)
1492 int i; 1492 int i;
1493 struct toshoboe_cb *self = (struct toshoboe_cb*)pci_get_drvdata(pci_dev); 1493 struct toshoboe_cb *self = (struct toshoboe_cb*)pci_get_drvdata(pci_dev);
1494 1494
1495 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1495 IRDA_DEBUG (4, "%s()\n", __func__);
1496 1496
1497 IRDA_ASSERT (self != NULL, return; ); 1497 IRDA_ASSERT (self != NULL, return; );
1498 1498
@@ -1533,7 +1533,7 @@ toshoboe_open (struct pci_dev *pci_dev, const struct pci_device_id *pdid)
1533 int ok = 0; 1533 int ok = 0;
1534 int err; 1534 int err;
1535 1535
1536 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1536 IRDA_DEBUG (4, "%s()\n", __func__);
1537 1537
1538 if ((err=pci_enable_device(pci_dev))) 1538 if ((err=pci_enable_device(pci_dev)))
1539 return err; 1539 return err;
@@ -1700,7 +1700,7 @@ toshoboe_gotosleep (struct pci_dev *pci_dev, pm_message_t crap)
1700 unsigned long flags; 1700 unsigned long flags;
1701 int i = 10; 1701 int i = 10;
1702 1702
1703 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1703 IRDA_DEBUG (4, "%s()\n", __func__);
1704 1704
1705 if (!self || self->stopped) 1705 if (!self || self->stopped)
1706 return 0; 1706 return 0;
@@ -1728,7 +1728,7 @@ toshoboe_wakeup (struct pci_dev *pci_dev)
1728 struct toshoboe_cb *self = (struct toshoboe_cb*)pci_get_drvdata(pci_dev); 1728 struct toshoboe_cb *self = (struct toshoboe_cb*)pci_get_drvdata(pci_dev);
1729 unsigned long flags; 1729 unsigned long flags;
1730 1730
1731 IRDA_DEBUG (4, "%s()\n", __FUNCTION__); 1731 IRDA_DEBUG (4, "%s()\n", __func__);
1732 1732
1733 if (!self || !self->stopped) 1733 if (!self || !self->stopped)
1734 return 0; 1734 return 0;