Politicians have written to Scotland's top law officer seeking answers about the fatal accident inquiry process after a prisoner died while being restrained.

Allan Marshall was being held on remand at HMP Edinburgh in March 2015 when he suffered a cardiac arrest during a lengthy struggle with staff, during which he was dragged face down and feet first by prison officers.

A sheriff described his death as "entirely preventable" after a fatal accident inquiry (FAI).

Holyrood's Justice Committee said the circumstances of his death are "both shocking and a matter of grave concern" and the inquiry has raised a number of questions about FAIs.

Committee convener Margaret Mitchell MSP has written to Lord Advocate James Wolffe QC to ask what steps are being taken to improve the time taken for FAIs in Scotland.

She asks if there are sufficient resources available to be able to "complete these FAIs in as short a period as is possible whilst at the same time retaining the rigorous process that needs to be followed in each case".

The letter, dated September 9, also asks what criteria is used to decide whether a prosecution is viable and, in cases such as Mr Marshall's, asks on what grounds and to whom Crown counsel would decide to offer immunity from prosecution.

The committee also requests information about how many times in the last five years a decision to grant immunity from prosecution for individuals involved in an FAI has been taken.

The letter also asks for current data on the length of time taken on average for FAIs conducted this year and last year to begin and conclude.

Justice secretary Humza Yousaf has said he will meet Mr Marshall's family and that they deserve an apology.

The family hit out at the justice secretary last week, stating it took him 21 days to respond following the publication of the sheriff's findings.

Mr Marshall's aunt, Sharon MacFadyen, told STV News: "It's unbelievable. I just felt there were no emotions in the letter at all. It's took him 21 days to even respond to it. I just find that shocking.

"It's been heartbreaking. We miss him every day, we talk about him every day.

"I'm actually frightened for anyone else who goes into prison because it could happen to anybody.

"They've found this heart condition and they've blamed it on that rather than saying 'lets look at the CCTV'.

"What we see in the CCTV is horrendous. No one will ever know the truth of what went on in that shower block. He needs to look back at everything."

After the FAI, sheriff Gordon Liddle said there were "instances when better training of SPS staff could have made the difference".

He concluded: "I am satisfied that the evidence which has been led in this inquiry amply demonstrates that Mr Marshall's death was entirely preventable."

The Scottish Prison Service (SPS) is currently considering 13 recommendations made after the FAI.

Last week, Mr Yousaf told MSPs at Holyrood the SPS was "rightly reflecting" on the findings of the FAI and its 13 recommendations.

In addition, he said SPS bosses would seek expert, external advice as part of a review into the use of control and restraint procedures.

A Crown Office spokesman said: "The Lord Advocate and COPFS has received correspondence from the Justice Committee and will respond in due course."