-
-REGISTER_SIM_OBJECT("IGbEInt", IGbEInt)
-
-
-BEGIN_DECLARE_SIM_OBJECT_PARAMS(IGbE)
-
- SimObjectParam<System *> system;
- SimObjectParam<Platform *> platform;
- Param<Tick> min_backoff_delay;
- Param<Tick> max_backoff_delay;
- SimObjectParam<PciConfigData *> configdata;
- Param<uint32_t> pci_bus;
- Param<uint32_t> pci_dev;
- Param<uint32_t> pci_func;
- Param<Tick> pio_latency;
- Param<Tick> config_latency;
- Param<std::string> hardware_address;
- Param<bool> use_flow_control;
- Param<int> rx_fifo_size;
- Param<int> tx_fifo_size;
- Param<int> rx_desc_cache_size;
- Param<int> tx_desc_cache_size;
- Param<Tick> clock;
-
-
-END_DECLARE_SIM_OBJECT_PARAMS(IGbE)
-
-BEGIN_INIT_SIM_OBJECT_PARAMS(IGbE)
-
- INIT_PARAM(system, "System pointer"),
- INIT_PARAM(platform, "Platform pointer"),
- INIT_PARAM(min_backoff_delay, "Minimum delay after receving a nack packed"),
- INIT_PARAM(max_backoff_delay, "Maximum delay after receving a nack packed"),
- INIT_PARAM(configdata, "PCI Config data"),
- INIT_PARAM(pci_bus, "PCI bus ID"),
- INIT_PARAM(pci_dev, "PCI device number"),
- INIT_PARAM(pci_func, "PCI function code"),
- INIT_PARAM_DFLT(pio_latency, "Programmed IO latency in bus cycles", 1),
- INIT_PARAM(config_latency, "Number of cycles for a config read or write"),
- INIT_PARAM(hardware_address, "Ethernet Hardware Address"),
- INIT_PARAM(use_flow_control,"Should the device use xon/off packets"),
- INIT_PARAM(rx_fifo_size,"Size of the RX FIFO"),
- INIT_PARAM(tx_fifo_size,"Size of the TX FIFO"),
- INIT_PARAM(rx_desc_cache_size,"Size of the RX descriptor cache"),
- INIT_PARAM(tx_desc_cache_size,"Size of the TX descriptor cache"),
- INIT_PARAM(clock,"Clock rate for the device to tick at")
-
-END_INIT_SIM_OBJECT_PARAMS(IGbE)
-
-
-CREATE_SIM_OBJECT(IGbE)
-{
- IGbE::Params *params = new IGbE::Params;
-
- params->name = getInstanceName();
- params->platform = platform;
- params->system = system;
- params->min_backoff_delay = min_backoff_delay;
- params->max_backoff_delay = max_backoff_delay;
- params->configData = configdata;
- params->busNum = pci_bus;
- params->deviceNum = pci_dev;
- params->functionNum = pci_func;
- params->pio_delay = pio_latency;
- params->config_delay = config_latency;
- params->hardware_address = hardware_address;
- params->use_flow_control = use_flow_control;
- params->rx_fifo_size = rx_fifo_size;
- params->tx_fifo_size = tx_fifo_size;
- params->rx_desc_cache_size = rx_desc_cache_size;
- params->tx_desc_cache_size = tx_desc_cache_size;
- params->clock = clock;
-
-
- return new IGbE(params);
-}
-
-REGISTER_SIM_OBJECT("IGbE", IGbE)