Either onomatopoeic or an alteration of го́мон (gómon, “hubbub”).
гам • (gam) m inan (genitive га́ма, uncountable)
гам • (gam)