Maryland’s General Assembly on Monday voted to revise its relatively new but flawed medical marijuana law to make the program workable and ease access to the drug for patients who need it.

The measure – sponsored by Sen. Jamie B. Raskin (D-Montgomery), Del. Cheryl D. Glenn (D-Baltimore) and others – is intended to allow specially certified private physicians to help their patients obtain marijuana for medicinal purposes through a state-approved distribution network.

The Senate’s vote was 47 to 0, while the House passed the measure 125 to 11.

“I’m ecstatic,” said Del. Cheryl D. Glenn (D-Baltimore), whose mother’s suffering during an illness that proved fatal might have been alleviated by medical marijuana. “This has been an emotional rollercoaster for me.”

Under the law enacted last year, responsibility for administering the medical marijuana program was given to academic medical centers, but none was willing to participate.

Under the compromise that passed Monday, the state’s existing marijuana commission would certify physicians with the ability to recommend that their patients receive the drug. Those patients would then obtain ID cards from the commission that would allow them to obtain the drug from a network of state-licensed growers and dispensaries.

The measure also regulates the number of growers and dispensaries, and it prohibits participants in the system from accepting gifts or having a financial interest in either producers or dispensaries.

“We’re very satisfied with the details,” Raskin said. “It’s been very bipartisan and searching for best practices in other states where it’s been done.”

In its final form, the bill would license up to 15 growers, Raskin said. The commission would later review the program to see whether that number of growers was sufficient or whether more are needed. In earlier versions of the bill, the House passed a measure limiting the number of growers to 10; the Senate did not have a cap and instead allowed the commission to determine the number.

Glenn said the marijuana commission is named in honor of her mother, Natalie M. LaPrade, who died of cancer about four years ago. Glenn said her mother, who could not eat because of her illness, might have been helped by medical marijuana, which acts as an appetite stimulant. She said the family talked about obtaining the drug for her mother event though the law did not permit it, but her mother refused.

“My mother wouldn’t do anything illegal,” Glenn said.