diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2009-06-04 19:07:59 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-06-08 03:20:22 -0400 |
commit | f957bcf0164e45bd77867e02412035e1c2fd7058 (patch) | |
tree | 0d853d05de9c1e49ded905aeb0d267ac7dd7ce91 | |
parent | d65a68a8da5c9d1041ebc5e018e677d641910668 (diff) |
s2io: Remove private boolean definitions
Remove the private definition of TRUE/FALSE and use the ones from
linux/stddef.h. Also remove the definition of BOOL which is not referenced
inside the driver anyway.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/s2io.c | 22 | ||||
-rw-r--r-- | drivers/net/s2io.h | 9 |
2 files changed, 11 insertions, 20 deletions
diff --git a/drivers/net/s2io.c b/drivers/net/s2io.c index 2bc73ede4312..458daa06ed41 100644 --- a/drivers/net/s2io.c +++ b/drivers/net/s2io.c | |||
@@ -1764,7 +1764,7 @@ static int init_nic(struct s2io_nic *nic) | |||
1764 | * by then we return error. | 1764 | * by then we return error. |
1765 | */ | 1765 | */ |
1766 | time = 0; | 1766 | time = 0; |
1767 | while (TRUE) { | 1767 | while (true) { |
1768 | val64 = readq(&bar0->rti_command_mem); | 1768 | val64 = readq(&bar0->rti_command_mem); |
1769 | if (!(val64 & RTI_CMD_MEM_STROBE_NEW_CMD)) | 1769 | if (!(val64 & RTI_CMD_MEM_STROBE_NEW_CMD)) |
1770 | break; | 1770 | break; |
@@ -2137,7 +2137,7 @@ static int verify_pcc_quiescent(struct s2io_nic *sp, int flag) | |||
2137 | 2137 | ||
2138 | herc = (sp->device_type == XFRAME_II_DEVICE); | 2138 | herc = (sp->device_type == XFRAME_II_DEVICE); |
2139 | 2139 | ||
2140 | if (flag == FALSE) { | 2140 | if (flag == false) { |
2141 | if ((!herc && (sp->pdev->revision >= 4)) || herc) { | 2141 | if ((!herc && (sp->pdev->revision >= 4)) || herc) { |
2142 | if (!(val64 & ADAPTER_STATUS_RMAC_PCC_IDLE)) | 2142 | if (!(val64 & ADAPTER_STATUS_RMAC_PCC_IDLE)) |
2143 | ret = 1; | 2143 | ret = 1; |
@@ -3587,7 +3587,7 @@ static void s2io_reset(struct s2io_nic * sp) | |||
3587 | writeq(val64, &bar0->pcc_err_reg); | 3587 | writeq(val64, &bar0->pcc_err_reg); |
3588 | } | 3588 | } |
3589 | 3589 | ||
3590 | sp->device_enabled_once = FALSE; | 3590 | sp->device_enabled_once = false; |
3591 | } | 3591 | } |
3592 | 3592 | ||
3593 | /** | 3593 | /** |
@@ -5572,10 +5572,10 @@ static void s2io_ethtool_getpause_data(struct net_device *dev, | |||
5572 | 5572 | ||
5573 | val64 = readq(&bar0->rmac_pause_cfg); | 5573 | val64 = readq(&bar0->rmac_pause_cfg); |
5574 | if (val64 & RMAC_PAUSE_GEN_ENABLE) | 5574 | if (val64 & RMAC_PAUSE_GEN_ENABLE) |
5575 | ep->tx_pause = TRUE; | 5575 | ep->tx_pause = true; |
5576 | if (val64 & RMAC_PAUSE_RX_ENABLE) | 5576 | if (val64 & RMAC_PAUSE_RX_ENABLE) |
5577 | ep->rx_pause = TRUE; | 5577 | ep->rx_pause = true; |
5578 | ep->autoneg = FALSE; | 5578 | ep->autoneg = false; |
5579 | } | 5579 | } |
5580 | 5580 | ||
5581 | /** | 5581 | /** |
@@ -6806,7 +6806,7 @@ static void s2io_set_link(struct work_struct *work) | |||
6806 | val64 |= ADAPTER_LED_ON; | 6806 | val64 |= ADAPTER_LED_ON; |
6807 | writeq(val64, &bar0->adapter_control); | 6807 | writeq(val64, &bar0->adapter_control); |
6808 | } | 6808 | } |
6809 | nic->device_enabled_once = TRUE; | 6809 | nic->device_enabled_once = true; |
6810 | } else { | 6810 | } else { |
6811 | DBG_PRINT(ERR_DBG, "%s: Error: ", dev->name); | 6811 | DBG_PRINT(ERR_DBG, "%s: Error: ", dev->name); |
6812 | DBG_PRINT(ERR_DBG, "device is not Quiescent\n"); | 6812 | DBG_PRINT(ERR_DBG, "device is not Quiescent\n"); |
@@ -7754,7 +7754,7 @@ s2io_init_nic(struct pci_dev *pdev, const struct pci_device_id *pre) | |||
7754 | struct s2io_nic *sp; | 7754 | struct s2io_nic *sp; |
7755 | struct net_device *dev; | 7755 | struct net_device *dev; |
7756 | int i, j, ret; | 7756 | int i, j, ret; |
7757 | int dma_flag = FALSE; | 7757 | int dma_flag = false; |
7758 | u32 mac_up, mac_down; | 7758 | u32 mac_up, mac_down; |
7759 | u64 val64 = 0, tmp64 = 0; | 7759 | u64 val64 = 0, tmp64 = 0; |
7760 | struct XENA_dev_config __iomem *bar0 = NULL; | 7760 | struct XENA_dev_config __iomem *bar0 = NULL; |
@@ -7777,7 +7777,7 @@ s2io_init_nic(struct pci_dev *pdev, const struct pci_device_id *pre) | |||
7777 | 7777 | ||
7778 | if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) { | 7778 | if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) { |
7779 | DBG_PRINT(INIT_DBG, "s2io_init_nic: Using 64bit DMA\n"); | 7779 | DBG_PRINT(INIT_DBG, "s2io_init_nic: Using 64bit DMA\n"); |
7780 | dma_flag = TRUE; | 7780 | dma_flag = true; |
7781 | if (pci_set_consistent_dma_mask | 7781 | if (pci_set_consistent_dma_mask |
7782 | (pdev, DMA_BIT_MASK(64))) { | 7782 | (pdev, DMA_BIT_MASK(64))) { |
7783 | DBG_PRINT(ERR_DBG, | 7783 | DBG_PRINT(ERR_DBG, |
@@ -7818,7 +7818,7 @@ s2io_init_nic(struct pci_dev *pdev, const struct pci_device_id *pre) | |||
7818 | sp->dev = dev; | 7818 | sp->dev = dev; |
7819 | sp->pdev = pdev; | 7819 | sp->pdev = pdev; |
7820 | sp->high_dma_flag = dma_flag; | 7820 | sp->high_dma_flag = dma_flag; |
7821 | sp->device_enabled_once = FALSE; | 7821 | sp->device_enabled_once = false; |
7822 | if (rx_ring_mode == 1) | 7822 | if (rx_ring_mode == 1) |
7823 | sp->rxd_mode = RXD_MODE_1; | 7823 | sp->rxd_mode = RXD_MODE_1; |
7824 | if (rx_ring_mode == 2) | 7824 | if (rx_ring_mode == 2) |
@@ -7964,7 +7964,7 @@ s2io_init_nic(struct pci_dev *pdev, const struct pci_device_id *pre) | |||
7964 | dev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX; | 7964 | dev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX; |
7965 | 7965 | ||
7966 | dev->features |= NETIF_F_SG | NETIF_F_IP_CSUM; | 7966 | dev->features |= NETIF_F_SG | NETIF_F_IP_CSUM; |
7967 | if (sp->high_dma_flag == TRUE) | 7967 | if (sp->high_dma_flag == true) |
7968 | dev->features |= NETIF_F_HIGHDMA; | 7968 | dev->features |= NETIF_F_HIGHDMA; |
7969 | dev->features |= NETIF_F_TSO; | 7969 | dev->features |= NETIF_F_TSO; |
7970 | dev->features |= NETIF_F_TSO6; | 7970 | dev->features |= NETIF_F_TSO6; |
diff --git a/drivers/net/s2io.h b/drivers/net/s2io.h index 55cb943f23f8..d5c5be6c07b9 100644 --- a/drivers/net/s2io.h +++ b/drivers/net/s2io.h | |||
@@ -18,15 +18,6 @@ | |||
18 | #define vBIT(val, loc, sz) (((u64)val) << (64-loc-sz)) | 18 | #define vBIT(val, loc, sz) (((u64)val) << (64-loc-sz)) |
19 | #define INV(d) ((d&0xff)<<24) | (((d>>8)&0xff)<<16) | (((d>>16)&0xff)<<8)| ((d>>24)&0xff) | 19 | #define INV(d) ((d&0xff)<<24) | (((d>>8)&0xff)<<16) | (((d>>16)&0xff)<<8)| ((d>>24)&0xff) |
20 | 20 | ||
21 | #ifndef BOOL | ||
22 | #define BOOL int | ||
23 | #endif | ||
24 | |||
25 | #ifndef TRUE | ||
26 | #define TRUE 1 | ||
27 | #define FALSE 0 | ||
28 | #endif | ||
29 | |||
30 | #undef SUCCESS | 21 | #undef SUCCESS |
31 | #define SUCCESS 0 | 22 | #define SUCCESS 0 |
32 | #define FAILURE -1 | 23 | #define FAILURE -1 |