.. | .. |
---|
379 | 379 | #define FEC_ENET_TS_AVAIL ((uint)0x00010000) |
---|
380 | 380 | #define FEC_ENET_TS_TIMER ((uint)0x00008000) |
---|
381 | 381 | |
---|
382 | | -#define FEC_DEFAULT_IMASK (FEC_ENET_TXF | FEC_ENET_RXF | FEC_ENET_MII) |
---|
383 | | -#define FEC_NAPI_IMASK FEC_ENET_MII |
---|
| 382 | +#define FEC_DEFAULT_IMASK (FEC_ENET_TXF | FEC_ENET_RXF) |
---|
384 | 383 | #define FEC_RX_DISABLED_IMASK (FEC_DEFAULT_IMASK & (~FEC_ENET_RXF)) |
---|
385 | 384 | |
---|
386 | 385 | /* ENET interrupt coalescing macro define */ |
---|
.. | .. |
---|
460 | 459 | */ |
---|
461 | 460 | #define FEC_QUIRK_HAS_FRREG (1 << 16) |
---|
462 | 461 | |
---|
| 462 | +/* Some FEC hardware blocks need the MMFR cleared at setup time to avoid |
---|
| 463 | + * the generation of an MII event. This must be avoided in the older |
---|
| 464 | + * FEC blocks where it will stop MII events being generated. |
---|
| 465 | + */ |
---|
| 466 | +#define FEC_QUIRK_CLEAR_SETUP_MII (1 << 17) |
---|
| 467 | + |
---|
463 | 468 | struct bufdesc_prop { |
---|
464 | 469 | int qid; |
---|
465 | 470 | /* Address of Rx and Tx buffers */ |
---|
.. | .. |
---|
529 | 534 | unsigned int total_tx_ring_size; |
---|
530 | 535 | unsigned int total_rx_ring_size; |
---|
531 | 536 | |
---|
532 | | - unsigned long work_tx; |
---|
533 | | - unsigned long work_rx; |
---|
534 | | - unsigned long work_ts; |
---|
535 | | - unsigned long work_mdio; |
---|
536 | | - |
---|
537 | 537 | struct platform_device *pdev; |
---|
538 | 538 | |
---|
539 | 539 | int dev_id; |
---|
540 | 540 | |
---|
541 | 541 | /* Phylib and MDIO interface */ |
---|
542 | 542 | struct mii_bus *mii_bus; |
---|
543 | | - int mii_timeout; |
---|
544 | 543 | uint phy_speed; |
---|
545 | 544 | phy_interface_t phy_interface; |
---|
546 | 545 | struct device_node *phy_node; |
---|
547 | 546 | int link; |
---|
548 | 547 | int full_duplex; |
---|
549 | 548 | int speed; |
---|
550 | | - struct completion mdio_done; |
---|
551 | 549 | int irq[FEC_IRQ_NUM]; |
---|
552 | 550 | bool bufdesc_ex; |
---|
553 | 551 | int pause_flag; |
---|
.. | .. |
---|
595 | 593 | int pps_enable; |
---|
596 | 594 | unsigned int next_counter; |
---|
597 | 595 | |
---|
598 | | - u64 ethtool_stats[0]; |
---|
| 596 | + u64 ethtool_stats[]; |
---|
599 | 597 | }; |
---|
600 | 598 | |
---|
601 | 599 | void fec_ptp_init(struct platform_device *pdev, int irq_idx); |
---|
602 | 600 | void fec_ptp_stop(struct platform_device *pdev); |
---|
603 | 601 | void fec_ptp_start_cyclecounter(struct net_device *ndev); |
---|
| 602 | +void fec_ptp_disable_hwts(struct net_device *ndev); |
---|
604 | 603 | int fec_ptp_set(struct net_device *ndev, struct ifreq *ifr); |
---|
605 | 604 | int fec_ptp_get(struct net_device *ndev, struct ifreq *ifr); |
---|
606 | 605 | |
---|