Well... battle armor are a problem. All but the most lightly-protected suits will shrug off an HMG hit and just get mad. They probably are hitting back with significant weaponry themselves, and if they're in range where you're firing HMGs the real threat is being swarmed- you don't want some guy in a Salamander suit opening up your left torso to rearrange everything in there to his liking. So when it comes to battle armor, leave the anti-infantry weapons out of it in-general and switch straight up to the kind of weaponry you'd use to kill a small Battlemech- medium lasers are a great choice. The best way to get rid of them, ideally, is area-effect weaponry like a Long Tom, but that can be a little inaccurate and messy. But yeah, MGs, flamers, etc. (hell, some suits are literally invulnerable to flamers!), that stuff is out the window when battle armor are the threat. Don't play around- kill them before they kill you. (Watching a Golem suit- ONE- take a Gauss hit and shrug it off was a serious lesson!)
As for modern infantry, there's new tricks for sure. LRM-equipped infantry are a neat trick, for example. And of course anti-Mech squads with leg-crippling satchel charges are a nasty thing, especially in a city where they can hide in buildings before running out to surprise you. That's bad- especially since once they're in your Mechs' hex you can't do anything to them other than panicked physical attacks and hysterical sobbing. The Total Warfare revamp to infantry also makes all unarmored infantry units far, far more durable than they used to be, so killing off a squad like that can get a little rough if you didn't bring the right tools for the job.
They're still a cheap and questionable-use option on most battlefields, but used in the right environment some infantry can become a real menace. It's worth keeping a unit or two around that can get rid of them quickly and efficiently- and better if it's something mobile that can rapidly deploy to the trouble spot for the job. The old Vulcan really is still one of the better options for the job (and cheap to boot), as well as the Firestarter (standard or Omni). If you're willing to risk vehicles, there's other great options available as well- the Ignis is an extinct design, but if you happen to salvage one or two they make infantry melt away like snow in Ecuador. The VV1 Ranger, Chalupa-Tank, Shoden LBX, and Joust are more recent tanks that excel at anti-infantry work as well.