Abstract-We consider a general triplet Markov Gaussian linear system (X, R, Y), where X is an hidden continuous random sequence, R is an hidden discrete Markov chain, Y is an observed continuous random sequence. When the triplet (X, R, Y) is a classical "Conditionally Gaussian Linear State-Space Model" (CGLSSM), the mean square error optimal filter is not workable with a reasonable complexity and different approximate methods, e.g. based on particle filters, are used. We propose two contributions. The first one is to extend the CGLSSM to a new, more general model, called the "Conditionally Gaussian Pairwise Markov Switching Model" (CGPMSM), in which X is not necessarily Markov given R. The second contribution is to consider a particular case of CGPMSM in which (R, Y) is Markov and in which an exact filter, optimal in the sense of mean square error, can be performed with linear-time complexity. Some experiments show that the proposed method and the suited particle filter have comparable efficiency, while the second one is much faster.Index Terms-Conditionally Gaussian linear state-space model, conditionally Gaussian pairwise markov switching model, exact optimal filtering, Gaussian switching system, hidden Markov models.