In this appeal, Jason D. Albertson challenges the district court’s refusal to give him credit for time spent in custody before and after his judgment of conviction but prior to the commutation of Albertson’s sentence upon revocation of his probation. We reverse the district court’s decision and remand the case for determination of the credit to which Albertson is entitled.
Albertson pleaded guilty to felony driving without privileges, Idaho Code § 18-8001(5) (1997).1 On December 12,1996, he was given a unified three-year sentence with a one and one-half-year minimum term of imprisonment. Albertson received credit on this sentence for one day that he served in jail prior to the judgment. The district court retained jurisdiction for 180 days pursuant to I.C. § 19-2601, during which time Albertson was incarcerated in the custody of the State Board of Correction. At the conclusion of the retained jurisdiction period, the district court suspended Albertson’s sentence and placed him on probation.
On April 28, 1998, the State filed a report of probation violations. Another report was filed on June 4,1998, while disposition of the first report was still pending. Albertson admitted some of the violations. On July 24, 1998, the district court reinstated Albertson’s probation subject to additional conditions, including a requirement that he serve seventy-four days in county jail with credit on this jail term for sixty-three days previously served. The record does not disclose just when Albertson served the sixty-three days for which credit was given.
On June 30, 1999, a new report of probation violations was filed. Albertson and the prosecutor entered into a stipulation by which Albertson agreed to admit the probation violations and the prosecutor agreed to recommend that the district court commute Albertson’s sentence, pursuant to I.C. § 19-2601(1), to one year in the county jail with work release privileges. At a hearing on July 10, 1998, the district court accepted this recommendation, revoked Albertson’s probation, and then commuted Albertson’s sentence as agreed by the parties. The district court specified that it would allow eleven days’ credit for time previously served against the one year of county jail confinement. We surmise that those eleven days were served by Albertson between June 30, 1999, when the most recent probation violation report was filed, and the July 10 disposition date.
Albertson subsequently filed a motion for credit for time served, alleging that he was entitled to credit for all the time that he had been incarcerated in connection with this offense before his sentence was commuted. This motion was denied. The district court explained:
Well, let me state first of all what my thinking was as I recall at the time I commuted the defendant’s sentence. It was my thought process at that time that a one-year sentence in the county jail would beat a one and half year to three-year sentence in the State Penitentiary. I believed at that time that the defendant who was seeking work release from me could only get that from the county jail, and not from the penitentiary, and I thought that was a gigantic advantage to defendant to be here in county jail where he could have work release. It was also my thought at the time I gave the sentence, that by being done with the matter at the end of one year, was a big advantage to going to the State Penitentiary doing whatever amount of time and coming out and being on parole for the balance of the total three years. So it was, in fact, my belief that I was doing the defendant a favor when I commuted his sentence from a maximum of three to a maximum of one. I’m not sure I thought through the time in terms of what he had spent in jail very well. He was represented by counsel.... Counsel in my presence seemed to all agree that 11 *725days of time served was appropriate, and so this Court accepted that. I don’t think that I thought through let’s count up the number of days that he had. I didn’t think I had to when I commuted the sentence and believed that in commutation, that I was doing the defendant a favor.
Albertson now appeals the denial of his motion.2
ANALYSIS
The computation of time served on a sentence of incarceration is governed by I.C. § 18-309, which provides:
In computing the term of imprisonment, the person against whom the judgment was entered, shall receive credit in the judgment for any period of incarceration prior to entry of judgment, if such incarceration was for the offense or an included offense for which the judgment was entered. The remainder of the term commences upon the pronouncement of sentence and if thereafter, during such term, the defendant by any legal means is temporarily released from such imprisonment and subsequently returned thereto, the time during which he was at large must not be computed as part of such term.
Albertson asserts that under this statute the district court was required to give him credit for any time served as a result of his arrest and conviction in this case, whether before or after entry of the judgment and pronouncement of sentence.
The question presented is one of statutory interpretation, a question of law over which this Court exercises free review. State v. Martinez, 126 Idaho 801, 803, 891 P.2d 1061, 1063 (Ct.App.1995). Our role in interpreting a statute is to give effect to the clear intent of the legislature as expressed in the language used. Crawford v. Dep’t of Corr., 133 Idaho 633, 635, 991 P.2d 358, 360 (1999); Martinez, supra.
Idaho Code § 18-309 divides a criminal defendant’s time served into two broad categories. The first sentence of the statute deals with any period of incarceration in a county jail while the defendant is awaiting disposition of the charge. It is well established that this portion of the statute requires credit for any prejudgment incarceration that is attributable to the offense for which the sentence is imposed. Law v. Rasmussen, 104 Idaho 455, 660 P.2d 67 (1983); State v. Peterson, 121 Idaho 775, 777, 828 P.2d 338, 340 (Ct.App.1992).
The second sentence of § 18-309 addresses the time served after the entry of judgment. It states that the “remainder of the term commences upon the pronouncement of sentence,” implying that all time spent in custody after sentencing is credited to the defendant’s sentence. The decisional law of this state has consistently applied this provision so as to allow credit against a sentence for any time spent in custody after the entry of judgment, except periods of county jail incarceration that were served as a condition of probation. In State v. Banks, 121 Idaho 608, 610, 826 P.2d 1320, 1322 (1992), the Idaho Supreme Court held that a period of confinement served solely as a condition of probation is not counted as time served on the suspended sentence if the probation is subsequently revoked. See also State v. Jakoski, 132 Idaho 67, 966 P.2d 663 (Ct.App.1998); State v. Lively, 131 Idaho 279, 954 P.2d 1075 (Ct.App.1998). Any other periods of post-judgment incarceration, however, must be credited to the sentence. Thus, a defendant is entitled to credit for time spent in the retained jurisdiction program. State v. Machen, 100 Idaho 167, 171, 595 P.2d 316, 320 (1979); State v. Chilton, 116 Idaho 274, 275, 775 P.2d 166, 167 (Ct.App.1989). Likewise, if a defendant was arrested for probation violations and spent time in confinement awaiting the disposition of the alleged violations, that incarceration must be credited against the underlying sentence because it was not served voluntarily as a condition of probation. I.C. § 19-2603; State v. Buys, 129 Idaho 122, 127, 922 P.2d 419, 424 (Ct.App.1996); Peterson, 121 Idaho at 779, 828 P.2d at 342. The reduction of a defendant’s sentence does not per se constitute credit for time served. Id. at 778, 828 P.2d at 341.
*726Albertson’s sentence was commuted pursuant to I.C. § 19-2601(1) which states: ‘Whenever any person shall have been convicted, or enter a plea of guilty, ... of or to any crime against the laws of the state, except those of treason or murder, the court in its discretion, may: 1. Commute the sentence and confine the defendant in the county jail----” Other types of sentence modifications are also authorized by Idaho Criminal Rule 35, which provides that a trial court may modify a sentence in certain circumstances, including “upon revocation of probation.” For purposes of applying credit for time served, we perceive no substantive difference between the commutation of a sentence under § 19-2601(1) and any other modification of a sentence under I.C.R. 35. The only apparent distinction is that a sentence that has been “commuted” is served in the county jail rather than in the custody of the Board of Correction. We have been shown no reason why this distinction in the location where the confinement is to be seived would affect the applicability of I.C. § 18-309 with respect to credit for time served.
We recognize that when the district court accepted the parties’ stipulation for commutation, it subjectively intended that Albertson would serve a full year in county jail, and the court felt that this sentence modification, allowing the defendant to be incarcerated in the county jail with work release privileges rather than serving his sentence in the state penitentiary, was an exercise of leniency which was, in effect, a substitute for credit for time already served.3 However, the provisions of I.C. § 18-309 are mandatory and do not confer upon the trial court discretion to disallow credit on a sentence. There was no express waiver by Albertson of his right to credit under § 18-309 as a part of the parties’ stipulation. Therefore, we cannot uphold the district court’s disallowance of credit on Albertson’s commuted sentence for time previously served both before and after his judgment of conviction.
We conclude that there must be credited against Albertson’s commuted sentence all prejudgment incarceration that resulted from his arrest for this offense, all of Albertson’s incarceration during the retained jurisdiction period before he was placed on probation, and all periods of incarceration in the county jail that were a consequence of his arrests for probation violations. He is not entitled to credit for an additional eleven days he was ordered to serve as a condition of reinstatement of his probation pursuant to the district court’s order of July 24, 1998 (in which the court ordered that Albertson serve seventy-four days in county jail as a condition of reinstatement of probation but gave him credit for sixty-three days previously served). The appellate record does not contain sufficient information about the periods of Albert-son’s incarceration to allow this Court to calculate the total credit to which he is entitled. Therefore, we must remand the matter to the district court for that determination.
The order of the district court denying Albertson’s motion for credit for time served is reversed, and this matter is remanded to the district court for computation of credit in conformity with this opinion.
PERRY, J., concurs.. Due to subsequent legislative amendment, driving without privileges is now a misdemeanor. 1998 Idaho Sess. Laws, ch. 325, § 1.
. Albertson has been released on his own recognizance pending this appeal.
. Although the commutation to one year in the county jail reduced Albertson's overall sentence, we note that, if credit for time served is not allowed, it actually increased Albertson’s minimum term, for he had already served substantially more than half a year on his original one and one-half-year minimum term of imprisonment.