Commit graph

310 commits

Author SHA1 Message Date
Nathan Binkert 13c005a8af shuffle files around for new directory structure
--HG--
rename : cpu/base_cpu.cc => cpu/base.cc
rename : cpu/base_cpu.hh => cpu/base.hh
rename : cpu/beta_cpu/2bit_local_pred.cc => cpu/o3/2bit_local_pred.cc
rename : cpu/beta_cpu/2bit_local_pred.hh => cpu/o3/2bit_local_pred.hh
rename : cpu/beta_cpu/alpha_full_cpu.cc => cpu/o3/alpha_cpu.cc
rename : cpu/beta_cpu/alpha_full_cpu.hh => cpu/o3/alpha_cpu.hh
rename : cpu/beta_cpu/alpha_full_cpu_builder.cc => cpu/o3/alpha_cpu_builder.cc
rename : cpu/beta_cpu/alpha_full_cpu_impl.hh => cpu/o3/alpha_cpu_impl.hh
rename : cpu/beta_cpu/alpha_dyn_inst.cc => cpu/o3/alpha_dyn_inst.cc
rename : cpu/beta_cpu/alpha_dyn_inst.hh => cpu/o3/alpha_dyn_inst.hh
rename : cpu/beta_cpu/alpha_dyn_inst_impl.hh => cpu/o3/alpha_dyn_inst_impl.hh
rename : cpu/beta_cpu/alpha_impl.hh => cpu/o3/alpha_impl.hh
rename : cpu/beta_cpu/alpha_params.hh => cpu/o3/alpha_params.hh
rename : cpu/beta_cpu/bpred_unit.cc => cpu/o3/bpred_unit.cc
rename : cpu/beta_cpu/bpred_unit.hh => cpu/o3/bpred_unit.hh
rename : cpu/beta_cpu/bpred_unit_impl.hh => cpu/o3/bpred_unit_impl.hh
rename : cpu/beta_cpu/btb.cc => cpu/o3/btb.cc
rename : cpu/beta_cpu/btb.hh => cpu/o3/btb.hh
rename : cpu/beta_cpu/comm.hh => cpu/o3/comm.hh
rename : cpu/beta_cpu/commit.cc => cpu/o3/commit.cc
rename : cpu/beta_cpu/commit.hh => cpu/o3/commit.hh
rename : cpu/beta_cpu/commit_impl.hh => cpu/o3/commit_impl.hh
rename : cpu/beta_cpu/full_cpu.cc => cpu/o3/cpu.cc
rename : cpu/beta_cpu/full_cpu.hh => cpu/o3/cpu.hh
rename : cpu/beta_cpu/cpu_policy.hh => cpu/o3/cpu_policy.hh
rename : cpu/beta_cpu/decode.cc => cpu/o3/decode.cc
rename : cpu/beta_cpu/decode.hh => cpu/o3/decode.hh
rename : cpu/beta_cpu/decode_impl.hh => cpu/o3/decode_impl.hh
rename : cpu/beta_cpu/fetch.cc => cpu/o3/fetch.cc
rename : cpu/beta_cpu/fetch.hh => cpu/o3/fetch.hh
rename : cpu/beta_cpu/fetch_impl.hh => cpu/o3/fetch_impl.hh
rename : cpu/beta_cpu/free_list.cc => cpu/o3/free_list.cc
rename : cpu/beta_cpu/free_list.hh => cpu/o3/free_list.hh
rename : cpu/beta_cpu/iew.cc => cpu/o3/iew.cc
rename : cpu/beta_cpu/iew.hh => cpu/o3/iew.hh
rename : cpu/beta_cpu/iew_impl.hh => cpu/o3/iew_impl.hh
rename : cpu/beta_cpu/inst_queue.cc => cpu/o3/inst_queue.cc
rename : cpu/beta_cpu/inst_queue.hh => cpu/o3/inst_queue.hh
rename : cpu/beta_cpu/inst_queue_impl.hh => cpu/o3/inst_queue_impl.hh
rename : cpu/beta_cpu/mem_dep_unit.cc => cpu/o3/mem_dep_unit.cc
rename : cpu/beta_cpu/mem_dep_unit.hh => cpu/o3/mem_dep_unit.hh
rename : cpu/beta_cpu/mem_dep_unit_impl.hh => cpu/o3/mem_dep_unit_impl.hh
rename : cpu/beta_cpu/ras.cc => cpu/o3/ras.cc
rename : cpu/beta_cpu/ras.hh => cpu/o3/ras.hh
rename : cpu/beta_cpu/regfile.hh => cpu/o3/regfile.hh
rename : cpu/beta_cpu/rename.cc => cpu/o3/rename.cc
rename : cpu/beta_cpu/rename.hh => cpu/o3/rename.hh
rename : cpu/beta_cpu/rename_impl.hh => cpu/o3/rename_impl.hh
rename : cpu/beta_cpu/rename_map.cc => cpu/o3/rename_map.cc
rename : cpu/beta_cpu/rename_map.hh => cpu/o3/rename_map.hh
rename : cpu/beta_cpu/rob.cc => cpu/o3/rob.cc
rename : cpu/beta_cpu/rob.hh => cpu/o3/rob.hh
rename : cpu/beta_cpu/rob_impl.hh => cpu/o3/rob_impl.hh
rename : cpu/beta_cpu/sat_counter.cc => cpu/o3/sat_counter.cc
rename : cpu/beta_cpu/sat_counter.hh => cpu/o3/sat_counter.hh
rename : cpu/beta_cpu/store_set.cc => cpu/o3/store_set.cc
rename : cpu/beta_cpu/store_set.hh => cpu/o3/store_set.hh
rename : cpu/beta_cpu/tournament_pred.cc => cpu/o3/tournament_pred.cc
rename : cpu/beta_cpu/tournament_pred.hh => cpu/o3/tournament_pred.hh
rename : cpu/ooo_cpu/ooo_cpu.cc => cpu/ozone/cpu.cc
rename : cpu/ooo_cpu/ooo_cpu.hh => cpu/ozone/cpu.hh
rename : cpu/ooo_cpu/ooo_impl.hh => cpu/ozone/cpu_impl.hh
rename : cpu/ooo_cpu/ea_list.cc => cpu/ozone/ea_list.cc
rename : cpu/ooo_cpu/ea_list.hh => cpu/ozone/ea_list.hh
rename : cpu/simple_cpu/simple_cpu.cc => cpu/simple/cpu.cc
rename : cpu/simple_cpu/simple_cpu.hh => cpu/simple/cpu.hh
rename : cpu/full_cpu/smt.hh => cpu/smt.hh
rename : cpu/full_cpu/op_class.hh => encumbered/cpu/full/op_class.hh
extra : convert_revision : c4a891d8d6d3e0e9e5ea56be47d851da44d8c032
2005-06-04 20:50:10 -04:00
Steve Reinhardt 62fa781fee Rename sim/universe.{cc,hh} to root.{cc,hh} (since the
object defined there was renamed Root long ago).

SConscript:
arch/alpha/alpha_linux_process.cc:
arch/alpha/alpha_tru64_process.cc:
base/misc.cc:
base/pollevent.cc:
base/pollevent.hh:
base/stats/events.cc:
base/trace.hh:
cpu/beta_cpu/fetch_impl.hh:
cpu/beta_cpu/full_cpu.cc:
cpu/beta_cpu/inst_queue_impl.hh:
cpu/pc_event.cc:
cpu/static_inst.cc:
dev/etherbus.cc:
dev/etherdump.cc:
dev/etherlink.cc:
dev/ide_disk.cc:
dev/pcidev.cc:
sim/builder.cc:
sim/eventq.cc:
sim/main.cc:
sim/root.cc:
sim/stat_control.cc:
    Rename sim/universe.{cc,hh} to root.{cc,hh}.

--HG--
rename : sim/universe.cc => sim/root.cc
extra : convert_revision : b8699e81e285253d66da75412e7bb2c251c0389a
2005-06-01 21:59:27 -04:00
Steve Reinhardt 8031cd93b5 Standardize clock parameter names to 'clock'.
Fix description for Bus clock_ratio (no longer a ratio).
Add Clock param type (generic Frequency or Latency).

cpu/base_cpu.cc:
cpu/base_cpu.hh:
cpu/beta_cpu/alpha_full_cpu_builder.cc:
cpu/simple_cpu/simple_cpu.cc:
dev/ide_ctrl.cc:
dev/ns_gige.cc:
dev/ns_gige.hh:
dev/pciconfigall.cc:
dev/sinic.cc:
dev/tsunami_cchip.cc:
dev/tsunami_io.cc:
dev/tsunami_pchip.cc:
dev/uart.cc:
python/m5/objects/BaseCPU.py:
python/m5/objects/BaseCache.py:
python/m5/objects/BaseSystem.py:
python/m5/objects/Bus.py:
python/m5/objects/Ethernet.py:
python/m5/objects/Root.py:
sim/universe.cc:
    Standardize clock parameter names to 'clock'.
    Fix description for Bus clock_ratio (no longer a ratio).
python/m5/config.py:
    Minor tweaks on Frequency/Latency:
    - added new Clock param type to avoid ambiguities
    - factored out init code into getLatency()
    - made RootFrequency *not* a subclass of Frequency so it
    can't be directly assigned to a Frequency paremeter

--HG--
extra : convert_revision : fc4bb8562df171b454bbf696314cda57e1ec8506
2005-06-01 21:44:00 -04:00
Lisa Hsu 0b88d529dc ns_gige_reg.h, ns_gige.cc:
clean up code to eliminate license issues.

dev/ns_gige.cc:
dev/ns_gige_reg.h:
    clean up code to eliminate license issues.

--HG--
extra : convert_revision : 64adbd87faa5ce5ac6b9da4fd95b12796487c8f9
2005-05-28 21:54:32 -04:00
Nathan Binkert 364f6e3235 Make sinic work with mpy
dev/sinic.cc:
dev/sinic.hh:
    Fix sinic parameters. (header_bus -> io_bus)
python/m5/objects/Ethernet.mpy:
    Add simobj definitions for sinic.

--HG--
extra : convert_revision : 77d5b80bd1f1708329b263fb48965d7f555cc9d1
2005-05-02 19:00:11 -04:00
Nathan Binkert 1760925f73 Improve checkpointing of ethernet packets a bit.
dev/etherpkt.cc:
    Don't try to suck in the packet if the length is zero.

--HG--
extra : convert_revision : 7212f3b677777fbce301f0613b9f513bb9fe057e
2005-05-02 18:55:39 -04:00
Ron Dreslinski 602a489573 Add suport for no allocation of cache block on a dma read passing through a cache from the cpu-side interface
--HG--
extra : convert_revision : 0a3b3741924ed39c1c8710d0963e4c8f3e73f81a
2005-04-29 21:01:43 -04:00
Nathan Binkert 3154e2a0c7 Add the m5 parameter to the ns83820 device model so that we
can pass simulator specific options to the device driver.

dev/ns_gige.cc:
    Add the m5 register and parameter to the ns83820 device model
    so that we can pass simulator specific options to the device
    driver.
dev/ns_gige.hh:
dev/ns_gige_reg.h:
    Add the m5 register to the ns83820 device model

--HG--
extra : convert_revision : 84674887560fa3b607e725b8e5bc8272761fcf09
2005-04-24 21:32:32 -04:00
Nathan Binkert 5eab6c4b41 Make the notion of a global event tick independent of the actual
CPU cycle ticks.  This allows the user to have CPUs of different
frequencies, and also allows frequencies and latencies that are
not evenly divisible by the CPU frequency.  For now, the CPU
frequency is still set to the global frequency, but soon, we'll
hopefully make the global frequency fixed at something like 1THz
and set all other frequencies independently.

arch/alpha/ev5.cc:
    The cycles counter is based on the current cpu cycle.
cpu/base_cpu.cc:
    frequency isn't the cpu parameter anymore, cycleTime is.
cpu/base_cpu.hh:
    frequency isn't the cpu parameter anymore, cycleTime is.
    create several public functions for getting the cpu frequency
    and the numbers of ticks for a given number of cycles, etc.
cpu/memtest/memtest.cc:
cpu/simple_cpu/simple_cpu.cc:
cpu/simple_cpu/simple_cpu.hh:
cpu/trace/trace_cpu.cc:
    Now that ticks aren't cpu cycles, fixup code to advance
    by the proper number of ticks.
cpu/memtest/memtest.hh:
cpu/trace/trace_cpu.hh:
    Provide a function to get the number of ticks for a given
    number of cycles.
dev/alpha_console.cc:
    Update for changes in the way that frequencies and latencies are
    accessed.  Move some stuff to init()
dev/alpha_console.hh:
    Need a pointer to the system and the cpu to get the frequency
    so we can pass the info to the console code.
dev/etherbus.cc:
dev/etherbus.hh:
dev/etherlink.cc:
dev/etherlink.hh:
dev/ethertap.cc:
dev/ide_disk.hh:
dev/ns_gige.cc:
dev/ns_gige.hh:
    update for changes in the way bandwidths are passed from
    python to C++ to accomidate the new way that ticks works.
dev/ide_disk.cc:
    update for changes in the way bandwidths are passed from
    python to C++ to accomidate the new way that ticks works.
    Add some extra debugging printfs
dev/platform.cc:
dev/sinic.cc:
dev/sinic.hh:
    outline the constructor and destructor
dev/platform.hh:
    outline the constructor and destructor.
    don't keep track of the interrupt frequency.  Only provide the
    accessor function.
dev/tsunami.cc:
dev/tsunami.hh:
    outline the constructor and destructor
    Don't set the interrupt frequency here.  Get it from the actual device
    that does the interrupting.
dev/tsunami_io.cc:
dev/tsunami_io.hh:
    Make the interrupt interval a configuration parameter.  (And convert
    the interval to the new latency/frequency stuff in the python)
kern/linux/linux_system.cc:
    update for changes in the way bandwidths are passed from
    python to C++ to accomidate the new way that ticks works.
    For now, we must get the boot cpu's frequency as a parameter
    since allowing the system to have a pointer to the boot cpu would
    cause a cycle.
kern/tru64/tru64_system.cc:
    For now, we must get the boot cpu's frequency as a parameter
    since allowing the system to have a pointer to the boot cpu would
    cause a cycle.
python/m5/config.py:
    Fix support for cycle_time relative latencies and frequencies.
    Add support for getting a NetworkBandwidth or a MemoryBandwidth.
python/m5/objects/BaseCPU.mpy:
    All CPUs now have a cycle_time.  The default is the global frequency,
    but it is now possible to set the global frequency to some large value
    (like 1THz) and set each CPU frequency independently.
python/m5/objects/BaseCache.mpy:
python/m5/objects/Ide.mpy:
    Make this a Latency parameter
python/m5/objects/BaseSystem.mpy:
    We need to pass the boot CPU's frequency to the system
python/m5/objects/Ethernet.mpy:
    Update parameter types to use latency and bandwidth types
python/m5/objects/Platform.mpy:
    this frequency isn't needed.  We get it from the clock interrupt.
python/m5/objects/Tsunami.mpy:
    The clock generator should hold the frequency
sim/eventq.hh:
    Need to remove this assertion because the writeback event
    queue is different from the CPU's event queue which can cause
    this assertion to fail.
sim/process.cc:
    Fix comment.
sim/system.hh:
    Struct member to hold the boot CPU's frequency.
sim/universe.cc:
    remove unneeded variable.

--HG--
extra : convert_revision : 51efe4041095234bf458d9b3b0d417f4cae16fdc
2005-04-11 15:32:06 -04:00
Nathan Binkert 060bb32f27 Cleanup diagnostic and error messages for the IDE disk
dev/ide_disk.cc:
    Cleanup diagnostic and error messages

--HG--
extra : convert_revision : fb1bc6d9f28a10961c9d3ee1dc81b540b92653b8
2005-04-06 17:47:32 -04:00
Nathan Binkert 235186859c Better debugging output for the ide controller
dev/ide_ctrl.cc:
    Better debugging

--HG--
extra : convert_revision : 854e17f9f36fe4a0b6b69fd48027d2b1b231e858
2005-04-06 17:39:25 -04:00
Nathan Binkert 43a9caa221 expose variables for number of global events per simulated second,
millisecond, microsecond, etc. so that the user can explicitly
convert between system ticks and time and know what sorts of
expensive operations are being used for that conversion.

arch/alpha/alpha_tru64_process.cc:
arch/alpha/pseudo_inst.cc:
dev/etherdump.cc:
dev/etherlink.cc:
dev/ns_gige.cc:
dev/sinic.cc:
dev/tsunami_io.cc:
dev/uart.cc:
sim/stat_control.cc:
sim/syscall_emul.hh:
    Use the new variables for getting the event clock
dev/etherdump.hh:
    delete variables that are no longer needed.

--HG--
extra : convert_revision : d95fc7d44909443e1b7952a24ef822ef051c7cf2
2005-03-29 07:55:44 -05:00
Nathan Binkert 257be74341 Formatting fixes
--HG--
extra : convert_revision : 9a726945b7a1decbecf460df6714257b88742dc8
2005-03-23 22:58:47 -05:00
Lisa Hsu d40a1c6573 Some changes to NSGigE's DPRINTF's that helped when I was doing NAT stuff.
--HG--
extra : convert_revision : d36c84a835667d4c67f46432a90b9557b0710eac
2005-03-16 13:55:58 -05:00
Ali Saidi 76e6dd01ae Merge zizzer:/bk/m5 into zeep.eecs.umich.edu:/z/saidi/work/m5
--HG--
extra : convert_revision : 9eed6f31249ff099464044b32b882b3cc041b57a
2005-03-14 15:38:26 -05:00
Lisa Hsu 81169916aa print the daddr to pciconfigall DPRINTF.
--HG--
extra : convert_revision : d13ce459d5dac026e596f0bb3ba801b1dbed9ed0
2005-03-14 11:16:27 -05:00
Ali Saidi c977d2a02b remove addr from PciConfigDevice since it's not used
Random some small config file stuff

dev/pcidev.cc:
objects/Pci.mpy:
    remove addr since it's not used

--HG--
extra : convert_revision : aeb5993552d65a5e3b57f393bcb7d8aaadf6b5a2
2005-03-11 19:34:35 -05:00
Lisa Hsu 21946f0710 fix typo in the fixed etherlink serialization.
dev/etherlink.cc:
    fix type in serialization.

--HG--
extra : convert_revision : 87f47db14b90f414fef9a0db869da4d7ef72216a
2005-03-09 11:04:19 -05:00
Nathan Binkert b9c847563d Fix serialization of the EtherLink object
dev/etherlink.cc:
    - The EtherLink::Link object is no lonver serializable, so it is now
    necessary to prepend the object's name (as determined by the parent)
    to all parameters.
    - Fix the serialization of the LinkDelayEvent so it actually works
    - Rename some variables to make serialization simpler
dev/etherlink.hh:
    - Make the EtherLink::Link object *not* derive from serializeable.
    Instead, the serialize function will take a base name from
    the parent EtherLink object and prepend that base name to each of
    its variable names when serializing.  This is similar to the
    PacketData and PacketFifo classes.
    - Make the EtherLink::Link object keep a pointer to its parent and its
    link number so the LinkDelayEvent can be properly serialized.
    - Rename some variables to make serialization simpler.

--HG--
extra : convert_revision : e5aa54cd9e07b5e033989809100e1640abfb8bed
2005-03-08 12:47:55 -05:00
Nathan Binkert 92ed0dffc0 formatting fixes
--HG--
extra : convert_revision : 8b9bfed29b66e8bce11448f175273f5ebb6876b2
2005-02-21 17:32:57 -05:00
Ali Saidi 538d7d19c8 Merge
--HG--
extra : convert_revision : 10c28ac66c7e71615a239783e21ab36a47de992c
2005-02-13 23:05:47 -05:00
Ali Saidi 57482491c5 build mysql version if libraries exist
add dprintf on alignment faults
fix RR benchmark rcS script name
Add Dual test without rcS script
Update Monet to be closer to the real thing
Fix p4/monet configs
Add a way to read the DRIR register with at 32bit access for validation

SConscript:
build/SConstruct:
    always use mysql if the libraries are installed
arch/alpha/alpha_memory.cc:
    Add a DPRINTF to print alignment faults when they happen
dev/tsunami_cchip.cc:
    Add a way to read the DRIR for validation.

--HG--
extra : convert_revision : 8c112c958f36b785390c46e70a889a79c6bea015
2005-02-13 23:03:04 -05:00
Nathan Binkert 06a4686af9 Rework the command line paramters for python output and how
output files and the output directory are are handled.  Make
the output directory configuration via a command line parameter,
or an environment variable.

SConscript:
    Add new output file stuff
base/misc.cc:
dev/simconsole.cc:
    use new output file code
cpu/base_cpu.cc:
    use new output file code to generate output streams
dev/etherdump.cc:
    use the output file code to find the output directory
    use a real stream instead of a pointer
dev/etherdump.hh:
    use a real stream instead of a pointer
objects/Root.mpy:
    output_dir and config_output_file are not longer configured here.
sim/main.cc:
    - Completely rework the command line argument passing to deal with
    changes in python and output files.
    - Update help output to reflect changes.
    - Remove all direct support for .ini files.  They are strictly
    for intermediate representation.
    - Remove the --foo:bar=blah syntax for .ini files and add --foo.bar=blah
    syntax for python.  This will generate: foo.bar = 'blah' in the python
    script.
    - Add '-d' to set the output directory.
    - Use new output file code to access the output stream.
sim/serialize.cc:
    use the new code to find the output directory
sim/universe.cc:
    Get rid of makeOutputStream.  Use the new output file code.
    Remove output_dir and config_output_file as parameters.

--HG--
extra : convert_revision : df2f0e13d401c3a60cae1239aa1ec3511721544d
2005-02-11 09:47:41 -05:00
Ali Saidi 7e559f6c50 Add Monet configuration, update p4 parameters, couple of typo fixes
dev/tsunami_cchip.cc:
    add a fake register to tsunami that we can do 32bit reads to.
    Warn on access.

--HG--
extra : convert_revision : d87860f3b527528151c23431556039bca6e12945
2005-02-03 23:50:57 -05:00
Nathan Binkert 936ad58402 small python config related fixes.
dev/simconsole.cc:
sim/universe.cc:
    isValid isn't compatible with new python stuff, so whack it.

--HG--
extra : convert_revision : 0c50038769a558650479c51122a8be5d92e7d9c4
2005-02-03 14:33:02 -05:00
Ali Saidi da269014da removed all tsunami dependence on tlaserreg.h (RTC defines) and
all but tlaser_node.cc dependence on tlaserreg.h

dev/tsunami_io.cc:
dev/tsunamireg.h:
    removed tlaserreg.h

--HG--
extra : convert_revision : 148a5d79530e5ed721a49279f684a48041deed2b
2005-01-30 16:58:39 -05:00
Kevin Lim e6b99b0768 Merge zizzer.eecs.umich.edu:/bk/m5
into zamp.eecs.umich.edu:/z/ktlim2/m5-patched/m5-new

--HG--
extra : convert_revision : e802c800a478c297d3aa780a9ea3c6701453d91d
2005-01-21 18:31:30 -05:00
Ron Dreslinski 7f10e948a5 Merge zizzer:/z/m5/Bitkeeper/m5
into zazzer.eecs.umich.edu:/z/rdreslin/m5bk/new_config

--HG--
extra : convert_revision : 8c87cd948d501b1fc58d57f1f505d1f72725ecde
2005-01-21 04:55:55 -05:00
Ron Dreslinski 867d80d55d Fix annoying bug that lead to dropped packets in the P4 system
dev/pktfifo.cc:
    Make it so that we don't unserialize the size of the fifo, clobering the fact that we were trying to make it bigger, and leading to a misleading config.out that states the un-overwritten max_size.
    Perhaps this should instead be a panic if the size (amount that was serialized) is bigger than the maxsize that was assigned by the configuration file.

--HG--
extra : convert_revision : d4b0527bfd7a584554ddc87c9b2103f7a3a72332
2005-01-21 04:55:43 -05:00
Ali Saidi 29789443ba Merge zizzer:/bk/m5 into zeep.eecs.umich.edu:/z/saidi/work/m5
--HG--
extra : convert_revision : d5e6f6e696d7607f89894856d940afc89ae8e37b
2005-01-19 18:40:09 -05:00
Ali Saidi 886f905785 added total bytes/bandwidth/packets formulas to nics
cleaned up stability code and wrote some better help for stats.py
fixed sample bug in info.py

dev/ns_gige.cc:
dev/ns_gige.hh:
dev/sinic.cc:
dev/sinic.hh:
    add total bandwidth/packets/bytes stats
util/stats/info.py:
    fixed samples bug
util/stats/stats.py:
    cleaned up stability code and wrote a bit better help

--HG--
extra : convert_revision : cae06f4fac744d7a51ee0909f21f03509151ea8f
2005-01-19 18:40:02 -05:00
Kevin Lim 6ac7954242 Merge zizzer.eecs.umich.edu:/bk/m5
into zamp.eecs.umich.edu:/z/ktlim2/m5-patched/m5-new

--HG--
extra : convert_revision : 3b9413a6861eaddb8de753d76e217106d41cc347
2005-01-19 16:34:35 -05:00
Ron Dreslinski 10371be698 Fix serialization of txPacket (need to properly calculate the length before serialization)
--HG--
extra : convert_revision : e93321495d19afb86949daf2c14102ffb6bcef41
2005-01-19 16:26:19 -05:00
Nathan Binkert b65f365474 fix unserialization of PacketFifo
dev/pktfifo.cc:
    fix unserialization.  calling resize on a list just sticks
    uninitialized garbage into the list.

--HG--
extra : convert_revision : 1cbff596dd0b88560e23b9368ec75a7369beb9d9
2005-01-19 12:43:06 -05:00
Kevin Lim aed3e6780a Merge changes to make m5 g++ 3.4 compatible.
sim/param.cc:
    Merge changes.

--HG--
extra : convert_revision : b5044e1f7c48ae2d74d5233dd4fabfb7a801d7c8
2005-01-18 13:02:47 -05:00
Nathan Binkert 3ece6ab029 New and improved configuration mechanism. No more writing of
wierd ini files.  The ini files are still used as an intermediate step,
but a sophisticated python library exists to help build them more
easily.

SConscript:
    add the new embedded file stuff
    remove all of the old object description junk
base/inifile.cc:
base/inifile.hh:
    get rid of findDefault and findAppend since they were the source
    of much evil.
base/trace.cc:
    For now, if we don't have the dprintf_stream set up, dump
    to standard out.  We probably want a command line option
    for this.
dev/alpha_console.cc:
    PioDevice now takes a platform parameter.
    All PioDevices must have a pio_latency parameter.  We stick
    a dummy parameter in here for now until we get rid of the
    builder stuff.
dev/alpha_console.hh:
    don't need Platform anymore
dev/baddev.cc:
    PioDevice now takes a platform parameter.
    All PioDevices must have a pio_latency parameter.  We stick
    a dummy parameter in here for now until we get rid of the
    builder stuff. Same for the platform parameter, though we just
    pass the PioDevice a null parameter since it isn't used by
    this device and it's quicker.
dev/baddev.hh:
    fix #include guards
dev/etherlink.cc:
    rename parameters.
dev/ethertap.cc:
    rename parameters
dev/ide_ctrl.cc:
    All devices need an address even if it will get overwritten later.
dev/ide_disk.cc:
    use an enum for the drive ID stuff.
    rename disk_delay -> delay
    Actually, I think that we should implement "cable select" and
    have the controller tell the drive what it is.
dev/io_device.cc:
dev/io_device.hh:
    All IO devices take a Platform *
dev/ns_gige.cc:
    all devices need an io_bus.  rename header_bus to io_bus
    We don't need stuff for the interrupt controller since
    it's all in the platform now.
dev/ns_gige.hh:
    We don't need stuff for the interrupt controller now since
    it's all in the platform.
dev/pciconfigall.cc:
    Pass a dummy NULL to the PioDevice for the platform since
    we don't need one.
dev/pcidev.cc:
    Move a bunch of common functionality into the PciDev
dev/platform.hh:
    remove unneeded code
dev/tsunami.cc:
    remove unused param
dev/tsunami_cchip.cc:
    pass platform pointer
dev/tsunami_io.cc:
dev/tsunami_pchip.cc:
dev/uart.cc:
    pass platform variable
dev/uart.hh:
    don't need to keep a platform pointer.  it's in the base class
kern/linux/linux_system.cc:
kern/tru64/tru64_system.cc:
    rename some parameters
sim/builder.cc:
    clean up builder code. use more parameters from the
    config node.  all sections with a type= are now created,
    the old mechanisms no longer work
sim/builder.hh:
    remove some extra variables since they are found in the ConfigNode
sim/main.cc:
    add a quick hack command line argument -X to dump out the
    embedded files.  (probably should be fixed up a little.)
    accept .mpy files
    printing to the streams has to happen after the hierarchy
    is built since we're moving away from param contexts
sim/param.cc:
    add parsing support for ranges
sim/process.cc:
    isValid isn't very useful anymore.  interpret the names
    stdout, stderr, cout, cerr for the file descriptors
sim/pyconfig/SConscript:
    Add Action handlers for creating an embedded python file
    and for creating an embedded C file.

    use these action handlers to embed all objects found in the objects
    tree into the binary along with the importer and the m5config stuff
sim/pyconfig/m5config.py:
    Major changes to the original configuration file generator.  These
    changes largely involve implementing copy-on-write like semantics
    for all of the SimObjects.  Real documentation must be written.
sim/universe.cc:
    Universe becomes a SimObject since we don't really have the notion of
    param contexts in the python code.

--HG--
rename : sim/pyconfig/m5configbase.py => sim/pyconfig/m5config.py
extra : convert_revision : c353453e5beb91c37f15755998fc0d8858c6829a
2005-01-15 04:12:25 -05:00
Kevin Lim f58d85128d Fixes so m5 compiles on gcc 3.4, which has much stricter syntax. Most changes come from templated code,
which is evaluated slightly differently than in previous versions of gcc.

arch/alpha/alpha_linux_process.cc:
    Alphabetize includes.
arch/alpha/vptr.hh:
    Change the constants that are being used for alpha pagebytes to come from the ISA.
base/random.hh:
cpu/static_inst.cc:
sim/param.cc:
    Fix up template syntax.
base/range.hh:
    Include iostream for << operator.
base/res_list.hh:
base/statistics.hh:
cpu/simple_cpu/simple_cpu.hh:
cpu/static_inst.hh:
sim/eventq.hh:
sim/param.hh:
    Fixup for templated code to resolve different scope lookup in gcc 3.4.  This defers the lookup of the
    function/variable until actual instantiation time by making it dependent on the templated class/function.
base/trace.cc:
    Fix call to new.
base/trace.hh:
    Fix up #define to have full path.
cpu/base_cpu.cc:
    Fix up call to new.
dev/etherlink.hh:
dev/ns_gige.hh:
dev/sinic.hh:
    Fixup for friend class/function declaration.  g++ 3.4 no longer allows typedefs to be declared as
    a friend class.
dev/pcidev.hh:
    Fix up re-definition of access level to params.
kern/linux/linux_syscalls.hh:
kern/tru64/tru64_syscalls.hh:
    Fix up header.  Fix up template syntax.
sim/serialize.cc:
    Include errno.h.
sim/startup.cc:
    Change startupq.  queue was getting destructed before all things had called ~StartupCallback(), which lead
    to a segfault.  This puts startupq in global space, and we allocate it ourselves.  Other code may be similar
    to this and may need changing in the future.
sim/syscall_emul.hh:
    Include cpu/exec_context.hh and sim/process.hh, as forward declarations are no longer sufficient.
sim/universe.cc:
    Include errno.h

--HG--
extra : convert_revision : e49d08ee89eb06a28351f02bafc028ca6652d5af
2005-01-14 18:34:56 -05:00
Steve Reinhardt f3e89d3991 Change Bus template parameter to BusType (to avoid confusion with Bus class).
Change Mem template parameter to MemType while we're at it.

dev/io_device.hh:
    Change Bus template parameter to BusType (to avoid confusion with Bus class).

--HG--
extra : convert_revision : dca8effb177535b3624ef08a3d3b8afab720390b
2004-12-09 01:07:08 -05:00
Ali Saidi 34260bbf0d Add support for Tsunami with 64 processors
base/socket.cc:
    Make panic print a more worthwhile message
dev/tsunami.hh:
    Change max number of tsunami cpus to be 64
dev/tsunamireg.h:
    Add new registers and register blocks for 64 cpu tsunami

--HG--
extra : convert_revision : 3ceaaa998518ded8613bc64edc04cb9120fd3d15
2004-12-06 12:06:16 -05:00
Ali Saidi 244ce7fb29 Print a warning if two devices are sharing the same interrupt
Update profile-top to print 2 or 4 graphs depending on a command line
option

dev/pciconfigall.cc:
dev/pciconfigall.hh:
dev/pcidev.hh:
    Print a warning if two devices are sharing the same interrupt

--HG--
extra : convert_revision : 0ef99cac92fbf2916ab8e5b1125d520eb4b5ac7d
2004-11-22 22:32:37 -05:00
Nathan Binkert 4ef2cd862d Merge zizzer.eecs.umich.edu:/z/m5/Bitkeeper/m5
into zizzer.eecs.umich.edu:/.automount/ziff/z/binkertn/research/m5/latest

--HG--
extra : convert_revision : 3127ab9f076b5ecce897a1c7de2678b58b73f7fb
2004-11-18 16:23:32 -05:00
Nathan Binkert 86836124ed always initalize the size of a packet (forgotten on checkpoints
in some places).  use the constructor for setting the size.

--HG--
extra : convert_revision : fad322c1d45b1952804cf35942b5685d70128e59
2004-11-18 16:23:31 -05:00
Lisa Hsu a8a7eb1c2f add a bunch of stats for interrupt classification, coalescing characterization, and dropped packets.
--HG--
extra : convert_revision : 421af424ec104afc352c073408a166fce6a31c70
2004-11-18 15:46:01 -05:00
Nathan Binkert 98ca4fa600 serialization fix for the NS GigE driver
dev/ns_gige.cc:
    We need to serialize the rxFragPtr

--HG--
extra : convert_revision : 1f68c9d7ae2dbeea69e60d988ea6392622104f52
2004-11-17 21:03:51 -05:00
Nathan Binkert 797661b6e1 fix sinic unserialization
dev/sinic.cc:
    we only use one address range in the sinic

--HG--
extra : convert_revision : daa730a34ac9c9264060431556a1c5caa3252c5e
2004-11-17 16:24:58 -05:00
Nathan Binkert 5f6328d9c6 properly implement the fifo _reserved stuff.
dev/pktfifo.cc:
    need to checkpoint _reserved
dev/pktfifo.hh:
    When clearing, clear _reserved
    size() is used for determining how many bytes are in the fifo
    ready to be pulled, so we don't want to add _reserved
    avail() on the other hand is used for determining how much
    free space is in the fifo for adding packets.
    adjust the implementation of empty() and full() to reflect this.

--HG--
extra : convert_revision : 3281972b4b70ea5833d39ae7ce1e73648b3573b0
2004-11-17 01:27:08 -05:00
Nathan Binkert c43c3f2af3 initialize _reserved
--HG--
extra : convert_revision : a0f98c135734602b1d4b0890d8ff8cecc0e42f88
2004-11-17 00:28:42 -05:00
Nathan Binkert a109296bde Fix a bug where we would improperly calculate if the FIFO was
full by adding a reserve feature to the packet fifo which allows
us to reserve space in the fifo if only part of a packet was
copied into the fifo.

dev/ns_gige.cc:
    use the new reserve feature in the fifo to properly determine
    when we're full.  assert that adding a packet to the fifo suceeds.
dev/pktfifo.hh:
    add the ability to reserve space in the fifo.  This is useful for
    partial writing of packets into the fifo.

--HG--
extra : convert_revision : 83f871f34fac237bb464c9513cf6490b5c62420e
2004-11-16 23:59:51 -05:00
Steve Reinhardt 2e0695ec9a Get rid of obsolete sim/sim_stats.* files (looks like these
are replaced by sim/stats.hh and sim/stat_control.*)

dev/ns_gige.cc:
dev/sinic.cc:
    Include sim/stats.hh instead of sim/sim_stats.hh

--HG--
extra : convert_revision : 5e07932eab45ae4fb719baa4f94c5f62092a8446
2004-11-13 21:13:25 -05:00
Nathan Binkert 7e4229fb8f Add the Simple Integrated Network Interface Controller
--HG--
extra : convert_revision : 2bce25881a104e8282a5ed819769c6a7de414fb2
2004-11-13 17:10:48 -05:00
Nathan Binkert 9f8db6f446 don't handle device specific configuration stuff in the base
class.  While we're at it, very minor formatting.

--HG--
extra : convert_revision : b7c719f92ece7234838434294b33833289adbada
2004-11-13 17:05:13 -05:00
Nathan Binkert 4760ae46c6 Use the new PacketFifo class to avoid manual calculations
--HG--
extra : convert_revision : afa193904b7ed4d5e5c50e9dcb78e8e855b00ecc
2004-11-13 16:52:08 -05:00
Nathan Binkert 8922d69953 change the serialization of a packet so that we don't
do a nameOut.  This fixes a subtle bug in serialization that
can pop up.

--HG--
extra : convert_revision : b52df977dcbef1c9bd0d4405ba0b36dff3737cdf
2004-11-13 16:46:56 -05:00
Nathan Binkert acb98fb0f6 we shouldn't ever pass around references to PacketPtrs,
const references are ok, or pass by value.

--HG--
extra : convert_revision : 7280a1c7d22b9294fddbe50f02f6f4c6ca9b2e5b
2004-11-13 16:33:16 -05:00
Nathan Binkert bd3e3c0230 forgot a change in the previous commit. the ide controller
doesn't have its own interrupt functions

dev/ide_ctrl.hh:
    oops. we don't have our own interrupt functions anymore
    we get them from the base class.

--HG--
extra : convert_revision : 3eac228ec59f4fea0b0e49f961e8b21705dee27f
2004-11-13 16:24:47 -05:00
Nathan Binkert b031888038 Use parameter structs for initialization so it's easier
to add new devices.  Abstract the Platform more so that
it is unnecessary to know know platform specifics for
interrupting or translating PCI DMA addresses.

dev/ide_ctrl.cc:
    convert to parameter struct for initialization
    use the interrupt functions in the PciDev base class
    convert from tsunami to using platform
    We don't need an interrupt controller here.
dev/ide_ctrl.hh:
    don't use Tsunami, use Platform
    make the IdeDisk a friend so that it can access my plaform
    convert to parameter struct for construction
dev/ide_disk.cc:
    don't use tsunami references, but platform references
dev/ns_gige.cc:
    Convert to parameter struct for initialzation. Use code in
    base class for interrupts so we don't need to know anything
    about the platform. Don't need an IntrControl *.
dev/ns_gige.hh:
    We don't need a Tsunami * anymore
    convert to a parameter struct for construction
dev/pcidev.cc:
    deal with new parameter struct
dev/pcidev.hh:
    - Move all of the configuration parameters into a param struct
    that we can pass into the constructor.
    - Add a Platform * for accessing new generic interrupt post/clear
    and dma address translation fuctions
    - Create functions for posting/clearing interrupts and translating
    dma addresses
dev/platform.cc:
    have default functions that panic on pci calls
dev/platform.hh:
    don't make the pci stuff pure virtual, but rather provide
    default implementations that panic.  Also, add dma address
    translation.
dev/tsunami.cc:
    this-> isn't necessary here.
    add pci address translation
dev/tsunami.hh:
    implement the pciToDma address translation

--HG--
extra : convert_revision : 7db27a2fa1f1bd84704921ec7ca0280b5653c43e
2004-11-13 15:45:22 -05:00
Nathan Binkert e9f3279334 sort #includes
don't need to include ev5.hh anymore

--HG--
extra : convert_revision : f80d2767936d3fb07a9cb7fd4709cafe9ea93e63
2004-11-13 14:46:02 -05:00
Nathan Binkert 425dda00df Macros are nasty, so let's get rid of them. Convert all
all macros in ev5.hh to inline functions or constant typed
variables and make them follow our style while we're at it.

All of the stuff in this file actually belongs in the ISA
traits code, but this is a first step at getting things done
in the right manner.

arch/alpha/alpha_memory.cc:
arch/alpha/alpha_memory.hh:
arch/alpha/ev5.cc:
arch/alpha/isa_desc:
dev/ns_gige.cc:
kern/tru64/tru64_events.cc:
    deal with changes in ev5.hh
arch/alpha/ev5.hh:
    Macros are nasty, so let's get rid of them.  Convert all
    all macros to inline functions or constant typed variables.
    Make them follow our style while we're at it.

    All of the stuff in this file actually belongs in the ISA
    traits code, but this is a first step at getting things done
    in the right manner.
arch/alpha/isa_traits.hh:
    move some of the ev5 specific code into the isa
arch/alpha/vtophys.cc:
base/remote_gdb.cc:
    deal with isa addition
cpu/exec_context.hh:
    be less isa specific and use the isa traits to figure out
    what we can.
dev/alpha_console.cc:
dev/pciconfigall.cc:
dev/tsunami_cchip.cc:
dev/tsunami_io.cc:
dev/tsunami_pchip.cc:
dev/uart.cc:
    deal with changes in ev5.hh
    I don't believe this masking is actually necessary.  We should
    look at removing it later.
dev/ide_ctrl.cc:
    sort #includes
    deal with changes in ev5.hh

--HG--
extra : convert_revision : c8a3adf0a4b1d198aefe38fc38b295abf289b08a
2004-11-13 14:01:38 -05:00
Ali Saidi be0184b463 Merge zizzer:/bk/m5 into zeep.eecs.umich.edu:/z/saidi/work/m5-smp
--HG--
extra : convert_revision : 59173b5d4599cfe1cbaa96705e9731ee5a8d8647
2004-10-25 18:15:28 -04:00
Ali Saidi 3402411661 changes to make interrupts part of the platform rather than tsunami
specific

--HG--
extra : convert_revision : f51788dd41c23f13b253268bb2b286a5225ef087
2004-10-25 18:14:13 -04:00
Nathan Binkert a7fd7729ab flesh out the TCP/IP/Ethernet support
base/refcnt.hh:
    reorganize the RefCountingPtr a little bit to make it easier
    to derive from
dev/etherpkt.hh:
    this doesn't belong here. use the inet.hh stuff
dev/ns_gige.cc:
dev/ns_gige.hh:
    use newer features in the tcp/ip/ethernet stuff

--HG--
extra : convert_revision : 32c1953c95655c1f4c70e0d8adedfd94beead624
2004-10-23 16:18:44 -04:00
Nathan Binkert 833c5b5ef4 get rid of some unused variables
--HG--
extra : convert_revision : 187cee0e0bad09bbaff059eb60f20d7d32c1b52c
2004-10-23 13:11:42 -04:00
Nathan Binkert 224acc2abc get rid of pmap.h and make things variables and inline
functions instead of preprocessor macros.

arch/alpha/vtophys.cc:
    use new constants, functions and structs to clean up the
    vtophys code.
arch/alpha/vtophys.hh:
    Clean up a little bit and make the protypes match new changes.
base/remote_gdb.cc:
dev/ide_disk.cc:
kern/tru64/tru64_events.cc:
    use new constants from isa_traits.hh instead of ones from
    old pmap.h

--HG--
extra : convert_revision : 5dce34e3b0c84ba72cefca34e5999b99898edcef
2004-10-23 10:41:35 -04:00
Nathan Binkert b881408ed7 Clean up the Range class and associated usages. The code was
never clear about whether the end of the range was inclusive
or exclusive.  Make it inclusive, but also provide a RangeSize()
function that will generate a Range based on a start and a size.
This, in combination with using the comparison operators, makes
almost all usages of the range not care how it is stored.

base/range.cc:
    Make the end of the range inclusive.

    start/end -> first/last
    (end seems too much like end() in stl)
base/range.hh:
    Make the end of the range inclusive.

    Fix all comparison operators so that they work correctly with
    an inclusive range.  Also, when comparing one range to another
    with <, <=, >, >=, we only look at the beginning of the range
    beacuse x <= y should be the same as x < y || x == y.  (This wasn't
    the case before.)

    Add a few functions for making a range:
    RangeSize is start and size
    RangeEx is start and end where end is exclusive
    RangeIn is start and end where end is inclusive

    start/end -> first/last
    (end seems too much like end() in stl)
dev/alpha_console.cc:
dev/baddev.cc:
dev/ide_ctrl.cc:
dev/ns_gige.cc:
dev/pciconfigall.cc:
dev/pcidev.cc:
dev/tsunami_cchip.cc:
dev/tsunami_io.cc:
dev/tsunami_pchip.cc:
dev/uart.cc:
    Use the RangeSize function to create a range.

--HG--
extra : convert_revision : 29a7eb7fce745680f1c77fefff456c2144bc3994
2004-10-22 01:34:40 -04:00
Steve Reinhardt f267dc4a87 Clean up/standardize handling of various output files.
No more non-intuitive behavior shifts depending on whether
outputDirectory is set (at the expense of backwards compatibility).
outputDirectory is now always valid, defaults to ".".

dev/etherdump.cc:
    Use makeOutputStream() to create output file.
    New behavior: actually complain if dump file can't
    be opened, instead of quietly ignoring the problem.
dev/etherdump.hh:
dev/simconsole.cc:
dev/simconsole.hh:
    Use makeOutputStream() to create output file.
sim/builder.cc:
sim/builder.hh:
sim/main.cc:
    builderStream() is now *configStream.
sim/serialize.cc:
    outputDirectory is now always valid, no need to check.
sim/universe.cc:
    Clean up/standardize handling of various output files.
    No more non-intuitive behavior shifts depending on whether
    outputDirectory is set (at the expense of backwards compatibility).
    outputDirectory is now always valid, defaults to ".".
    New function makeOutputStream() does "the right thing" to
    associate a stream with a filename.

--HG--
extra : convert_revision : a03c58c547221b3906e0d6f55e4a569843f2d646
2004-10-19 20:00:20 -04:00
Ali Saidi 3ef950abba Fixes for bigendian platforms
arch/alpha/vtophys.cc:
    PGOFSET -> ALPHA_PGOFSET to avoid include file problems
base/callback.hh:
    Added  a class to create a callback from a function
base/intmath.hh:
    make FloorLog2 inlined
dev/pcidev.cc:
    more work in getting pciconfig space happy with different endiannesses
dev/uart.cc:
    used an incorrect size for write uint64_t instead of uint8_t
sim/system.cc:
    when writing things into system data structures we need to pay
    attention to endianness

--HG--
extra : convert_revision : 52f441b5789c45db30ef2f6fd4975cbc7323a381
2004-10-16 19:10:51 -05:00
Nathan Binkert 1d02345a24 a bit more cleaning of the network header wrappers.
base/inet.hh:
    add functions to the various headers to grab the most common
    encapsulated protocols.  This could easily get out of hand, but
    we're just worrying about tcp, udp, and ip for now.

    add common functions size(), bytes(), and payload() to all wrappers.
    size() gets the header size
    bytes() returns a uint8_t * to the beginning of the header
    payload() returns a uint8_t * to the beginning of the payload.
dev/etherpkt.cc:
dev/etherpkt.hh:
    don't cache pointers to headers.  It's probably not worth the
    hassle.

--HG--
extra : convert_revision : ba9df85ac019b8a48233042dde79fb9da9546410
2004-09-21 01:41:55 -04:00
Nathan Binkert a58b834c8e Clean up network header stuff and make it more generic. Use
libdnet when we can instead of our own home grown stuff.

SConscript:
    separate the crc code into its own file
base/inet.cc:
    move the crc stuff to crc.cc
    add generic code for calculating ip/tcp/udp checksums
base/inet.hh:
    -  move crc stuff to crc.hh
    -  #include all of the libdnet stuff.  (this makes base/inet.hh the
    only file you need to include if you want to use this kind of stuff.)
    -  Wrap some of the libdnet structs to get easier access to structure
    members.  These wrappers will automatically deal with masking/shifting/
    byte-swapping.
base/refcnt.hh:
    If one derives from RefCountingPtr, they should have access to
    the internal data pointer.
build/SConstruct:
    make #include of dnet stuff work
dev/etherlink.cc:
dev/ethertap.cc:
dev/ethertap.hh:
    EtherPacket -> PacketData
dev/etherpkt.cc:
    EtherPacket -> PacketData
    add a function for populating extra info about a packet.
    Basically just gives pointers to ethernet/ip/tcp/udp headers
    if they exist.
dev/etherpkt.hh:
    EtherPacket -> PacketData
    remove most of the packet header stuff from teh PacketData
    class and just add a few generic functions for grabbing various
    headers that may exist in the packet.  The old functionality is
    contained in the headers.
dev/ns_gige.cc:
    -  IP -> Ip, UDP -> Udp, TCP ->Tcp when used in variable names
    -  get rid of our own byte swapping functions.
    -  whack checksum code and use libdnet version.
    -  Get pointers to the various packet headers and grab info from
    those headers.  (The byte swapping in the headers now.)
    -  Add stats for Udp Checksums
dev/ns_gige.hh:
    use libdnet for checksum code.
    IP -> Ip, TCP -> Tcp in variable names
    add stats for UDP checksums

--HG--
extra : convert_revision : 96c4160e1967b7c0090acd456df4a76e1f3aab53
2004-09-20 10:43:53 -04:00
Ali Saidi 23e0643c69 Updates to make SMP work.
dev/tsunami_cchip.cc:
    updates to ipi handling chipset code
sim/system.cc:
    debugSymbolTable, now has symbols from pal, console, and linux

--HG--
extra : convert_revision : c981d857f7e3d75f4c46172809e6d14e5f0a1238
2004-08-31 23:47:57 -04:00
Nathan Binkert 0b0a6778c9 Fixup interrupting of the ethernet device.
dev/ns_gige.cc:
    clean up the interrupt handling code so that it is simpler and
    less prone to bugs.  I hope I removed the bug where the:
    assert(intrTick >= curTick || intrTick == 0); would get triggered.
    I'm pretty sure that was due to intrTick not being cleared when
    the interrupt was cleared.

    This code probably still needs to be looked at more closely to
    make sure interrupts are not missed.

--HG--
extra : convert_revision : 61e2eb043540f2534a80c9b633006a71e7d6e282
2004-08-20 11:40:57 -04:00
Nathan Binkert 40174f119d cleanup interrupt code for gigabit device
dev/ns_gige.cc:
    Clean up the interrupt code.  Do a better job determining when
    coalescing should happen.
    Remove some bogus comments
    Stop using magic numbers in initialization and comment what
    the various numbers do
dev/ns_gige_reg.h:
    #define describing which interrupts cannot be delayed and
    which interrrupts we don't implement

--HG--
extra : convert_revision : eb196afa0bf448e1849dd2bd30dde32134effee7
2004-08-11 10:14:26 -04:00
Nathan Binkert 256afbbe26 std::
--HG--
extra : convert_revision : 8383048265ef5b4d7c995dbf44f7d85e349ddbde
2004-08-11 09:05:13 -04:00
Nathan Binkert a3a1b4dbae better debugging
dev/ns_gige.cc:
    Make all DPRINTF statements take one line. If they need two lines,
    break them up into separate statements.  This makes grep much more
    effective since *every* line will be prefixed by the cycle that the
    trace message is from and the object that caused the message.
    normalize some debugging statements so that searching is easier
    (e.g. always say rxState, not rx state or receive state)
    break into the debugger when a packet is dropped since we don't really
    like dropping packets.

--HG--
extra : convert_revision : 9cf309ca2143a6b8c8215ac5dd6a31aae60173cd
2004-07-30 11:33:45 -04:00
Nathan Binkert e60a4c58ee Fix a few bugs in the receive state machine. In doing back to tracking
whether or not the state machine is enabled rather than tracking the
specific instance of trying to halt the state machine.

dev/ns_gige.cc:
    change back to tracking the state machine's enableness instead of
    whether or not it is trying to halt.  Also fix a major bug that
    would cause the NIC to drop packets when the rx state machine was
    idle, but enabled.
    Fix a couple other bugs in the state machine where the idle interrupt
    would happen at the wrong time.
    Add a warning to deal with improper values of intrTick
dev/ns_gige.hh:
    We need to keep track of whether the state machine is enabled
    or not separately from the control register since the bits don't
    always reflect the truth.

--HG--
extra : convert_revision : 20056b225fa62a0744473babfd693506aa5f29b2
2004-07-30 11:29:45 -04:00
Nathan Binkert 8f87a57e70 make all ethernet dma use the new interface
--HG--
extra : convert_revision : 1cab883fac2bffd83cb035ebf28958c15118dfdc
2004-07-30 11:17:20 -04:00
Nathan Binkert f1f85c5470 better debugging of DMA operations
dev/ns_gige.cc:
    use the new PhysicalMemory dma_read and dma_write functions

--HG--
extra : convert_revision : 427049d43355f02ac8bdfe2e60c24825dd734006
2004-07-30 11:09:03 -04:00
Nathan Binkert da2566f014 style
--HG--
extra : convert_revision : 7489726b6c7bd11af603a448e4ff56c1e46139fe
2004-07-26 23:10:20 -04:00
Nathan Binkert 0650e4a43f When a packet has finished transmitting, kick the state
machine too.  The fifo may have been full and we want
to get another packet into it if we can.

--HG--
extra : convert_revision : 8f57294bd18f5eccb900118f2de83a4ccfd20dbb
2004-07-23 12:19:27 -04:00
Nathan Binkert 8844eadcdf notify the transmitter when the packet has finished transmitting.
--HG--
extra : convert_revision : 66f6f80945c1f621cdc3e743f601d2a73361bacd
2004-07-23 00:05:29 -04:00
Nathan Binkert c9e6a15196 Add support to store less than the full packet in an etherdump
and actually default to only storing a max of 96 bytes per
packet since that should be plenty to fit all of the headers in.

--HG--
extra : convert_revision : 0c4a6571d80536477ed166e695d957e39da0334e
2004-07-22 23:54:24 -04:00
Nathan Binkert 5b1da825d8 Wrap tracing stuff in #if TRACING_ON to avoid compile error
in m5.fast

--HG--
extra : convert_revision : 329d810bfe282e88133ca35da62ee6dcc73a38f5
2004-07-21 15:44:57 -04:00
Erik Hallnor a6939573ce Fix serialization when a tx interrupt isn't scheduled
dev/uart.cc:
    Fix serialization when a tx interrupt isn't scheduled.

--HG--
extra : convert_revision : 3029e284cbba417e3f453d83fdf2ef307d684916
2004-07-14 21:34:51 -04:00
Nathan Binkert 6f43d2b8d8 Fix infinite loop in ns_gige stat machine
argh!

dev/ns_gige.cc:
    Exit the state machine so that we don't come right back where
    we started and enter an infinite loop.

--HG--
extra : convert_revision : a5f2b5b5a692de6c80e4b02d7f9bc5d27fe17252
2004-07-14 09:02:15 -04:00
Nathan Binkert 13f8dc981f make the cache access latency a parameter that is based on bus
ticks for the most commonly accessed devices.

dev/baddev.cc:
    Get rid of the constant cache access latency.
    For unimportant devices, don't add any latency.
dev/ide_ctrl.cc:
dev/ide_ctrl.hh:
dev/ns_gige.cc:
dev/pciconfigall.cc:
dev/pciconfigall.hh:
dev/tsunami_cchip.cc:
dev/tsunami_cchip.hh:
dev/tsunami_io.cc:
dev/tsunami_io.hh:
dev/tsunami_pchip.cc:
dev/tsunami_pchip.hh:
dev/uart.cc:
dev/uart.hh:
    make the cache access latency a parameter that is based on bus
    ticks.
dev/io_device.cc:
dev/io_device.hh:
    add an io latency variable
dev/ns_gige.hh:
    this moved to io_device.hh

--HG--
extra : convert_revision : 4883130feeaef48abee492eddf0b8eb40eb94789
2004-07-12 22:58:22 -04:00
Lisa Hsu f857bd9dff make tx/rx fifo size a param, also fix the empty dma problem by adjusting the state machine.
dev/ns_gige.cc:
    make tx/rx fifo sizes a param. the default is 128K for each.  also, make the state machine not move onto txFragRead if there is no room in the txfifo for data.
dev/ns_gige.hh:
    make tx/rx fifo size a param

--HG--
extra : convert_revision : ed91eb31c2b21d4cdc6de87d8641df6197be5209
2004-07-12 16:09:52 -04:00
Andrew Schultz 4f4252fa89 Remove second pciToDma translation on current PRD address pointer b/c
second translation (which is superfluous) doesn't work properly when
system memory is higher than 128MB

--HG--
extra : convert_revision : 9cdf6925689d376953b1aa071bcd1e2f06419202
2004-07-09 22:32:27 -04:00
Lisa Hsu bbbfebd885 Merge zizzer.eecs.umich.edu:/bk/m5
into shizzle.(none):/home/hsul/work/m5clean

--HG--
extra : convert_revision : 78beb2735c6536ce3e639d59c99e755e9139f4f1
2004-07-09 11:50:40 -04:00
Lisa Hsu 7b2691d537 when you add caches, dma commands within the state machine are delayed and cause the state machine to exit until the dma comes back. thus, all relevant code must be executed BEFORE going to do the dma code.
dev/ns_gige.cc:
    rearrange code so nothing gets skipped when "doing dma."

--HG--
extra : convert_revision : cca66885f45e7df1831e2d8ccaddf5ece7600b13
2004-07-09 11:50:27 -04:00
Nathan Binkert 7c2084dcfe store the checkpoint to the proper directory
dev/disk_image.cc:
    store the disk checkpoint to the proper directory

--HG--
extra : convert_revision : f76347576691560f00c60b86ac2044960d5a193c
2004-07-08 15:59:46 -04:00
Lisa Hsu 19fd3439c7 tag each mem_req as coming from the nic if it is DMA'd from the NIC. the NIC tells the DMA interface, which in turn sets a new nic_req flag in the MemReq it makes.
dev/ns_gige.cc:
    tell all outgoing dma events that this request is from the NIC

--HG--
extra : convert_revision : 62af17a2728a0ff729e7723dc29bd0d130ca5fe3
2004-07-06 17:55:16 -04:00
Lisa Hsu 5bbd57917f these changes are an undo from my last changeset. these are meant for later.
--HG--
extra : convert_revision : 0126918ef293cba02aaaa61dff3c471eb4743116
2004-07-05 11:20:53 -04:00
Lisa Hsu 7ca7b343ff almost forgot to do this - hope it doesn't mess up schedule.
dev/ns_gige.cc:
dev/ns_gige.hh:
    add the stats nate wanted

--HG--
extra : convert_revision : b59d586def7df31741b53cdb59cf3b19253caf26
2004-07-04 16:47:07 -04:00
Lisa Hsu 31c52ac0a7 Merge zizzer.eecs.umich.edu:/bk/m5
into shizzle.(none):/home/hsul/work/linux-clean

--HG--
extra : convert_revision : a072c1560e1f8b5cac378ed5f047a8a9c86b97b9
2004-06-30 00:51:11 -04:00
Lisa Hsu 167c57f265 fix transmit side checksum offloading to not generate a pseudo header.
dev/ns_gige.cc:
    transmit side checksum offloading doesn't need pseudo header generation, it just takes the pseudo header checksum and uses it.

--HG--
extra : convert_revision : 9741bd650415c18ed37b06a453b23610d028135b
2004-06-30 00:50:56 -04:00
Ali Saidi 5a1340d046 Another fix for the too much work problem in 2.6. This should do it.
Both rx/tx interrupts are now scheduled for the future to give the
linux kernel time to get out of its loop.

--HG--
extra : convert_revision : 8fee0a25fde0ce0545c924f8547bed460602e006
2004-06-29 16:08:26 -04:00
Ali Saidi 38fe4d9a86 With the new uart code 300 cycles isn't quite enough, 350 seems to
work. When everything gets changed to seconds this should be updated.

--HG--
extra : convert_revision : 9f1064ff6fec5deceb591904f4571c9129ecc998
2004-06-28 21:23:10 -04:00
Nathan Binkert 19d5789db1 Don't serialize the absolute path so we can move checkpoints around.
sim/serialize.cc:
sim/serialize.hh:
    export the checkpoint directory

--HG--
extra : convert_revision : ba5b796fd930ab0487a502beefcf76bd6bb7c366
2004-06-28 15:54:05 -04:00
Ali Saidi c75eadc2b2 allow the use of old console code and update elf_object not to rely on EM_ALPHA value.
base/loader/elf_object.cc:
    EM_ALPHA value isn't official, so perhaps we shouldn't use it
dev/alpha_console.cc:
dev/alpha_console.hh:
    this change allows the use of old console code

--HG--
extra : convert_revision : cfacd64ae7fd2595158ca1a83ebcdb66ee7e119b
2004-06-27 14:33:55 -04:00
Ali Saidi 54b49f933a rewrote uart and renamed console.cc to simconsole to reduce confusion
base/traceflags.py:
    removed TsunamiUart/TlaserUart and added a plain Uart
dev/alpha_console.cc:
    updated for new simconsole
dev/platform.hh:
    added a uart member to platform
dev/simconsole.cc:
dev/simconsole.hh:
    removed lots of legacy code, it should all be ours now.
    converted tabs to 8 spaces
    added our copyright
dev/tsunami.cc:
    uses simconsole.hh rather than console.hh
dev/tsunami_cchip.cc:
dev/tsunami_io.cc:
    never needed console.hh
dev/tsunami_io.hh:
    this does need eventq.hh and it just happend to be working whenn console.hh was
    included everywhere
dev/tsunamireg.h:
    added a couple more 8250/16550 uart defines
dev/uart.cc:
    new uart code, rewritten to support both tlaser and tsunami (both a 8250 and 8530
    uart).
dev/uart.hh:
    updated for new uart, legacy code removed

--HG--
rename : dev/console.cc => dev/simconsole.cc
rename : dev/console.hh => dev/simconsole.hh
rename : dev/tsunami_uart.cc => dev/uart.cc
rename : dev/tsunami_uart.hh => dev/uart.hh
extra : convert_revision : e663352d49d4c2d3c95643030cf73c0e85ba2f08
2004-06-26 21:26:28 -04:00
Ali Saidi 4799a7b874 minor changes to endian code so that it runs on x86 linux
base/intmath.hh:
    only need FloorLog2(size_t) on a mac, so ifdefed for this
dev/alpha_console.cc:
    Actually allocate the alphaAccess struct.

--HG--
extra : convert_revision : 1f50b1a025c8ee728a9f3d2c603ea38347234f54
2004-06-23 18:39:11 -04:00