I suggest you examine the original Greek in an interlinear bible. The word 'spirit' used is a cognate of pneuma (pneuma being variously translated as spirit, life, or breath; pneuma is a fairly common Greek term having a multitude of meanings). In particular, you will note the repetition of the parallel phrase 'tou theou' ('of God' or 'from God'), qualifying that the spirits in question are not 'ghosts' or the Holy Spirit, but the spirits (or life, soul, mind) of men. In no place in 1 John 4:1-4 is there any obvious reference to the Holy Spirit, and the preceding text in 1 John 3:24 makes the use of pneuma in 1 John 4 even less ambiguous ('we know that he abides in us by the spirit [ek tou pneumatos] which he gave to us").
(, interlinear bible courtesy of the Online Parallel Bible Project)