Roger Trenton Davis soon will enter a Virginia prison to begin serving a 40-year sentence for the sale and possession of nine ounces of marijuana.

Three times federal court judges have called that sentence "cruel and unusual punishment" and overruled the state judge who imposed it in 1974. The original prosecutor in the case has said the sentence is too severe. In Virginia, the maximum sentence for second-degree murder is 20 years.

But last week the Supreme Court upheld the sentence and rebuked the 4th Circuit Court of Appeals, the latest federal court to rule in Davis' favor. The appellate court had "ignored" mandates that federal courts not interfere with sentences handed out under state law--a precedent that "must be followed by the lower federal courts no matter how misguided the judges of those courts may think it to be," the Supreme Court said.

In a dissenting opinion, Justice William J. Brennan Jr. wrote: "Unfortunately, it is Roger Trenton Davis who must now suffer the pains of the Court's insensitivity . . . "

Roger Trenton Davis, 36, was once a leader of a small-town counterculture, big and bearded with a bandanna on his head, a black man who dated white girls, even married one. Today, he is a man approaching middle age and still waiting to serve a 40-year sentence for a crime that last year received an average 3 1/2-year sentence in the United States.

He has served three years on a total of three other drug convictions, one before his controversial sentencing and one after. He has cut his hair, held several jobs, become a father and remained married to the white woman whose friendship with him stirred prejudice in the rural Virginia town in which Davis was reared and convicted.

And still he waits, not because prosecutors believe Davis should spend four decades in jail--he would be eligible for parole in less than seven years--but because of a legalistic debate over federal court intervention in state law. That justice might somehow have been out of kilter when a rural Wythe County jury--amid a local war on drug use--sentenced Davis, was not an issue.

"To the courts," says Davis, "I'm just a name."

Out in the snowy yard of his northwest Roanoke apartment, hands in the pockets of his brown leather jacket, Davis stands with his big shoulders pulled back. He has a handsome ebony face and clear almond eyes beneath his short Afro. With him in the cold are two neighborhood teen-agers.

"You know," one of the youths says, "this guy cut a friend of mine's throat and got three years' probation."

"Yeah," says the other, "but you know that guy hadda have some money in some people's palms to get outta that one. That's what you need, Rog." The talk continues. Davis listens and smiles.

"Well, take it easy, Rog," the first youth says. "We'll see you around."

"I ain't going nowhere yet," Davis says. And as he turns back toward his three-bedroom apartment, he pulls his lips back and sucks air through his two gold-inlaid front teeth, making a sibilant sound as if he is trying to dislodge an errant piece of food. "I'm not the person I'm hearing about on the news. I'm not the one. It doesn't seem like me. It shouldn't be happening to me."

Davis was convicted of the marijuana offenses in Wythe County Circuit Court, the same court where 21 years earlier a judge sentenced the white man who killed Davis' father in a traffic accident to a $150 fine and a 90-day suspended jail sentence. When Davis was tried in the mountain community of 25,000 in Southwestern Virginia, liquor by the drink was still illegal there and the local newspaper editor was writing: "The use of marijuana by young Americans is of tremendous help to the Communists."

Davis' attorney argued that the nine ounces of marijuana Davis was charged with selling and possessing was not technically the Cannabis Sativa L variety then cited in Virginia's drug statutes. He even brought in a University of Maryland botanist to confirm that it wasn't. But those points held little sway with the jury.

"Botanical mumbo-jumbo had no bearing on the case," one juror told a reporter a year after the trial. "It by and large passed right over our heads."

The real issue, say Davis, his present Charlottesville attorney Ted Hogshire and officials of the American Civil Liberties Union, which has paid trial expenses, was not marijuana but miscegenation--the mixing of the races through marriage.

For as a young man in Wytheville, population 3,000, Davis broke a primary social taboo: He dated white girls and married one, a pretty farmer's daughter with long blond hair whom he met one day in the student lounge at Wytheville Community College.

"I had never really known any blacks; there weren't any in my high school," says Carol Breedlove Davis, who had come from nearby Bland County. But one day, she says, "I was doing my shorthand--that's all I ever did--and he just cruised in and started talking to me. There was just something about him."

"Roger Davis became a kind of local legend--a black hippie leader with the charm of a Pied Piper," Wythe County drug counselor Nancy Davis (no relation) wrote to then-Gov. Mills E. Godwin, a former segregationist and an architect of Virginia's policy of "massive resistance" to school desegregation, when she organized a pardon petition for Davis.

"He could often be seen on Main Street surrounded by several of the prettiest white girls in town, all competing for his affection," the letter continued. "His popularity became legendary and gradually other blacks followed his lead. The result was a kind of explosion of interracial dating, both open and secret, and a large number of interracial marriages."

Roger Trenton Davis flaunted it, too. He would ride up and down Main Street in a Cadillac with Carol in the passenger seat, go into Durham's Restaurant and order a big steak dinner for the two of them. During that time, a cross was burned on Davis' lawn.

And while this was going on, the drug revolution--the long-haired, olive-drab and denimed, hemp-scented scene of the sixties--was hitting Wythe County. Kids were smoking marijuana, taking LSD. "I was a young guy cruising around," Davis says of those days. "I was about freedom, good times, a lot of friends, into everything everybody else was into. I don't think anybody hardly thought about the future."

But then Wythe County declared war on dope. Dozens of people were arrested beginning in January 1973. Davis was convicted twice, once for selling four LSD tablets and once on the marijuana charges. Between his first arrest and the first day of his trial in March 1974, The Southwest Virginia Enterprise, the local biweekly newspaper, ran at least 55 front page or page two stories on drugs and drug arrests. Sixteen of them were on Davis.

After his convictions, Davis spent three years at Powhatan Correctional Center in Richmond, finishing his time on the LSD charges and serving a few months on his marijuana sentence. Then in May 1977, U.S. District Court Judge James C. Turk ruled that Davis' 40-year marijuana sentence was "cruel and unusual" in violation of the Eighth Amendment. Davis walked out of prison, moved with Carol to Roanoke and got a job as a counselor at a youth counseling center, Total Action Against Poverty.

The state appealed that ruling, however, and in November 1978 a three-judge panel of the 4th Circuit Court of Appeals reversed Turk's decision. In July 1979, the full 4th Circuit reversed that decision. In April 1980 the Supreme Court remanded the case back to the 4th Circuit. The appeals court reaffirmed its earlier decision. The state appealed again, out of which came last week's Supreme Court ruling.

During the course of the appeals, Davis says, he "tried to put it all out of my mind, get a new start." After 2 1/2 years at the counseling center, he tried to start a nightclub but failed. He took odd construction jobs and worked as a maintenance worker at a nearby Days Inn Motel and at his apartment complex.

Davis joined the Mason's King Solomon Lodge No. 1 and became a master mason, began taking Tae Kwon Do, a passion he hopes to develop into a his own martial arts school in the future. Two years ago, he and his wife had their daughter, Heather. "It was something we had deliberately put off, but went ahead with when we were starting to think this whole thing was finally over," Davis says.

The Davises also had two new run-ins with the law. In July 1979, Roanoke police arrested Carol Davis on a charge of possession of Quaaludes and marijuana. The case was dropped for lack of evidence, says her Roanoke attorney, Arthur P. Strickland.

Three months later, Roanoke police arrested Roger Davis for possession of one ounce of marijuana. Strickland, who also handled that case, says Davis settled by agreeing to serve two weekends in jail and to pay a $150 fine. Since then, say Roanoke vice squad detectives, neither of the Davises has been arrested, nor is either suspected of being involved in drug use or sales.

Last week, when Davis learned of the Supreme Court's decision, he stopped his Tae Kwon Do lessons. "It's difficult to do anything," he says. "It occupies your mind most of the time. It's hard to think, hard to work, hard to do any damn thing."

Hogshire says he will ask Virginia's new governor, Charles S. Robb, to grant Davis a conditional pardon. Robb's predecessor, John N. Dalton, granted three conditional pardons to others after signing into law less strict marijuana statutes in 1979.

In each of the cases--including one in which a 27-year-old quadriplegic from Danville had been sentenced to 21 years in jail for possession of one-third of an ounce of marijuana with the intent to sell--Dalton reduced the sentences to comply with the new laws. The 27-year-old's sentence was reduced to one year. Under the new laws Davis would have received a maximum of 20 years in prison.

Deputy Virginia Attorney General James Kulp, who argued the Davis case before the Supreme Court, says Davis is not an innocent victim of society, pointing to his LSD and marijuana arrests. It was not Roger Davis that worried former state attorney general J. Marshall Coleman, but federal court interference with state law, Kulp says.

"The thing that concerned us was the principle," he said.

So Roger Davis waits. He worries about leaving his wife alone--"about her having to try and explain to Heather why Daddy can't come home." He looks over his beer at a local pub, a wood-paneled place with roaring video machines in one corner and the abandoned instruments of a rock band in another, and a muscle below his right eye begins to twitch. The words rush out, and the Pied Piper charm, the Tae Kwon Do discipline and the Davis cool evaporate.

"You don't send a person to jail to be rehabilitated," he says. "Everybody there is a criminal. You go there and you're there with murderers, rapists, thieves . . . what is there to talk about but murders and rapes and things people got away with. The guards are undereducated, they are there to get their checks and make sure you don't escape. You're sleeping beside someone and its obvious he's a nut and you think, 'Am I supposed to be here beside this fool?' . . . "

"I'm trying to find a way out, looking for people to help me, anybody really, anybody that knows it's wrong, thinks it's wrong, has some compassion. I know in my heart I haven't done anything wrong. When I get out, I'll be old. My life will be over."