aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wavelan_cs.p.h
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2008-03-31 20:56:32 -0400
committerJohn W. Linville <linville@tuxdriver.com>2008-04-08 15:05:57 -0400
commit2aee82de5238625a7664f88d6ebff9de467bb685 (patch)
tree9ec1c7dd8e9897db39ea20094d580f7245e6e047 /drivers/net/wireless/wavelan_cs.p.h
parent7b463ced635231dd1d4ca6d8b1d93f9353b9dc3a (diff)
wavelan_cs: stop inlining largish static functions
Hi John, Can you please take a look at this patch? drivers/net/wireless/wavelan_cs.c has unusually large number of static inline functions - 27. I looked through them and 20 of them do not seem to warrant inlining. Some are really big; others call mdelay(1) or busy-wait for a bit to be set in a hardware register - it's pointless to optimize such functions for speed. This patch removes "inline" from these static function (regardless of number of callsites - gcc nowadays auto-inlines statics with one callsite). Size difference for 32bit x86: text data bss dec hex filename 17020 372 8 17400 43f8 linux-2.6-ALLYES/drivers/net/wireless/wavelan_cs.o 14032 356 8 14396 383c linux-2.6.inline-ALLYES/drivers/net/wireless/wavelan_cs.o Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> -- vda Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wavelan_cs.p.h')
-rw-r--r--drivers/net/wireless/wavelan_cs.p.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/drivers/net/wireless/wavelan_cs.p.h b/drivers/net/wireless/wavelan_cs.p.h
index 33dd97094227..628192d7248f 100644
--- a/drivers/net/wireless/wavelan_cs.p.h
+++ b/drivers/net/wireless/wavelan_cs.p.h
@@ -637,7 +637,7 @@ struct net_local
637/* ----------------- MODEM MANAGEMENT SUBROUTINES ----------------- */ 637/* ----------------- MODEM MANAGEMENT SUBROUTINES ----------------- */
638static inline u_char /* data */ 638static inline u_char /* data */
639 hasr_read(u_long); /* Read the host interface : base address */ 639 hasr_read(u_long); /* Read the host interface : base address */
640static inline void 640static void
641 hacr_write(u_long, /* Write to host interface : base address */ 641 hacr_write(u_long, /* Write to host interface : base address */
642 u_char), /* data */ 642 u_char), /* data */
643 hacr_write_slow(u_long, 643 hacr_write_slow(u_long,
@@ -651,7 +651,7 @@ static void
651 int, /* Offset in psa */ 651 int, /* Offset in psa */
652 u_char *, /* Buffer in memory */ 652 u_char *, /* Buffer in memory */
653 int); /* Length of buffer */ 653 int); /* Length of buffer */
654static inline void 654static void
655 mmc_out(u_long, /* Write 1 byte to the Modem Manag Control */ 655 mmc_out(u_long, /* Write 1 byte to the Modem Manag Control */
656 u_short, 656 u_short,
657 u_char), 657 u_char),
@@ -659,10 +659,10 @@ static inline void
659 u_char, 659 u_char,
660 u_char *, 660 u_char *,
661 int); 661 int);
662static inline u_char /* Read 1 byte from the MMC */ 662static u_char /* Read 1 byte from the MMC */
663 mmc_in(u_long, 663 mmc_in(u_long,
664 u_short); 664 u_short);
665static inline void 665static void
666 mmc_read(u_long, /* Read n bytes from the MMC */ 666 mmc_read(u_long, /* Read n bytes from the MMC */
667 u_char, 667 u_char,
668 u_char *, 668 u_char *,
@@ -688,10 +688,10 @@ static int
688 int, 688 int,
689 char *, 689 char *,
690 int); 690 int);
691static inline void 691static void
692 wv_82593_reconfig(struct net_device *); /* Reconfigure the controller */ 692 wv_82593_reconfig(struct net_device *); /* Reconfigure the controller */
693/* ------------------- DEBUG & INFO SUBROUTINES ------------------- */ 693/* ------------------- DEBUG & INFO SUBROUTINES ------------------- */
694static inline void 694static void
695 wv_init_info(struct net_device *); /* display startup info */ 695 wv_init_info(struct net_device *); /* display startup info */
696/* ------------------- IOCTL, STATS & RECONFIG ------------------- */ 696/* ------------------- IOCTL, STATS & RECONFIG ------------------- */
697static en_stats * 697static en_stats *
@@ -699,17 +699,17 @@ static en_stats *
699static iw_stats * 699static iw_stats *
700 wavelan_get_wireless_stats(struct net_device *); 700 wavelan_get_wireless_stats(struct net_device *);
701/* ----------------------- PACKET RECEPTION ----------------------- */ 701/* ----------------------- PACKET RECEPTION ----------------------- */
702static inline int 702static int
703 wv_start_of_frame(struct net_device *, /* Seek beggining of current frame */ 703 wv_start_of_frame(struct net_device *, /* Seek beggining of current frame */
704 int, /* end of frame */ 704 int, /* end of frame */
705 int); /* start of buffer */ 705 int); /* start of buffer */
706static inline void 706static void
707 wv_packet_read(struct net_device *, /* Read a packet from a frame */ 707 wv_packet_read(struct net_device *, /* Read a packet from a frame */
708 int, 708 int,
709 int), 709 int),
710 wv_packet_rcv(struct net_device *); /* Read all packets waiting */ 710 wv_packet_rcv(struct net_device *); /* Read all packets waiting */
711/* --------------------- PACKET TRANSMISSION --------------------- */ 711/* --------------------- PACKET TRANSMISSION --------------------- */
712static inline void 712static void
713 wv_packet_write(struct net_device *, /* Write a packet to the Tx buffer */ 713 wv_packet_write(struct net_device *, /* Write a packet to the Tx buffer */
714 void *, 714 void *,
715 short); 715 short);
@@ -717,20 +717,20 @@ static int
717 wavelan_packet_xmit(struct sk_buff *, /* Send a packet */ 717 wavelan_packet_xmit(struct sk_buff *, /* Send a packet */
718 struct net_device *); 718 struct net_device *);
719/* -------------------- HARDWARE CONFIGURATION -------------------- */ 719/* -------------------- HARDWARE CONFIGURATION -------------------- */
720static inline int 720static int
721 wv_mmc_init(struct net_device *); /* Initialize the modem */ 721 wv_mmc_init(struct net_device *); /* Initialize the modem */
722static int 722static int
723 wv_ru_stop(struct net_device *), /* Stop the i82593 receiver unit */ 723 wv_ru_stop(struct net_device *), /* Stop the i82593 receiver unit */
724 wv_ru_start(struct net_device *); /* Start the i82593 receiver unit */ 724 wv_ru_start(struct net_device *); /* Start the i82593 receiver unit */
725static int 725static int
726 wv_82593_config(struct net_device *); /* Configure the i82593 */ 726 wv_82593_config(struct net_device *); /* Configure the i82593 */
727static inline int 727static int
728 wv_pcmcia_reset(struct net_device *); /* Reset the pcmcia interface */ 728 wv_pcmcia_reset(struct net_device *); /* Reset the pcmcia interface */
729static int 729static int
730 wv_hw_config(struct net_device *); /* Reset & configure the whole hardware */ 730 wv_hw_config(struct net_device *); /* Reset & configure the whole hardware */
731static inline void 731static void
732 wv_hw_reset(struct net_device *); /* Same, + start receiver unit */ 732 wv_hw_reset(struct net_device *); /* Same, + start receiver unit */
733static inline int 733static int
734 wv_pcmcia_config(struct pcmcia_device *); /* Configure the pcmcia interface */ 734 wv_pcmcia_config(struct pcmcia_device *); /* Configure the pcmcia interface */
735static void 735static void
736 wv_pcmcia_release(struct pcmcia_device *);/* Remove a device */ 736 wv_pcmcia_release(struct pcmcia_device *);/* Remove a device */