aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aic7xxx/aic7xxx_osm.h
diff options
context:
space:
mode:
authorHarvey Harrison <harvey.harrison@gmail.com>2009-03-04 15:06:06 -0500
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2009-04-03 11:23:16 -0400
commit1beb6fa85ca9afaee109811a3f4a984232a32a4f (patch)
tree432ecd3c15c451e4f3027811f7ab6fed8bd99f5c /drivers/scsi/aic7xxx/aic7xxx_osm.h
parent5880f486ef733dae820724a71e3b91241c7921bd (diff)
[SCSI] replace __inline with inline
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Acked-by: Jeff Garzik <jgarzik@redhat.com> Acked-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/aic7xxx/aic7xxx_osm.h')
-rw-r--r--drivers/scsi/aic7xxx/aic7xxx_osm.h104
1 files changed, 52 insertions, 52 deletions
diff --git a/drivers/scsi/aic7xxx/aic7xxx_osm.h b/drivers/scsi/aic7xxx/aic7xxx_osm.h
index 3f7238db35e5..56f07e527b48 100644
--- a/drivers/scsi/aic7xxx/aic7xxx_osm.h
+++ b/drivers/scsi/aic7xxx/aic7xxx_osm.h
@@ -230,7 +230,7 @@ int ahc_dmamap_unload(struct ahc_softc *, bus_dma_tag_t, bus_dmamap_t);
230#include "aic7xxx.h" 230#include "aic7xxx.h"
231 231
232/***************************** Timer Facilities *******************************/ 232/***************************** Timer Facilities *******************************/
233static __inline void 233static inline void
234ahc_scb_timer_reset(struct scb *scb, u_int usec) 234ahc_scb_timer_reset(struct scb *scb, u_int usec)
235{ 235{
236} 236}
@@ -401,19 +401,19 @@ struct info_str {
401/******************************** Locking *************************************/ 401/******************************** Locking *************************************/
402/* Lock protecting internal data structures */ 402/* Lock protecting internal data structures */
403 403
404static __inline void 404static inline void
405ahc_lockinit(struct ahc_softc *ahc) 405ahc_lockinit(struct ahc_softc *ahc)
406{ 406{
407 spin_lock_init(&ahc->platform_data->spin_lock); 407 spin_lock_init(&ahc->platform_data->spin_lock);
408} 408}
409 409
410static __inline void 410static inline void
411ahc_lock(struct ahc_softc *ahc, unsigned long *flags) 411ahc_lock(struct ahc_softc *ahc, unsigned long *flags)
412{ 412{
413 spin_lock_irqsave(&ahc->platform_data->spin_lock, *flags); 413 spin_lock_irqsave(&ahc->platform_data->spin_lock, *flags);
414} 414}
415 415
416static __inline void 416static inline void
417ahc_unlock(struct ahc_softc *ahc, unsigned long *flags) 417ahc_unlock(struct ahc_softc *ahc, unsigned long *flags)
418{ 418{
419 spin_unlock_irqrestore(&ahc->platform_data->spin_lock, *flags); 419 spin_unlock_irqrestore(&ahc->platform_data->spin_lock, *flags);
@@ -493,22 +493,22 @@ void ahc_pci_write_config(ahc_dev_softc_t pci,
493 int reg, uint32_t value, 493 int reg, uint32_t value,
494 int width); 494 int width);
495 495
496static __inline int ahc_get_pci_function(ahc_dev_softc_t); 496static inline int ahc_get_pci_function(ahc_dev_softc_t);
497static __inline int 497static inline int
498ahc_get_pci_function(ahc_dev_softc_t pci) 498ahc_get_pci_function(ahc_dev_softc_t pci)
499{ 499{
500 return (PCI_FUNC(pci->devfn)); 500 return (PCI_FUNC(pci->devfn));
501} 501}
502 502
503static __inline int ahc_get_pci_slot(ahc_dev_softc_t); 503static inline int ahc_get_pci_slot(ahc_dev_softc_t);
504static __inline int 504static inline int
505ahc_get_pci_slot(ahc_dev_softc_t pci) 505ahc_get_pci_slot(ahc_dev_softc_t pci)
506{ 506{
507 return (PCI_SLOT(pci->devfn)); 507 return (PCI_SLOT(pci->devfn));
508} 508}
509 509
510static __inline int ahc_get_pci_bus(ahc_dev_softc_t); 510static inline int ahc_get_pci_bus(ahc_dev_softc_t);
511static __inline int 511static inline int
512ahc_get_pci_bus(ahc_dev_softc_t pci) 512ahc_get_pci_bus(ahc_dev_softc_t pci)
513{ 513{
514 return (pci->bus->number); 514 return (pci->bus->number);
@@ -521,8 +521,8 @@ static inline void ahc_linux_pci_exit(void) {
521} 521}
522#endif 522#endif
523 523
524static __inline void ahc_flush_device_writes(struct ahc_softc *); 524static inline void ahc_flush_device_writes(struct ahc_softc *);
525static __inline void 525static inline void
526ahc_flush_device_writes(struct ahc_softc *ahc) 526ahc_flush_device_writes(struct ahc_softc *ahc)
527{ 527{
528 /* XXX Is this sufficient for all architectures??? */ 528 /* XXX Is this sufficient for all architectures??? */
@@ -535,81 +535,81 @@ int ahc_linux_proc_info(struct Scsi_Host *, char *, char **,
535 535
536/*************************** Domain Validation ********************************/ 536/*************************** Domain Validation ********************************/
537/*********************** Transaction Access Wrappers *************************/ 537/*********************** Transaction Access Wrappers *************************/
538static __inline void ahc_cmd_set_transaction_status(struct scsi_cmnd *, uint32_t); 538static inline void ahc_cmd_set_transaction_status(struct scsi_cmnd *, uint32_t);
539static __inline void ahc_set_transaction_status(struct scb *, uint32_t); 539static inline void ahc_set_transaction_status(struct scb *, uint32_t);
540static __inline void ahc_cmd_set_scsi_status(struct scsi_cmnd *, uint32_t); 540static inline void ahc_cmd_set_scsi_status(struct scsi_cmnd *, uint32_t);
541static __inline void ahc_set_scsi_status(struct scb *, uint32_t); 541static inline void ahc_set_scsi_status(struct scb *, uint32_t);
542static __inline uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd); 542static inline uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd);
543static __inline uint32_t ahc_get_transaction_status(struct scb *); 543static inline uint32_t ahc_get_transaction_status(struct scb *);
544static __inline uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd); 544static inline uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd);
545static __inline uint32_t ahc_get_scsi_status(struct scb *); 545static inline uint32_t ahc_get_scsi_status(struct scb *);
546static __inline void ahc_set_transaction_tag(struct scb *, int, u_int); 546static inline void ahc_set_transaction_tag(struct scb *, int, u_int);
547static __inline u_long ahc_get_transfer_length(struct scb *); 547static inline u_long ahc_get_transfer_length(struct scb *);
548static __inline int ahc_get_transfer_dir(struct scb *); 548static inline int ahc_get_transfer_dir(struct scb *);
549static __inline void ahc_set_residual(struct scb *, u_long); 549static inline void ahc_set_residual(struct scb *, u_long);
550static __inline void ahc_set_sense_residual(struct scb *scb, u_long resid); 550static inline void ahc_set_sense_residual(struct scb *scb, u_long resid);
551static __inline u_long ahc_get_residual(struct scb *); 551static inline u_long ahc_get_residual(struct scb *);
552static __inline u_long ahc_get_sense_residual(struct scb *); 552static inline u_long ahc_get_sense_residual(struct scb *);
553static __inline int ahc_perform_autosense(struct scb *); 553static inline int ahc_perform_autosense(struct scb *);
554static __inline uint32_t ahc_get_sense_bufsize(struct ahc_softc *, 554static inline uint32_t ahc_get_sense_bufsize(struct ahc_softc *,
555 struct scb *); 555 struct scb *);
556static __inline void ahc_notify_xfer_settings_change(struct ahc_softc *, 556static inline void ahc_notify_xfer_settings_change(struct ahc_softc *,
557 struct ahc_devinfo *); 557 struct ahc_devinfo *);
558static __inline void ahc_platform_scb_free(struct ahc_softc *ahc, 558static inline void ahc_platform_scb_free(struct ahc_softc *ahc,
559 struct scb *scb); 559 struct scb *scb);
560static __inline void ahc_freeze_scb(struct scb *scb); 560static inline void ahc_freeze_scb(struct scb *scb);
561 561
562static __inline 562static inline
563void ahc_cmd_set_transaction_status(struct scsi_cmnd *cmd, uint32_t status) 563void ahc_cmd_set_transaction_status(struct scsi_cmnd *cmd, uint32_t status)
564{ 564{
565 cmd->result &= ~(CAM_STATUS_MASK << 16); 565 cmd->result &= ~(CAM_STATUS_MASK << 16);
566 cmd->result |= status << 16; 566 cmd->result |= status << 16;
567} 567}
568 568
569static __inline 569static inline
570void ahc_set_transaction_status(struct scb *scb, uint32_t status) 570void ahc_set_transaction_status(struct scb *scb, uint32_t status)
571{ 571{
572 ahc_cmd_set_transaction_status(scb->io_ctx,status); 572 ahc_cmd_set_transaction_status(scb->io_ctx,status);
573} 573}
574 574
575static __inline 575static inline
576void ahc_cmd_set_scsi_status(struct scsi_cmnd *cmd, uint32_t status) 576void ahc_cmd_set_scsi_status(struct scsi_cmnd *cmd, uint32_t status)
577{ 577{
578 cmd->result &= ~0xFFFF; 578 cmd->result &= ~0xFFFF;
579 cmd->result |= status; 579 cmd->result |= status;
580} 580}
581 581
582static __inline 582static inline
583void ahc_set_scsi_status(struct scb *scb, uint32_t status) 583void ahc_set_scsi_status(struct scb *scb, uint32_t status)
584{ 584{
585 ahc_cmd_set_scsi_status(scb->io_ctx, status); 585 ahc_cmd_set_scsi_status(scb->io_ctx, status);
586} 586}
587 587
588static __inline 588static inline
589uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd) 589uint32_t ahc_cmd_get_transaction_status(struct scsi_cmnd *cmd)
590{ 590{
591 return ((cmd->result >> 16) & CAM_STATUS_MASK); 591 return ((cmd->result >> 16) & CAM_STATUS_MASK);
592} 592}
593 593
594static __inline 594static inline
595uint32_t ahc_get_transaction_status(struct scb *scb) 595uint32_t ahc_get_transaction_status(struct scb *scb)
596{ 596{
597 return (ahc_cmd_get_transaction_status(scb->io_ctx)); 597 return (ahc_cmd_get_transaction_status(scb->io_ctx));
598} 598}
599 599
600static __inline 600static inline
601uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd) 601uint32_t ahc_cmd_get_scsi_status(struct scsi_cmnd *cmd)
602{ 602{
603 return (cmd->result & 0xFFFF); 603 return (cmd->result & 0xFFFF);
604} 604}
605 605
606static __inline 606static inline
607uint32_t ahc_get_scsi_status(struct scb *scb) 607uint32_t ahc_get_scsi_status(struct scb *scb)
608{ 608{
609 return (ahc_cmd_get_scsi_status(scb->io_ctx)); 609 return (ahc_cmd_get_scsi_status(scb->io_ctx));
610} 610}
611 611
612static __inline 612static inline
613void ahc_set_transaction_tag(struct scb *scb, int enabled, u_int type) 613void ahc_set_transaction_tag(struct scb *scb, int enabled, u_int type)
614{ 614{
615 /* 615 /*
@@ -618,43 +618,43 @@ void ahc_set_transaction_tag(struct scb *scb, int enabled, u_int type)
618 */ 618 */
619} 619}
620 620
621static __inline 621static inline
622u_long ahc_get_transfer_length(struct scb *scb) 622u_long ahc_get_transfer_length(struct scb *scb)
623{ 623{
624 return (scb->platform_data->xfer_len); 624 return (scb->platform_data->xfer_len);
625} 625}
626 626
627static __inline 627static inline
628int ahc_get_transfer_dir(struct scb *scb) 628int ahc_get_transfer_dir(struct scb *scb)
629{ 629{
630 return (scb->io_ctx->sc_data_direction); 630 return (scb->io_ctx->sc_data_direction);
631} 631}
632 632
633static __inline 633static inline
634void ahc_set_residual(struct scb *scb, u_long resid) 634void ahc_set_residual(struct scb *scb, u_long resid)
635{ 635{
636 scsi_set_resid(scb->io_ctx, resid); 636 scsi_set_resid(scb->io_ctx, resid);
637} 637}
638 638
639static __inline 639static inline
640void ahc_set_sense_residual(struct scb *scb, u_long resid) 640void ahc_set_sense_residual(struct scb *scb, u_long resid)
641{ 641{
642 scb->platform_data->sense_resid = resid; 642 scb->platform_data->sense_resid = resid;
643} 643}
644 644
645static __inline 645static inline
646u_long ahc_get_residual(struct scb *scb) 646u_long ahc_get_residual(struct scb *scb)
647{ 647{
648 return scsi_get_resid(scb->io_ctx); 648 return scsi_get_resid(scb->io_ctx);
649} 649}
650 650
651static __inline 651static inline
652u_long ahc_get_sense_residual(struct scb *scb) 652u_long ahc_get_sense_residual(struct scb *scb)
653{ 653{
654 return (scb->platform_data->sense_resid); 654 return (scb->platform_data->sense_resid);
655} 655}
656 656
657static __inline 657static inline
658int ahc_perform_autosense(struct scb *scb) 658int ahc_perform_autosense(struct scb *scb)
659{ 659{
660 /* 660 /*
@@ -665,20 +665,20 @@ int ahc_perform_autosense(struct scb *scb)
665 return (1); 665 return (1);
666} 666}
667 667
668static __inline uint32_t 668static inline uint32_t
669ahc_get_sense_bufsize(struct ahc_softc *ahc, struct scb *scb) 669ahc_get_sense_bufsize(struct ahc_softc *ahc, struct scb *scb)
670{ 670{
671 return (sizeof(struct scsi_sense_data)); 671 return (sizeof(struct scsi_sense_data));
672} 672}
673 673
674static __inline void 674static inline void
675ahc_notify_xfer_settings_change(struct ahc_softc *ahc, 675ahc_notify_xfer_settings_change(struct ahc_softc *ahc,
676 struct ahc_devinfo *devinfo) 676 struct ahc_devinfo *devinfo)
677{ 677{
678 /* Nothing to do here for linux */ 678 /* Nothing to do here for linux */
679} 679}
680 680
681static __inline void 681static inline void
682ahc_platform_scb_free(struct ahc_softc *ahc, struct scb *scb) 682ahc_platform_scb_free(struct ahc_softc *ahc, struct scb *scb)
683{ 683{
684} 684}
@@ -687,7 +687,7 @@ int ahc_platform_alloc(struct ahc_softc *ahc, void *platform_arg);
687void ahc_platform_free(struct ahc_softc *ahc); 687void ahc_platform_free(struct ahc_softc *ahc);
688void ahc_platform_freeze_devq(struct ahc_softc *ahc, struct scb *scb); 688void ahc_platform_freeze_devq(struct ahc_softc *ahc, struct scb *scb);
689 689
690static __inline void 690static inline void
691ahc_freeze_scb(struct scb *scb) 691ahc_freeze_scb(struct scb *scb)
692{ 692{
693 if ((scb->io_ctx->result & (CAM_DEV_QFRZN << 16)) == 0) { 693 if ((scb->io_ctx->result & (CAM_DEV_QFRZN << 16)) == 0) {