aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/FlashPoint.c
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2006-03-08 03:14:23 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-03-12 10:12:32 -0500
commitd8b6b8bd8a99ee91843381d51e8e619463721aed (patch)
treea768444119807bc18ea399aa87c441f5e01aab07 /drivers/scsi/FlashPoint.c
parent85ae97d816da3f8af9dcfbc4197a2950b55c3b0d (diff)
[SCSI] drivers/scsi/FlashPoint.c: remove trivial wrappers
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/FlashPoint.c')
-rw-r--r--drivers/scsi/FlashPoint.c54
1 files changed, 19 insertions, 35 deletions
diff --git a/drivers/scsi/FlashPoint.c b/drivers/scsi/FlashPoint.c
index 38e6b71484b7..1d1e4413c8d1 100644
--- a/drivers/scsi/FlashPoint.c
+++ b/drivers/scsi/FlashPoint.c
@@ -26,25 +26,9 @@
26#undef BUSTYPE_PCI 26#undef BUSTYPE_PCI
27 27
28 28
29#define OS_InPortByte(port) inb(port)
30#define OS_InPortWord(port) inw(port)
31#define OS_InPortLong(port) inl(port)
32#define OS_OutPortByte(port, value) outb(value, port)
33#define OS_OutPortWord(port, value) outw(value, port)
34#define OS_OutPortLong(port, value) outl(value, port)
35 29
36 30
37/*
38 Define name replacements for compatibility with the Linux BusLogic Driver.
39*/
40 31
41#define SccbMgr_sense_adapter FlashPoint_ProbeHostAdapter
42#define SccbMgr_config_adapter FlashPoint_HardwareResetHostAdapter
43#define SccbMgr_unload_card FlashPoint_ReleaseHostAdapter
44#define SccbMgr_start_sccb FlashPoint_StartCCB
45#define SccbMgr_abort_sccb FlashPoint_AbortCCB
46#define SccbMgr_my_int FlashPoint_InterruptPending
47#define SccbMgr_isr FlashPoint_HandleInterrupt
48 32
49 33
50 34
@@ -266,12 +250,12 @@ typedef struct _SCCB {
266#define SG_ELEMENT_SIZE 8 /*Eight byte per element. */ 250#define SG_ELEMENT_SIZE 8 /*Eight byte per element. */
267 251
268 252
269#define RD_HARPOON(ioport) OS_InPortByte((u32bits)ioport) 253#define RD_HARPOON(ioport) inb((u32bits)ioport)
270#define RDW_HARPOON(ioport) OS_InPortWord((u32bits)ioport) 254#define RDW_HARPOON(ioport) inw((u32bits)ioport)
271#define RD_HARP32(ioport,offset,data) (data = OS_InPortLong((u32bits)(ioport + offset))) 255#define RD_HARP32(ioport,offset,data) (data = inl((u32bits)(ioport + offset)))
272#define WR_HARPOON(ioport,val) OS_OutPortByte((u32bits)ioport,(u08bits) val) 256#define WR_HARPOON(ioport,val) outb((u08bits) val, (u32bits)ioport)
273#define WRW_HARPOON(ioport,val) OS_OutPortWord((u32bits)ioport,(u16bits)val) 257#define WRW_HARPOON(ioport,val) outw((u16bits)val, (u32bits)ioport)
274#define WR_HARP32(ioport,offset,data) OS_OutPortLong((u32bits)(ioport + offset), data) 258#define WR_HARP32(ioport,offset,data) outl(data, (u32bits)(ioport + offset))
275 259
276 260
277#define TAR_SYNC_MASK (BIT(7)+BIT(6)) 261#define TAR_SYNC_MASK (BIT(7)+BIT(6))
@@ -1130,13 +1114,13 @@ static void (*FPT_s_PhaseTbl[8]) (ULONG, UCHAR)= { 0 };
1130 1114
1131/*--------------------------------------------------------------------- 1115/*---------------------------------------------------------------------
1132 * 1116 *
1133 * Function: SccbMgr_sense_adapter 1117 * Function: FlashPoint_ProbeHostAdapter
1134 * 1118 *
1135 * Description: Setup and/or Search for cards and return info to caller. 1119 * Description: Setup and/or Search for cards and return info to caller.
1136 * 1120 *
1137 *---------------------------------------------------------------------*/ 1121 *---------------------------------------------------------------------*/
1138 1122
1139static int SccbMgr_sense_adapter(PSCCBMGR_INFO pCardInfo) 1123static int FlashPoint_ProbeHostAdapter(PSCCBMGR_INFO pCardInfo)
1140{ 1124{
1141 static UCHAR first_time = 1; 1125 static UCHAR first_time = 1;
1142 1126
@@ -1408,13 +1392,13 @@ static int SccbMgr_sense_adapter(PSCCBMGR_INFO pCardInfo)
1408 1392
1409/*--------------------------------------------------------------------- 1393/*---------------------------------------------------------------------
1410 * 1394 *
1411 * Function: SccbMgr_config_adapter 1395 * Function: FlashPoint_HardwareResetHostAdapter
1412 * 1396 *
1413 * Description: Setup adapter for normal operation (hard reset). 1397 * Description: Setup adapter for normal operation (hard reset).
1414 * 1398 *
1415 *---------------------------------------------------------------------*/ 1399 *---------------------------------------------------------------------*/
1416 1400
1417static ULONG SccbMgr_config_adapter(PSCCBMGR_INFO pCardInfo) 1401static ULONG FlashPoint_HardwareResetHostAdapter(PSCCBMGR_INFO pCardInfo)
1418{ 1402{
1419 PSCCBcard CurrCard = NULL; 1403 PSCCBcard CurrCard = NULL;
1420 PNVRamInfo pCurrNvRam; 1404 PNVRamInfo pCurrNvRam;
@@ -1595,7 +1579,7 @@ static ULONG SccbMgr_config_adapter(PSCCBMGR_INFO pCardInfo)
1595 return((ULONG)CurrCard); 1579 return((ULONG)CurrCard);
1596} 1580}
1597 1581
1598static void SccbMgr_unload_card(ULONG pCurrCard) 1582static void FlashPoint_ReleaseHostAdapter(ULONG pCurrCard)
1599{ 1583{
1600 UCHAR i; 1584 UCHAR i;
1601 ULONG portBase; 1585 ULONG portBase;
@@ -1687,14 +1671,14 @@ static UCHAR FPT_ChkIfChipInitialized(ULONG ioPort)
1687} 1671}
1688/*--------------------------------------------------------------------- 1672/*---------------------------------------------------------------------
1689 * 1673 *
1690 * Function: SccbMgr_start_sccb 1674 * Function: FlashPoint_StartCCB
1691 * 1675 *
1692 * Description: Start a command pointed to by p_Sccb. When the 1676 * Description: Start a command pointed to by p_Sccb. When the
1693 * command is completed it will be returned via the 1677 * command is completed it will be returned via the
1694 * callback function. 1678 * callback function.
1695 * 1679 *
1696 *---------------------------------------------------------------------*/ 1680 *---------------------------------------------------------------------*/
1697static void SccbMgr_start_sccb(ULONG pCurrCard, PSCCB p_Sccb) 1681static void FlashPoint_StartCCB(ULONG pCurrCard, PSCCB p_Sccb)
1698{ 1682{
1699 ULONG ioport; 1683 ULONG ioport;
1700 UCHAR thisCard, lun; 1684 UCHAR thisCard, lun;
@@ -1807,14 +1791,14 @@ static void SccbMgr_start_sccb(ULONG pCurrCard, PSCCB p_Sccb)
1807 1791
1808/*--------------------------------------------------------------------- 1792/*---------------------------------------------------------------------
1809 * 1793 *
1810 * Function: SccbMgr_abort_sccb 1794 * Function: FlashPoint_AbortCCB
1811 * 1795 *
1812 * Description: Abort the command pointed to by p_Sccb. When the 1796 * Description: Abort the command pointed to by p_Sccb. When the
1813 * command is completed it will be returned via the 1797 * command is completed it will be returned via the
1814 * callback function. 1798 * callback function.
1815 * 1799 *
1816 *---------------------------------------------------------------------*/ 1800 *---------------------------------------------------------------------*/
1817static int SccbMgr_abort_sccb(ULONG pCurrCard, PSCCB p_Sccb) 1801static int FlashPoint_AbortCCB(ULONG pCurrCard, PSCCB p_Sccb)
1818{ 1802{
1819 ULONG ioport; 1803 ULONG ioport;
1820 1804
@@ -1908,13 +1892,13 @@ static int SccbMgr_abort_sccb(ULONG pCurrCard, PSCCB p_Sccb)
1908 1892
1909/*--------------------------------------------------------------------- 1893/*---------------------------------------------------------------------
1910 * 1894 *
1911 * Function: SccbMgr_my_int 1895 * Function: FlashPoint_InterruptPending
1912 * 1896 *
1913 * Description: Do a quick check to determine if there is a pending 1897 * Description: Do a quick check to determine if there is a pending
1914 * interrupt for this card and disable the IRQ Pin if so. 1898 * interrupt for this card and disable the IRQ Pin if so.
1915 * 1899 *
1916 *---------------------------------------------------------------------*/ 1900 *---------------------------------------------------------------------*/
1917static UCHAR SccbMgr_my_int(ULONG pCurrCard) 1901static UCHAR FlashPoint_InterruptPending(ULONG pCurrCard)
1918{ 1902{
1919 ULONG ioport; 1903 ULONG ioport;
1920 1904
@@ -1934,14 +1918,14 @@ static UCHAR SccbMgr_my_int(ULONG pCurrCard)
1934 1918
1935/*--------------------------------------------------------------------- 1919/*---------------------------------------------------------------------
1936 * 1920 *
1937 * Function: SccbMgr_isr 1921 * Function: FlashPoint_HandleInterrupt
1938 * 1922 *
1939 * Description: This is our entry point when an interrupt is generated 1923 * Description: This is our entry point when an interrupt is generated
1940 * by the card and the upper level driver passes it on to 1924 * by the card and the upper level driver passes it on to
1941 * us. 1925 * us.
1942 * 1926 *
1943 *---------------------------------------------------------------------*/ 1927 *---------------------------------------------------------------------*/
1944static int SccbMgr_isr(ULONG pCurrCard) 1928static int FlashPoint_HandleInterrupt(ULONG pCurrCard)
1945{ 1929{
1946 PSCCB currSCCB; 1930 PSCCB currSCCB;
1947 UCHAR thisCard,result,bm_status, bm_int_st; 1931 UCHAR thisCard,result,bm_status, bm_int_st;