The switch is a pretty “dumb” box…it only cares about a couple of things:
- When it receives an ethernet frame and it didn’t see the source MAC address before, it is stored in the mac address table.
- If the destination MAC address is known, it forwards it out of the correct interface.
- If the destination MAC address is unknown, it is flooded on all ports (except the one where it came from).
- If the destination MAC address is a broadcast, it is flooded on all ports (except the one it came from).
So this story about the switch learning MAC addresses always applies on a LAN since we always use Ethernet there. You have to see the switch and the computer completely seperate from each other…the switch doesn’t care about any of the traffic, only about the frames and their MAC addresses…that’s it.
About the computers,we use IP for pretty much everything so most of the traffic from your computer will use IP packets but it’s possible that some protocols use something else. Not sure if Windows uses any “discovery” protocols that don’t use IP but are encapsulated in an Ethernet frame directly. I do know a Cisco example:
Cisco Discovery Protocol
CDP doesn’t use IP but is encapsulated in Ethernet frames directly .