aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/irda/sa1100_ir.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/irda/sa1100_ir.c')
-rw-r--r--drivers/net/irda/sa1100_ir.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/drivers/net/irda/sa1100_ir.c b/drivers/net/irda/sa1100_ir.c
index aa6fef8ff130..ccde5829ba21 100644
--- a/drivers/net/irda/sa1100_ir.c
+++ b/drivers/net/irda/sa1100_ir.c
@@ -298,7 +298,7 @@ static int sa1100_irda_suspend(struct platform_device *pdev, pm_message_t state)
298 if (!dev) 298 if (!dev)
299 return 0; 299 return 0;
300 300
301 si = dev->priv; 301 si = netdev_priv(dev);
302 if (si->open) { 302 if (si->open) {
303 /* 303 /*
304 * Stop the transmit queue 304 * Stop the transmit queue
@@ -323,7 +323,7 @@ static int sa1100_irda_resume(struct platform_device *pdev)
323 if (!dev) 323 if (!dev)
324 return 0; 324 return 0;
325 325
326 si = dev->priv; 326 si = netdev_priv(dev);
327 if (si->open) { 327 if (si->open) {
328 /* 328 /*
329 * If we missed a speed change, initialise at the new speed 329 * If we missed a speed change, initialise at the new speed
@@ -359,7 +359,7 @@ static int sa1100_irda_resume(struct platform_device *pdev)
359 */ 359 */
360static void sa1100_irda_hpsir_irq(struct net_device *dev) 360static void sa1100_irda_hpsir_irq(struct net_device *dev)
361{ 361{
362 struct sa1100_irda *si = dev->priv; 362 struct sa1100_irda *si = netdev_priv(dev);
363 int status; 363 int status;
364 364
365 status = Ser2UTSR0; 365 status = Ser2UTSR0;
@@ -532,7 +532,7 @@ static void sa1100_irda_fir_error(struct sa1100_irda *si, struct net_device *dev
532 */ 532 */
533static void sa1100_irda_fir_irq(struct net_device *dev) 533static void sa1100_irda_fir_irq(struct net_device *dev)
534{ 534{
535 struct sa1100_irda *si = dev->priv; 535 struct sa1100_irda *si = netdev_priv(dev);
536 536
537 /* 537 /*
538 * Stop RX DMA 538 * Stop RX DMA
@@ -580,7 +580,7 @@ static void sa1100_irda_fir_irq(struct net_device *dev)
580static irqreturn_t sa1100_irda_irq(int irq, void *dev_id) 580static irqreturn_t sa1100_irda_irq(int irq, void *dev_id)
581{ 581{
582 struct net_device *dev = dev_id; 582 struct net_device *dev = dev_id;
583 if (IS_FIR(((struct sa1100_irda *)dev->priv))) 583 if (IS_FIR(((struct sa1100_irda *)netdev_priv(dev))))
584 sa1100_irda_fir_irq(dev); 584 sa1100_irda_fir_irq(dev);
585 else 585 else
586 sa1100_irda_hpsir_irq(dev); 586 sa1100_irda_hpsir_irq(dev);
@@ -593,7 +593,7 @@ static irqreturn_t sa1100_irda_irq(int irq, void *dev_id)
593static void sa1100_irda_txdma_irq(void *id) 593static void sa1100_irda_txdma_irq(void *id)
594{ 594{
595 struct net_device *dev = id; 595 struct net_device *dev = id;
596 struct sa1100_irda *si = dev->priv; 596 struct sa1100_irda *si = netdev_priv(dev);
597 struct sk_buff *skb = si->txskb; 597 struct sk_buff *skb = si->txskb;
598 598
599 si->txskb = NULL; 599 si->txskb = NULL;
@@ -647,7 +647,7 @@ static void sa1100_irda_txdma_irq(void *id)
647 647
648static int sa1100_irda_hard_xmit(struct sk_buff *skb, struct net_device *dev) 648static int sa1100_irda_hard_xmit(struct sk_buff *skb, struct net_device *dev)
649{ 649{
650 struct sa1100_irda *si = dev->priv; 650 struct sa1100_irda *si = netdev_priv(dev);
651 int speed = irda_get_next_speed(skb); 651 int speed = irda_get_next_speed(skb);
652 652
653 /* 653 /*
@@ -722,7 +722,7 @@ static int
722sa1100_irda_ioctl(struct net_device *dev, struct ifreq *ifreq, int cmd) 722sa1100_irda_ioctl(struct net_device *dev, struct ifreq *ifreq, int cmd)
723{ 723{
724 struct if_irda_req *rq = (struct if_irda_req *)ifreq; 724 struct if_irda_req *rq = (struct if_irda_req *)ifreq;
725 struct sa1100_irda *si = dev->priv; 725 struct sa1100_irda *si = netdev_priv(dev);
726 int ret = -EOPNOTSUPP; 726 int ret = -EOPNOTSUPP;
727 727
728 switch (cmd) { 728 switch (cmd) {
@@ -764,13 +764,13 @@ sa1100_irda_ioctl(struct net_device *dev, struct ifreq *ifreq, int cmd)
764 764
765static struct net_device_stats *sa1100_irda_stats(struct net_device *dev) 765static struct net_device_stats *sa1100_irda_stats(struct net_device *dev)
766{ 766{
767 struct sa1100_irda *si = dev->priv; 767 struct sa1100_irda *si = netdev_priv(dev);
768 return &si->stats; 768 return &si->stats;
769} 769}
770 770
771static int sa1100_irda_start(struct net_device *dev) 771static int sa1100_irda_start(struct net_device *dev)
772{ 772{
773 struct sa1100_irda *si = dev->priv; 773 struct sa1100_irda *si = netdev_priv(dev);
774 int err; 774 int err;
775 775
776 si->speed = 9600; 776 si->speed = 9600;
@@ -833,7 +833,7 @@ err_irq:
833 833
834static int sa1100_irda_stop(struct net_device *dev) 834static int sa1100_irda_stop(struct net_device *dev)
835{ 835{
836 struct sa1100_irda *si = dev->priv; 836 struct sa1100_irda *si = netdev_priv(dev);
837 837
838 disable_irq(dev->irq); 838 disable_irq(dev->irq);
839 sa1100_irda_shutdown(si); 839 sa1100_irda_shutdown(si);
@@ -906,7 +906,7 @@ static int sa1100_irda_probe(struct platform_device *pdev)
906 if (!dev) 906 if (!dev)
907 goto err_mem_4; 907 goto err_mem_4;
908 908
909 si = dev->priv; 909 si = netdev_priv(dev);
910 si->dev = &pdev->dev; 910 si->dev = &pdev->dev;
911 si->pdata = pdev->dev.platform_data; 911 si->pdata = pdev->dev.platform_data;
912 912
@@ -985,7 +985,7 @@ static int sa1100_irda_remove(struct platform_device *pdev)
985 struct net_device *dev = platform_get_drvdata(pdev); 985 struct net_device *dev = platform_get_drvdata(pdev);
986 986
987 if (dev) { 987 if (dev) {
988 struct sa1100_irda *si = dev->priv; 988 struct sa1100_irda *si = netdev_priv(dev);
989 unregister_netdev(dev); 989 unregister_netdev(dev);
990 kfree(si->tx_buff.head); 990 kfree(si->tx_buff.head);
991 kfree(si->rx_buff.head); 991 kfree(si->rx_buff.head);