From: Mark Einon Date: Mon, 6 Jun 2011 18:07:04 +0000 (+0100) Subject: staging: et131x: Removing '_t' from ce_stats_t struct X-Git-Tag: MMI-PSA29.97-13-9~18845^2~496 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f4b70529beb4242e3906ced6de864110a8de8f50;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git staging: et131x: Removing '_t' from ce_stats_t struct Removing '_t' from ce_stats_t struct name and renaming et131x_adapter ce_stats member from 'Stats' to 'stats' Signed-off-by: Mark Einon Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/et131x/et1310_mac.c b/drivers/staging/et131x/et1310_mac.c index 5a745cfda45d..b1a7183e1b51 100644 --- a/drivers/staging/et131x/et1310_mac.c +++ b/drivers/staging/et131x/et1310_mac.c @@ -452,7 +452,7 @@ void ConfigFlowControl(struct et131x_adapter *etdev) */ void UpdateMacStatHostCounters(struct et131x_adapter *etdev) { - struct ce_stats_t *stats = &etdev->Stats; + struct ce_stats *stats = &etdev->stats; struct macstat_regs __iomem *macstat = &etdev->regs->macstat; @@ -503,33 +503,33 @@ void HandleMacStatInterrupt(struct et131x_adapter *etdev) * block indicates that one of the counters has wrapped. */ if (Carry1 & (1 << 14)) - etdev->Stats.code_violations += COUNTER_WRAP_16_BIT; + etdev->stats.code_violations += COUNTER_WRAP_16_BIT; if (Carry1 & (1 << 8)) - etdev->Stats.alignment_err += COUNTER_WRAP_12_BIT; + etdev->stats.alignment_err += COUNTER_WRAP_12_BIT; if (Carry1 & (1 << 7)) - etdev->Stats.length_err += COUNTER_WRAP_16_BIT; + etdev->stats.length_err += COUNTER_WRAP_16_BIT; if (Carry1 & (1 << 2)) - etdev->Stats.other_errors += COUNTER_WRAP_16_BIT; + etdev->stats.other_errors += COUNTER_WRAP_16_BIT; if (Carry1 & (1 << 6)) - etdev->Stats.crc_err += COUNTER_WRAP_16_BIT; + etdev->stats.crc_err += COUNTER_WRAP_16_BIT; if (Carry1 & (1 << 3)) - etdev->Stats.rx_ov_flow += COUNTER_WRAP_16_BIT; + etdev->stats.rx_ov_flow += COUNTER_WRAP_16_BIT; if (Carry1 & (1 << 0)) - etdev->Stats.norcvbuf += COUNTER_WRAP_16_BIT; + etdev->stats.norcvbuf += COUNTER_WRAP_16_BIT; if (Carry2 & (1 << 16)) - etdev->Stats.max_pkt_error += COUNTER_WRAP_12_BIT; + etdev->stats.max_pkt_error += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 15)) - etdev->Stats.tx_uflo += COUNTER_WRAP_12_BIT; + etdev->stats.tx_uflo += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 6)) - etdev->Stats.first_collision += COUNTER_WRAP_12_BIT; + etdev->stats.first_collision += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 8)) - etdev->Stats.tx_deferred += COUNTER_WRAP_12_BIT; + etdev->stats.tx_deferred += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 5)) - etdev->Stats.excessive_collisions += COUNTER_WRAP_12_BIT; + etdev->stats.excessive_collisions += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 4)) - etdev->Stats.late_collisions += COUNTER_WRAP_12_BIT; + etdev->stats.late_collisions += COUNTER_WRAP_12_BIT; if (Carry2 & (1 << 2)) - etdev->Stats.collisions += COUNTER_WRAP_12_BIT; + etdev->stats.collisions += COUNTER_WRAP_12_BIT; } void SetupDeviceForMulticast(struct et131x_adapter *etdev) diff --git a/drivers/staging/et131x/et1310_phy.c b/drivers/staging/et131x/et1310_phy.c index 190db0b7480a..1df0d05e6ebe 100644 --- a/drivers/staging/et131x/et1310_phy.c +++ b/drivers/staging/et131x/et1310_phy.c @@ -178,7 +178,7 @@ int MiWrite(struct et131x_adapter *etdev, u8 xcvrReg, u16 value) { struct mac_regs __iomem *mac = &etdev->regs->mac; int status = 0; - u8 xcvrAddr = etdev->Stats.xcvr_addr; + u8 xcvrAddr = etdev->stats.xcvr_addr; u32 delay; u32 miiAddr; u32 miiCmd; @@ -259,8 +259,8 @@ int et131x_xcvr_find(struct et131x_adapter *etdev) xcvr_id = (u32) ((idr1 << 16) | idr2); if (idr1 != 0 && idr1 != 0xffff) { - etdev->Stats.xcvr_id = xcvr_id; - etdev->Stats.xcvr_addr = xcvr_addr; + etdev->stats.xcvr_id = xcvr_id; + etdev->stats.xcvr_addr = xcvr_addr; return 0; } } diff --git a/drivers/staging/et131x/et1310_rx.c b/drivers/staging/et131x/et1310_rx.c index cd72a0be67dc..100ee9b4e43f 100644 --- a/drivers/staging/et131x/et1310_rx.c +++ b/drivers/staging/et131x/et1310_rx.c @@ -971,7 +971,7 @@ struct rfd *nic_rx_pkts(struct et131x_adapter *etdev) * also counted here. */ if (len < (NIC_MIN_PACKET_SIZE + 4)) { - etdev->Stats.other_errors++; + etdev->stats.other_errors++; len = 0; } @@ -1039,16 +1039,16 @@ struct rfd *nic_rx_pkts(struct et131x_adapter *etdev) } if (len > 0) - etdev->Stats.multircv++; + etdev->stats.multircv++; } else if (word0 & ALCATEL_BROADCAST_PKT) - etdev->Stats.brdcstrcv++; + etdev->stats.brdcstrcv++; else /* Not sure what this counter measures in * promiscuous mode. Perhaps we should check * the MAC address to see if it is directed * to us in promiscuous mode. */ - etdev->Stats.unircv++; + etdev->stats.unircv++; } if (len > 0) { @@ -1132,7 +1132,7 @@ void et131x_handle_recv_interrupt(struct et131x_adapter *etdev) } /* Increment the number of packets we received */ - etdev->Stats.ipackets++; + etdev->stats.ipackets++; /* Set the status on the packet, either resources or success */ if (etdev->rx_ring.nReadyRecv < RFD_LOW_WATER_MARK) { diff --git a/drivers/staging/et131x/et1310_tx.c b/drivers/staging/et131x/et1310_tx.c index 4241d2afecc0..b8f8dae57d6c 100644 --- a/drivers/staging/et131x/et1310_tx.c +++ b/drivers/staging/et131x/et1310_tx.c @@ -635,11 +635,11 @@ inline void et131x_free_send_packet(struct et131x_adapter *etdev, struct net_device_stats *stats = &etdev->net_stats; if (tcb->flags & fMP_DEST_BROAD) - atomic_inc(&etdev->Stats.brdcstxmt); + atomic_inc(&etdev->stats.brdcstxmt); else if (tcb->flags & fMP_DEST_MULTI) - atomic_inc(&etdev->Stats.multixmt); + atomic_inc(&etdev->stats.multixmt); else - atomic_inc(&etdev->Stats.unixmt); + atomic_inc(&etdev->stats.unixmt); if (tcb->skb) { stats->tx_bytes += tcb->skb->len; @@ -673,7 +673,7 @@ inline void et131x_free_send_packet(struct et131x_adapter *etdev, /* Add the TCB to the Ready Q */ spin_lock_irqsave(&etdev->TCBReadyQLock, flags); - etdev->Stats.opackets++; + etdev->stats.opackets++; if (etdev->tx_ring.tcb_qtail) etdev->tx_ring.tcb_qtail->next = tcb; diff --git a/drivers/staging/et131x/et131x.h b/drivers/staging/et131x/et131x.h index 8aa3365b83cf..e4251479debd 100644 --- a/drivers/staging/et131x/et131x.h +++ b/drivers/staging/et131x/et131x.h @@ -108,7 +108,7 @@ void et131x_setphy_normal(struct et131x_adapter *adapter); int PhyMiRead(struct et131x_adapter *adapter, u8 xcvrAddr, u8 xcvrReg, u16 *value); #define MiRead(adapter, xcvrReg, value) \ - PhyMiRead((adapter), (adapter)->Stats.xcvr_addr, (xcvrReg), (value)) + PhyMiRead((adapter), (adapter)->stats.xcvr_addr, (xcvrReg), (value)) int32_t MiWrite(struct et131x_adapter *adapter, u8 xcvReg, u16 value); diff --git a/drivers/staging/et131x/et131x_adapter.h b/drivers/staging/et131x/et131x_adapter.h index 0cbf699757c5..c6657f4208bd 100644 --- a/drivers/staging/et131x/et131x_adapter.h +++ b/drivers/staging/et131x/et131x_adapter.h @@ -98,7 +98,7 @@ struct rfd { #define FLOW_NONE 3 /* Struct to define some device statistics */ -struct ce_stats_t { +struct ce_stats { /* Link Input/Output stats */ uint64_t ipackets; /* # of in packets */ uint64_t opackets; /* # of out packets */ @@ -239,7 +239,7 @@ struct et131x_adapter { u8 ReplicaPhyLoopbkPF; /* Replica Enable Pass/Fail */ /* Stats */ - struct ce_stats_t Stats; + struct ce_stats stats; struct net_device_stats net_stats; struct net_device_stats net_stats_prev; diff --git a/drivers/staging/et131x/et131x_isr.c b/drivers/staging/et131x/et131x_isr.c index 11700b53ea96..19d67264ff9c 100644 --- a/drivers/staging/et131x/et131x_isr.c +++ b/drivers/staging/et131x/et131x_isr.c @@ -222,7 +222,7 @@ irqreturn_t et131x_isr(int irq, void *dev_id) * DPC. We will clear the software copy of that in that * routine. */ - adapter->Stats.InterruptStatus = status; + adapter->stats.InterruptStatus = status; /* Schedule the ISR handler as a bottom-half task in the * kernel's tq_immediate queue, and mark the queue for @@ -244,7 +244,7 @@ void et131x_isr_handler(struct work_struct *work) { struct et131x_adapter *etdev = container_of(work, struct et131x_adapter, task); - u32 status = etdev->Stats.InterruptStatus; + u32 status = etdev->stats.InterruptStatus; struct address_map __iomem *iomem = etdev->regs; /* diff --git a/drivers/staging/et131x/et131x_netdev.c b/drivers/staging/et131x/et131x_netdev.c index 7cc4b4895905..2da582867ead 100644 --- a/drivers/staging/et131x/et131x_netdev.c +++ b/drivers/staging/et131x/et131x_netdev.c @@ -100,7 +100,7 @@ struct net_device_stats *et131x_stats(struct net_device *netdev) { struct et131x_adapter *adapter = netdev_priv(netdev); struct net_device_stats *stats = &adapter->net_stats; - struct ce_stats_t *devstat = &adapter->Stats; + struct ce_stats *devstat = &adapter->stats; stats->rx_packets = devstat->ipackets; stats->tx_packets = devstat->opackets; @@ -218,7 +218,7 @@ int et131x_ioctl_mii(struct net_device *netdev, struct ifreq *reqbuf, int cmd) switch (cmd) { case SIOCGMIIPHY: - data->phy_id = etdev->Stats.xcvr_addr; + data->phy_id = etdev->stats.xcvr_addr; break; case SIOCGMIIREG: