emu eth
TRANSCRIPT
-
7/29/2019 emu eth
1/12
ThisfilecontainsinformationabouttheSIMHEthernetpackage.
-------------------------------------------------------------------------------
TheXQemulatorisahost-independentsoftwareemulationofDigital'sDELQA-T(M7516-YM),DELQA(M7516)andDEQNA(M7504)Q-busEthernetcardsfortheSIMHemulator.
TheXUemulatorisahost-independentsoftwareemulationofDigital'sDEUNA(M7792/M7793)andDELUA(M7521)UnibusEthernetcardsfortheSIMHemulator.
TheXQandXUsimulatorsusetheSim_Ethermoduletoexecutehost-specificpacketreadsandwrites,sincealloperatingsystemstalktorealEthernetcards/controllersdifferently.Seethecommentsatthetopofsim_ether.cforthelistofcurrentlysupportedhostplatforms.
TheSim_EthermodulesetstheselectedEthernetcardintopromiscuousmodetogatherallpackets,thenfiltersoutthepacketsthatitdoesn'twant.InWindows,packetshavingthesamesourceMACaddressasthecontrollerareignoredforWinPCAPcompatibility(seeWindowsnotesbelow).
IfyourEthernetcardispluggedintoaswitch,thepromiscuousmodesettingshouldnotcausemuchofaproblem,sincetheswitchwillstillfilteroutmostoftheundesirabletraffic.Youwillonlysee"excessive"trafficifyou
areonadirectorhub(repeater)segment.
OnWindowsusingtheWinPcapinterface,thesimulatedcomputercan"talk"tothehostcomputeronthesameinterface.Onotherplatformswithlibpcap(*nix),thesimulatedcomputercannot"talk"tothehostcomputerviatheselectedinterface,sincesimulatortransmittedpacketsarenotreceivedbythehost'snetworkstack.TheworkaroundforthisistouseasecondNICinthehostandconnectthembothintothesamenetwork;thenthehostandthesimulatorcancommunicateoverthephysicalLAN.
IntegratedUniversalTUN/TAPsupportprovidesanothersolutionfortheabovedual-NICproblemforsystemsthatsupportUniversalTUN/TAP.SincetheTUN/TAPinterfaceisapseudonetworkinterface,thehostcancreateaTAPdevicefor
thesimulatorandthenbridgeorroutepacketsbetweentheTAPdeviceandtherealnetworkinterface.NotethattheTAPdeviceandanybridgingorroutingmustbeestablishedbeforerunningthesimulator;SIMHdoesnotcreate,bridge,orrouteTAPdevicesforyou.
IntegratedUniversalTUN/TAPsupportcanbeusedforhostsimulatornetworktraffic(ontheplatformswhereitisavailable)byusingtheSIMHcommand:"attachxqtap:tapN"(i.e.attachxqtap:tap0).Platformsthatthishasbeentestedoninclude:Linux,FreeBSD,OpenBSD,NetBSDandOSX.Eachoftheseplatformshassomewaytocreateatappseudodevice(andpossiblythentobridgeitwithaphysicalnetworkinterface).
ThefollowingstepswereperformedtogetaworkingSIMHvaxsimulator
sharingaphysicalNICandallowingHostSIMHvaxcommunications:
Linux(Ubuntu10.04):apt-getinstallmakeapt-getinstalllibpcap-devapt-getinstallbridge-utilsapt-getinstalluml-utilities
#!/bin/sh
-
7/29/2019 emu eth
2/12
HOSTIP=`/sbin/ifconfigeth0|grep"inetaddr"|gawk--'{print$2}'|gawk-F:--'{print$2}'`HOSTNETMASK=`/sbin/ifconfigeth0|grep"inetaddr"|gawk--'{print$4}'|gawk-F:--'{print$2}'`HOSTBCASTADDR=`/sbin/ifconfigeth0|grep"inetaddr"|gawk--'{print$3}'|gawk-F:--'{print$2}'`HOSTDEFAULTGATEWAY=`/sbin/route-n|grep^0.0.0.0|gawk--'{print$2}'`#/usr/sbin/tunctl-ttap0[-usomeuser]/sbin/ifconfigtap0up##Nowconverteth0toabridgeandbridgeitwiththeTAPinterface/usr/sbin/brctladdbrbr0/usr/sbin/brctladdifbr0eth0/usr/sbin/brctlsetfdbr00/sbin/ifconfigeth00.0.0.0/sbin/ifconfigbr0$HOSTIPnetmask$HOSTNETMASKbroadcast$HOSTBCASTADDRup#setthedefaultroutetothebr0interface/sbin/routeadd-net0.0.0.0/0gw$HOSTDEFAULTGATEWAY#bridgeinthetapdevice/usr/sbin/brctladdifbr0tap0/sbin/ifconfigtap00.0.0.0
#Runsimulatorand"attachxqtap:tap0"
OpenBSD(OpenBSD4.6)
/sbin/ifconfigtun0create/sbin/ifconfigtun0link0/sbin/ifconfigtun0up
/sbin/ifconfigbridge0create/sbin/brconfigbridge0fwddelay4/sbin/brconfigbridge0addem0addtun0#Changeem0toreflectyourphysicalNICname/sbin/brconfigbridge0up
#Runsimulatorand"attachxqtap:tun0"FreeBSD(FreeBSD8.0)
/sbin/ifconfigtap0create/sbin/ifconfigtap0up
/sbin/ifconfigbridge0create/sbin/ifconfigbridge0addmem0addmtap0#Changeem0toreflectyourphysicalNICname/sbin/ifconfigbridge0up
#Runsimulatorand"attachxqtap:tap0"
#Note:itseemsthatonFreeBSDyoumayhaveto#"/sbin/ifconfigtap0up"and"/sbin/ifconfigbridge0up"priortoeach#timesimh"attach"esthetap:tap0device
NetBSD(NetBSD5.0.2)
/sbin/ifconfigtap0create/sbin/ifconfigtap0up
-
7/29/2019 emu eth
3/12
/sbin/ifconfigbridge0create/sbin/brconfigbridge0fwddelay1/sbin/brconfigbridge0addwm0addtap0#Changewm0toreflectyourphysicalNICname/sbin/brconfigbridge0up
#Runsimulatorand"attachxqtap:tap0"
OSX(SnowLeopard)OSXDoesNOThavenativesupportfortun/tapinterfaces.Italsodoesnothavenativesupportforbridging.MattiasNisslerhascreatedtun/tapfunctionalityavailableathttp://tuntaposx,sourceforge.net/We'llpuntonbridgingforthesakeofthisexampleandmoveontouseabasictapbasedinternalnetworksoahostandguestcancommunicatedirectly.Downloadtheinstallpackagefrom:http://sourceforge.net/projects/tuntaposx/files/tuntap/20111101/tuntap_20111101.tar.gz
Expandthetarballtoadirectory.Invokethepackageinstallertuntap_20111101.pkgClickthroughthevariouspromptsacceptingthingsandeventuallyinstallingthepackage.#BuildandRunsimulatorand:sim>attachxqtap:tap0sim>!ifconfigtap0192.168.6.1netmask255.255.255.0
SimulatedsystemusesIPaddress192.168.6.2andhostuses192.168.6.1andthingswork.Youmustrunasrootforthistowork.
-------------------------------------------------------------------------------Analternativetodirectpcapandtun/tapnetworkingon*nixenvironmentsisVDE(VirtualDistributedEthernet).
Note1:Usingvdebasednetworkingislikelymoreflexible,butitisn'tnearlyasefficient.HostOSoverheadwillalwaysbehigherwhenvdenetworkingisusedascomparedtonativepcapand/ortun/tapnetworking.Note2:Rootaccesswilllikelybeneededtoconfigureorstartthevdeenvironmentpriortostartingasimulatorwhichmayuseit.Note3:SimulatorsrunningusingVDEnetworkingcanrunwithoutrootprivilege.
Linux(Ubuntu10.04):apt-getinstallmakeapt-getinstalllibvdeplug-devapt-getinstallvde2
vde_switch-s/tmp/switch1-taptap0-m666ifconfigtap0192.168.6.1netmask255.255.255.0up#BuildandRunsimulatorand:sim>attachxqvde:/tmp/switch1#simulatorusesIPaddress192.168.6.2
-
7/29/2019 emu eth
4/12
-------------------------------------------------------------------------------
Windowsnotes:1.TheWindows-specificcodeusestheWinPCAP4.xpackagefromhttp://www.winpcap.org.Thispackageforwindowssimulatesthelibpcappackagethatisfreelyavailableforun*xsystems.
2.Youmust*install*theWinPCAPruntimepackage.
3.ThefirsttimetheWinPCAPdriverisused,itwillbedynamicallyloaded,andtheusermustbeanAdministratoronthemachinetodoso.Ifyouneedtorunasanunprivilegeduser,youmustsetthe"npf"drivertoautostart.CurrentWinPcapinstallersprovideanoptiontoconfigurethisatinstallationtime,soifthatchoiceismade,thenthereisnoneedforadministratorprivilegedtorunsimulatorswithnetworksupport.
BuildingonWindows:YoushouldbeabletobuildwithanyofthefreecompilerenvironmentsavailableontheWindowsplatform.IfyouwanttousetheVisualC++Express2008or2010interactivedevelopmentenvironments,readthefile".\VisualStudioProjects\0ReadMe_Projects.txt"fordetailsabouttherequireddependencies.Alternatively,youcanbuildsimhwithnetworking
supportusingtheMinGWGCCcompilerenvironmentorthecygwinenvironment.EachoftheseVisualC++,MinGWandcygwinbuildenvironmentsrequireWinPcapandPosixpackagesbeingavailable.Theseshouldbelocatedinadirectorystructureparalleltothecurrentsimulatorsourcedirectory.ForExample,thedirectorystructureshouldlooklike:
.../simh/simhv38-2-rc1/VAX/vax_cpu.c.../simh/simhv38-2-rc1/scp.c.../simh/simhv38-2-rc1/VisualStudioProjects/simh.sln.../simh/simhv38-2-rc1/VisualStudioProjects/VAX.vcproj.../simh/simhv38-2-rc1/BIN/Nt/Win32-Release/vax.exe.../simh/windows-build/pthreads/pthread.h
.../simh/windows-build/winpcap/WpdPack/Include/pcap.h
Thecontentsofthewindows-builddirectorycanbedownloadedfrom:
https://github.com/downloads/markpizz/simh/windows-build.zip
ThereareWindowsbatchfilesprovidedtoinitiatecompilesusingtheMinGWcompilertoolchain.Thesebatchfilesarelocatedinthesamedirectoryasthisfileandarecalled:build_mingw.bat,build_mingw_ether.bat,andbuild_mingw_noasync.bat.ThesebatchfileseachpresumethattheMinGWtoolchainiseitherinthecurrentpathor,ifnotthatitislocatedatC:\MinGW\bin.ThesebatchfilesmerelyinvoketheMinGWmake(GNUmake)
passingsomespecificargumentsalongwiththeoptionalargumentsthebatchfileisinvokedwith.ThecurrentwindowsnetworkbuiltbinarieswillrunonanysystemwithoutregardtowhetherornotWinPcapisinstalled,andwillprovideNetworkfunctionalitywhenWinPcapisavailable.
-------------------------------------------------------------------------------
Linux,{Free|Net|Open}BSD,OS/X,andUn*xnotes:
-
7/29/2019 emu eth
5/12
-----WARNING-----WARNING-----WARNING-----WARNING-----WARNING-----
Sim_Etherhasbeenreworkedtobemoreuniversal;becauseofthis,youwillneedtogetaversionoflibpcapthatis0.9orgreater.AllcurrentLinuxdistributionsprovidealibpcap-devpackagewhichhastheneededversionoflibpcapandtherequiredcomponentstobuildapplicationsusingit.IfyouarerunninganolderLinuxOS,youcandownloadandbuildtherequiredlibraryfromwww.tcpdump.org-seethecommentsatthetopofSim_ether.cfordetails.
-----WARNING-----WARNING-----WARNING-----WARNING-----WARNING-----
1.Forallplatforms,youmustrunSIMH(scp)withsufficientprivilegetoallowtheEthernetcardcanbesetintopromiscuousmodeandtowritepacketsthroughthedriver.a)ForWindowssystemsthismeanshavingadministratorprivilegestostartthe"npf"driver.ThecurrentWinPcapinstalleroffersanoptiontoautostartthe"npf"driverwhenthesystemboots.Startingthe"npf"driveratboottimemeansthatsimulatorsdonotneedtorunwithadministratorprivileges.b)FormorerecentLinuxsystems,Theconceptsleveraging"FilesystemCapabilities"canbeusedtospecificallygrantthesimhbinarytheneededprivilegestoaccessthenetwork.Thearticleat:
http://packetlife.net/blog/2010/mar/19/sniffing-wireshark-non-root-user/describeshowtodothisforwireshark.TheexactsamecapabilitiesareneededbySIMHfornetworksupport.Usethatarticleasaguide.c)ForUnix/Unix-likesystemswhichusebpfdevices(NetBSD,OpenBSD,FreeBSDandOS/X)itispossibletosetpermissionsonthebpfdevicestoallowreadandwriteaccesstousersotherthanroot(Forexample:chmod666/dev/bpf*).Doingthis,hasitsownsecurityissues.d)Forotherplatformsthiswilllikelymeanrunningasroot.Additionalalternativemethodsforavoidingthe'runasroot'requirementwillbewelcomed.
2.IfyouwanttouseTAPdevices,andanysurroundingsystemnetwork/bridgesetupmustbedonebeforerunningSIMH.However,oncethatisdone(possiblyatsystemboottime),usingtheTAPdevicescanbedonewithoutrootprivileges.
BuildingonLinux,{Free|Net|Open}BSD,OS/X,Solaris,other*nix:
1.Get/make/installthelibpcap-devpackageforyouroperatingsystem.Sources:All:http://www.tcpdump.org/Olderversionsoflibpcapcanbefound,forvarioussystems,at:Linux:searchforyourvariantonhttp://rpmfind.netOS/X:AppleDeveloper'ssite?
NOTE:Therepositoriesforolderversionsoftheseplatformsdon'tcontainaversionoflibpcapgreaterthan0.8.1.However,most(all)recentreleasesof*nixenvironmentsshipwithsufficientlyrecentversionsoflibpcapeitherautomaticallyinstalledoravailableforinstallationaspartofthedistribution.TheOSprovidedlibpcap-devcomponentswillbeprefereabletoapackagebuiltfromwww.tcpdump.orgsources.ThisisduetothefactthatvariousOSsuppliedpackageswilldependontheOSsuppliedlibpcap.Theimproperbuildor
-
7/29/2019 emu eth
6/12
installofthewww.tcpdump.orgsourcepackagecanconflictwiththeOSprovidedoneandbreaktheOSprovidedapplications(i.e.tcpdumpand/orwireshark)aswellasnotworkingcorrectlyforusebysimh.
2.Ifyouinstallthevendorsuppliedlibpcap-devpackagethenthesimhmakefilewillautomaticallyusethevendorsuppliedlibrarywithoutanyadditionalarguments.Ifyouhavedownloadedandbuiltlibpcapfromwww.tcpdump.org,thentheexistingmakefilewilldetectthatthisisthecaseandtrytousethat.
3.Themakefiledefaultstobuildingsimulatorswithnetworksupportwhichdynamicallyloadthelibpcaplibrary.Thismeansthatthesamesimulatorbinarieswillrunonanysystemwhetherornotlibpcapisinstalled.Ifyouwanttoforcedirectlibpcaplinkingduringabuildyoudosobytyping'makeUSE_NETWORK=1'
4.Buildit!
-------------------------------------------------------------------------------
OpenVMSAlphaandOpenVMSIntegrety(IA64)notes:1.EthernetsupportwillonlyworkonAlphaVMS7.3-1orlater,whichiswhenrequiredVCIpromiscuousmodesupportwasadded.Hobbyistscan
gettherequiredversionofVMSfromtheOpenVMSAlphaHobbyistKit3.0.
RunningasimulatorbuiltwithEthernetsupportonaversionofVMSpriorto7.3-1willbehaveasifthereisnoEthernetsupportbuiltinduetotheinabilityofthesoftwaretosetthePCAPVCMintopromiscuousmode.
AnexampledisplayoffullyfunctionalEthernetsupport:sim>SHOWXQETHETHdevices:0we0(VMSDevice:_EWA0:)1we1(VMSDevice:_EWB0:)
AnexampledisplaywhenthesimulatorwasbuiltwithoutEthernetsupport
orisnotrunningtherequiredversionofVMS:sim>SHOWXQETHETHdevices:nonetworkdevicesareavailable
2.YoumustplacethePCAPVCM.EXEexecletinSYS$LOADABLE_IMAGESbeforerunningasimulatorwithEthernetsupport.Note:Thisisdonebythebuildcommandsindescrip.mms.
3.YoumusthaveCMKRNLprivilegetoSHOWorATTACHanEthernetdevice;alternatively,youcanINSTALLthesimulatorwithCMKRNLprivilege.
4.Ifyouuseasecondadaptertocommunicatetothehost,SOMEprotocol
thatcreatesanI/Ostructure(SCS,DECNET,TCP)mustberunningontheadapterpriortryingtoconnectwithSIMH,orthehostmaycrash.TheexecletisnotwrittentocreateanI/Ostructureforthedevice.
BuildingonOpenVMSAlphaandOpenVMSIntegrety(IA64):Thecurrentdescrip.mmsfilewillbuildsimulatorscapableofusingEthernetsupportwiththemautomatically.Thesecurrentlyare:VAX,VAX780,andPDP11.Thedescrip.mmsdrivenbuildswillalsobuildthepcaplibraryandbuildandinstalltheVCIexeclet.
-
7/29/2019 emu eth
7/12
1.FetchtheVMS-PCAPzipfilefrom:http://simh.trailing-edge.com/sources/vms-pcap.zip
2.UnzipitintothebaseoftheSIMHdistributiondirectory.3.Buildthesimulator(s)withMMSorMMK:$MMx{VAX,PDP11,PDP10,etc...}
-------------------------------------------------------------------------------
VAXsimulatorsupport:
AnOpenVMSVAXv7.2systemwithDECNETPhaseIV,MultiNet4.4a,andLAT5.3hasbeensuccessfullyrun.OthertestershavereportedsuccessbootingNetBSDandOpenVMSVAX5.5-2also.
PDP11simulatorsupport:
AnRT-11v5.3systemwithafreewareTCP/IPstackhasbeensuccessfullyrun.OthertestershavereportedthatRSXwithDECNETandtheNetBSDoperatingsystemsalsowork.RSTS/Ev10.1haspreliminarysupport-RSTS/EbootsandenablestheXH(XQ)device-DECNETandLATsoftwarehavenotbeentested.
TheXUmodulehasbeentestedbyathirdpartyforbasicpacketfunctionalityunderamodifiedRSX11Menvironment.Iamunabletotestitin-houseuntil
someonecanarrangetosendmeadiskimagecontainingastockRSTS/EorRSX11M+systemimagethatalsocontainsDECNET,LAT,and/orTCP/IPsoftware.
-------------------------------------------------------------------------------
HowtodebugproblemswiththeEthernetsubsystems:
PLEASEreadthehost-specificnotesinsim_ether.c!
WhilerunningSCP,thefollowingcommandscanbeusedtoenabledebugmessages:
sim>SETDEBUGSTDERRsim>SETXQDEBUG=TRACE;CSR;VAR;WARN;SETUP;SANITY;REG;PACKET;DATA;ETH
sim>SETXUDEBUG=ETH;TRACE;REG;WARN;PACKET;DATA
Documentationofthefunctionalityofthesedebugmodifierscanbefoundinpdp11_xq.handpdp11_xu.h.Inlinedebugginghasreplacedtheprevious#ifdefstyleofdebugging,whichrequiredrecompilationbeforedebugging.
-------------------------------------------------------------------------------
Thingsplannedforfuturereleases:1.FullMOPimplementation
-------------------------------------------------------------------------------
ThingswhichIneedhelpwith:1.InformationaboutRemoteMOPprocessing2.VAX/PDP-11hardwarediagnosticsimagefilesanddocs,totestXQthoroughly.3.FeedbackonoperationwithotherVAX/PDP-11OS's.
-------------------------------------------------------------------------------
Pleasesendallpatches,questions,feedback,clarifications,andhelpto:davidDOThittnerATngcDOTcom
-
7/29/2019 emu eth
8/12
Thanks,andEnjoy!!Dave
===============================================================================ChangeLog===============================================================================01-Mar-12AGNAddedsupportforbuildingusingCygwinonWindows01-Mar-12MPMadehostNICaddressdetectionmorerobuston*nixplatformsandmaditworkwhencompilingunderCygwin29-Feb-12MPFixedMACAddressConflictdetectionsupport28-Feb-12MPFixedoverrunbugineth_deviceswhichcausedSEGFAULTs28-Feb-12MPFixedinternalloopbackprocessingtoonlyrespondtoloopbackpacketsaddressedtothephysicalMACorappropriateMulticastorBroadcastaddresses.17-Nov-11MPAddeddynamicloadingoflibpcapon*nixplatforms30-Oct-11MPAddedsupportforvde(VirtualDistributedEthernet)networking29-Oct-11MPAddedsupportforintegratedTapnetworkinginterfacesonOSX17-Aug-11RMSFixfromSergeyOboguevrelatingtoXUandXQAutoConfigandvectorassignments12-Aug-11MPCleaneduppayloadlengthdeterminationFixedraceconditiondetectingreflectionswhenthreaded
readingandwritingisenabled07-Jul-11MBVMSPcap(fromMikeBurke)-FixedAlphaissues-AddedOpenVMSIntegretysupport20-Apr-11MPFixedsave/restorebehavior12-Jan-11DTHAddedSHOWXUFILTERSmodifier11-Jan-11DTHCorrectedDEUNA/DELUASELFTESTcommand,enablingusebyVMS3.7,VMS4.7,andUltrix1.109-Jan-11MPFixedmissingcrcdatawhenUSE_READER_THREADisdefinedandcrc'sareneeded(onlythepdp11_xu)16-Dec-10MPaddedpriorityboostforreadandwritethreadswhenUSE_READER_THREADdoesI/Oinseparatethreads.ThishelpsthroughputsinceitallowstheseI/Oboundthreadstopreempt
themainthread(whichisexecutingsimulatedinstructions).09-Dec-10MPallowedmoreflexibleparsingofMACaddressstrings09-Dec-10MPAddedsupporttodetermineifnetworkaddressconflictsexist07-Dec-10MPReworkedDECnetselfdetectiontothemoregeneralapproachofloopbackselfwhenanyPhysicalAddressisbeingset.06-Dec-10MPAddedloopbackprocessingsupporttopdp11_xu.c06-Dec-10MPFixedloopbackprocessingtocorrectlyhandleforwardpackets.04-Dec-10MPChangedeth_writetodononblockingwriteswhenUSE_READER_THREADisdefined.30-Nov-10MPFixedthefactthatnobroadcastpacketswerereceivedbytheDEUNA29-Nov-10MPFixedinterruptdispatchissuewhichcauseddeliveredpackets
(inandout)tosometimesnotinterrupttheCPUafterprocessing.17-Jun-10MPFixedbugintheAUTODINIIhashfiltering.14-Jun-10MPAddedsupportforintegratedTapnetworkinginterfacesonBSDplatforms.13-Jun-10MPAddedsupportforintegratedTapnetworkinginterfacesonLinuxplatforms.31-May-10MPAddedsupportformoreTOE(TCPOffloadEngine)featuresforIPv4
-
7/29/2019 emu eth
9/12
networktrafficfromthehostand/orfromhostsontheLAN.ThesenewTOEfeaturesare:LSO(LargeSendOffload)andJumbopacketfragmentationsupport.ThesefeaturesallowasimulatednetworkdevicetosupporttrafficwhenahostleveragesaNIC'sLargeSendOffloadcapabilitiestofragmentand/orsegmentoutgoingnetworktraffic.AdditionallyasimulatednetworkdevicecanreasonablyexistonaLANwhichisconfiguredtouseJumboframes.21-May-10MPAddedfunctionalitytofixupIPheaderchecksumstoaccommodatepacketsfromahostwithaNICwhichhasTOE(TCPOffloadEngine)enabledwhichisexpectedtoimplementthechecksumcomputationsinhardware.SincewecatchpacketsbeforetheyarriveattheNICtheexpectedchecksuminsertionshaven'tbeenperformedyet.Thisprocessingisonlydoneforpacketssentfromthehosttotheguestwe'resupporting.Ingeneralthiswillbearelatively
smallnumberofpacketssoitisdoneforallIPframepacketscomingfromthehosttotheguest.InordertomakethedeterminationofpacketsspecificallyarrivingfromthehostweneedtoknowthehardwareMACaddressofthehostNIC.CurrentlydeterminingaNIC'sMACaddressisrelativelyeasyonWindows.Thenon-windowscodeworksonlinuxandmayworkonother*nixplatformseitherasisorwithslightmodifications.Thecode,asimplemented,onlymesseswiththisactivityifthehostinterfaceMACaddresscanbedetermined.
20-May-10MPAddedgeneralsupporttodealwithreceivingpacketssmallerthanETH_MIN_PACKETinlength.Thesecomefrompacketsloopedbackbysomebridgingmechanismandneedtobepaddedtotheminimumframesize.ArealNICwon'tpassusanypacketslikethat.Thisfixbelongsheresincethislayerisresponsibleforinterfacingtothephysicallayerdevices,ANDitbelongsheretogetCRCprocessingright.15-Aug-08MPFixedtransmittedpacketstohavethecorrectsourceMACaddress.Fixedincorrectaddressfiltersettingcallingeth_filter().07-Mar-08MPFixedtheSCPvisibleSAregisterstoalwaysdisplaytheROMMACaddress,evenafteritischangedbySETXQMAC=.07-Mar-08MPAddedchangessothattheConsoleDELQAdiagnostic(>>>TEST82
)willsucceed.03-Mar-08MPAddedDELQA-T(akaDELQAPlus)deviceemulationsupport.06-Feb-08MPAddeddroppedframestatisticstorecordwhenthereceiverdiscardsreceivedpacketsduetothereceiverbeingdisabled,orduetotheXQdevice'spacketreceivequeuebeingfull.Fixedbuginreceiveprocessingwhenwe'renotpolling.Thiscould
-
7/29/2019 emu eth
10/12
causereceiveprocessingtoneverbeactivatedagainifwedon'treadallavailablepacketsviaeth_readeachtimewegettheopportunity.31-Jan-08MPAddedtheabilitytoCoalescereceivedpacketinterrupts.ThisisenabledbySETXQPOLL=DELAY=nnnwherennnisanumberofmicrosecondstodelaythetriggeringofaninterruptwhenapacketisreceived.29-Jan-08MPAddedSETXQPOLL=DISABLE(akaSETXQPOLL=0)tooperatewithoutpollingforpacketreadcompletion.29-Jan-08MPChangedthesanityandidtimermechanismstouseaseparatetimerunitsothattransmitandreceiveactivitiescanbedealtwithbythenormalxq_svcroutine.Dynamicallydeterminethetimerpollingratebasedonthecalibratedtmr_pollandclk_tpsvaluesofthesimulator.25-Jan-08MPEnabledtheSETXQPOLLtobemeaningfulifthesimulatorcurrentlydoesn'tsupportidling.25-Jan-08MPChangedxq_debug_setuptousesim_debuginsteadofprintfsothat
alldebugoutputgoestothesameplace.25-Jan-08MPRestoredthecalltoxq_svcafterallsuccessfulcallstoeth_writetoallowreceiveprocessingtohappenbeforethenexteventservicetime.Thismusthavebeeninadvertentlycommentedoutwhileotherthingswerebeingtested.23-Jan-08MPAddeddebuggingsupporttodisplaypacketheadersandpacketdata18-Jun-07RMSAddedUNIT_IDLEflag29-Oct-06RMSSyncedpollandclock27-Jan-06RMSFixedunalignedaccessesinXQB(foundbyDougCarman)07-Jan-06RMSFixedunalignedaccessbugs(foundbyDougCarman)
07-Sep-05DTHRemovedunusedvariable16-Aug-05RMSFixedC++declarationandcastproblems
05-Mar-08MPAddedoptionalmulticastfilteringsupportfordoingLANCEstyleAUTODINIIbasedhashedfiltering.07-Feb-08MPAddedeth_show_devtodisplayEthernetstateChangedthereturnvaluefrometh_readtoreturnwhetherornotapacketwasread.Noexistingcallersusedorcheckedconstantreturnvaluethatpreviouslywasbeingsupplied.29-Jan-08MPAddedeth_set_asynctoprovideamechanism(whenUSE_READER_THREADisenabled)toallowpacketreceptiontodynamicallyupdatethesimulatoreventqueueand
potentiallyavoidpollingforI/O.Thisprovidesaminimaloverhead(nopolling)maximalresponsivenessfornetworkactivities.29-Jan-08MPProperlysequencedactivitiesineth_closetoavoidaraceconditionwhenUSE_READER_THREADisenabled.25-Jan-08MPChangedthefollowingwhenUSE_READER_THREADisenabled:-Fixedbugwhenthesimulateddevicedoesn'tneedcrcinpacketdatawhichisread.-Addedcalltopcap_setmintocopytominimizepacketdeliverylatencies.
-
7/29/2019 emu eth
11/12
-Addedethq_destroyandusedittoavoidamemoryleakineth_close.-Properlycleaneduppthreadmutexesineth_close.Migratedtousingsim_os_ms_sleepforadelayinsteadofacalltoselect().Fixedthebpffilterusedwhennotrafficistobematched.Reworkedeth_add_packet_crc32implementationtoavoidanextrabuffercopywhilereadingpackets.Fixedup#ifdef'srelatingtoUSE_SHAREDsothatsettingUSE_SHAREDorUSE_NETWORKwillbuildaworkingnetworkenvironment.23-Jan-08MPReworkedeth_packet_traceandeth_packet_trace_extoallowonlyoutputEthernetheader+crcandprovideamechanismforthesimulateddevicetodisplayfullpacketdatadebugging.17-May-07DTHFixednon-Ethernetdeviceremovalloop(fromNaokiHamada)15-May-07DTHAddeddynamicloadingofwpcap.dll;CorrectedexceedmaxindexbuginethXlookup04-May-07DTHCorrectedfailuretolookupEthernetdevicenamesintheregistryonWindowsXPx6410-Jul-06RMSFixedlinuxconditionalization(fromChaskielGrundman)02-Jun-06JDBFixedcompilerwarningforincompatiblesscanfparameter15-Dec-05DTHPatchedeth_host_devices[removenon-Ethernetdevices](fromMarkPizzolatoandGalenTackett,08-Jun-05)Patchedeth_open[tunfix](fromAntalRitter,06-Oct-05)
30-Nov-05DTHAddedoptiontoregenerateCRConreceivedpackets;someEthernetdevicesneedtopassitontothesimulation,andbythetimelibpcap/winpcapgetsthepacket,thehostOSnetworklayerhasalreadystrippedCRCoutofthepacket01-Dec-04DTHAddedWindowsuser-definedadapternames(fromTimotheLitt)
19-Mar-04Release:1.GenericizedSim_Ethercode,reduced#ifdefs(DavidHittner)2.Furtherrefinementofsim_ether,qualifiedmoreplatforms(MarkPizzolato)3.AddedXUmodule(DavidHittner)4.CorrectedXQinterruptsignalingforPDP11s(DavidHittner)
5.Addedinlinedebuggingsupport(DavidHittner)
-------------------------------------------------------------------------------
26-Nov-03Release:1.AddedVMSsupporttoSim_Ether;createdpcap-vmsport(AndersAhgren)2.AddedDECNETduplicatedetectionforWindows(MarkPizzolato)3.AddedBPFfilteringtoincreaseefficiency(MarkPizzolato)4.CorrectedXQRuntprocessing(MarkPizzolato)5.CorrectedXQSoftwareReset(MarkPizzolato)6.CorrectedXQMulticast/Promiscuousmodesetting/resetting(MarkPizzolato)7.AddedUniversalTUN/TAPsupport(MarkPizzolato)8.AddedFreeBSDsupport(EdwardBrocklesby)
9.CorrectedinterruptsonXQBdevice(DavidHittner)
-------------------------------------------------------------------------------
05-Jun-03Release:1.AddedSET/SHOWXQSTATS(DavidHittner)2.AddedSHOWXQFILTERS(DavidHittner)3.Addedabilitytosplitrcvpacketsintomultiplebuffers(DavidHittner)4.Addedexplicitrunt&giantpacketprocessing(DavidHittner)
-
7/29/2019 emu eth
12/12
-------------------------------------------------------------------------------
30-May-03Release:1.Correctedbuginxq_setmacintroducedinv3.0(multiplepeople)2.MadeXQrcvbufferallocationdynamictoreducescpsize(DavidHittner)3.Optimizedsomestructs,removedlegacyvariables(MarkPizzolato)4.Changed#ifdefWIN32to_WIN32forconsistency(MarkPizzolato)
-------------------------------------------------------------------------------
06-May-03Release:1.AddedsecondXQcontroller(DavidHittner)2.AddedSIMHv3.0compatibility(DavidHittner)3.RemovedSETADDRESSfunctionality(DavidHittner)
-------------------------------------------------------------------------------
10-Apr-03Release:1.AddedpreliminarysupportforRSTS/E(DavidHittner)2.AddedPDP-11bootromloadviaCSRflags(DavidHittner)3.SupportforSPARClinux(MarkPizzolato)
-------------------------------------------------------------------------------
11-Mar-03Release:1.AddedsupportforRT-11TCP/IP2.Correctedinterrupts(thankstoTomEvansandBobSupnik)3.Movedchangelogtothebottomofthereadmefile,cleanedupdocument
-------------------------------------------------------------------------------
16-Jan-03Release:1.AddedVMSclustersupport(thankstoMarkPizzolato)2.VerifiedVAXremotebootfunctionality(>>>BXQA0)3.Addedmajorperformanceenhancements(thankstoMarkPizzolatoagain)4.Changed_DEBUGtracerstoXQ_DEBUGandETH_DEBUG5.Addedlocalpacketprocessing
6.Addedsystemidbroadcast
-------------------------------------------------------------------------------
08-Nov-02Release:1.AddedUSE_NETWORKconditionaltoSim_Ether2.FixedbehaviorofSHOWXQETHifnodevicesexist3.AddedOpenBSDsupporttoSim_Ether(courtesyofFedericoSchwindt)4.AddedethXdetectionsimplification(fromMeganGentry)
===============================================================================