What the "말려" in "휘말려" means?

휘말려 means like surrounding/wraping, right?

I recognize 휘 from 휘감아, that if I'm not wrong is like spining, which I can kinda see the correlation, like, spining... spining around... surrounding

But I'm not sure what adding "말려" changes exactly, or how it would work on other words, can someone help me?