We give a representation of the solution for a stochastic linear equation of the form Xt=Yt+∫(0, t]Xs− dZs where Z is a càdlàg semimartingale and Y is a càdlàg adapted process with bounded variation on finite intervals. As an application we study the case where Y and −Z are nondecreasing, jointly have stationary increments and the jumps of −Z are bounded by 1. Special cases of this process are shot-noise processes, growth collapse (additive increase, multiplicative decrease) processes and clearing processes. When Y and Z are, in addition, independent Lévy processes, the resulting X is called a generalized Ornstein–Uhlenbeck process.