Suspect Emanuel Kidega Samson. (Nashville police/AP)

A man who opened fire in a Tennessee church on Sunday may have been motivated by a quest for revenge for an earlier shooting that targeted black churchgoers in Charleston, S.C., according to people familiar with the investigation.

Police said the suspect, Emanuel Kidega Samson, was wearing a mask when he entered Burnett Chapel Church of Christ in Antioch, a small community outside Nashville, and began shooting. One parishioner was shot in the parking lot and died; six other people, including the minister, were wounded.

People close to the investigation said a note found in the gunman’s car indicated he may have been seeking revenge for the 2015 shooting at Emanuel AME, a historically black church in Charleston. In that attack, avowed white supremacist Dylann Roof killed nine black worshipers at an evening Bible-study session. Roof was convicted and is awaiting execution.

The Justice Department’s civil rights division and the FBI have opened a hate-crimes probe into the Tennessee attack. Samson is facing a state murder charge.

Investigators have not publicly identified a motive in the shooting, though they are also examining whether Samson had mental health problems that may have contributed to the violence, according to people familiar with the investigation who spoke on the condition of anonymity to discuss an ongoing case.

Further details about the suspect’s note, whose existence was first reported by the Associated Press, were not immediately available.

Samson, 25, came to the United States from Sudan as a child, and church members said he had previously attended services there.

Nashville police said Monday that no one in the church recalled the gunman saying anything during the attack. Police said Samson’s rampage ended when a church usher grappled with him, resulting in the gunman being shot.

Steve Anderson, the Nashville police chief, said at the same briefing that Samson admitted to being at the church and firing his weapon there, but that was all the information the suspect had provided investigators at that time. It was unclear whether he had spoken with investigators since then.