For a standard Brownian motion $dB_t$ the infinitesimal generator is given as $$\mathcal{G}f(t,x)=\dfrac{1}{2}\dfrac{\partial^2}{\partial x^2}f(t,x).$$ So, when I have a Kolmogorov backward equation to the effect that $$\dfrac{\partial}{\partial t}p(t,x)=\mathcal{G}\,p(t,x),$$ I can verify that $$p(t,x)=\dfrac{1}{\sqrt{2 \pi t}}\exp\left(-\dfrac{1}{2}\,\dfrac{x^2}{t}\right)$$ would satisfy this equation.
I am struggling to recover an expression for $p(t,x)$ when I am working with either a Brownian motion with scalar drift and diffusion coefficient, i.e. $dX_t=\mu\,dt+\sigma\,dB_t$ such that the infinitesimal generator would be $$\mathcal{G}f(t,x)=\mu\dfrac{\partial}{\partial x}f(t,x)+\sigma^2\dfrac{\partial^2}{\partial x^2}f(t,x)$$ or an Ornstein-Uhlenbeck process such that $dX_t=\theta(\mu-X_t)\,dt+\sigma\,dB_t$ such that we have $$\mathcal{G}f(t,x)=\theta(\mu-x)\dfrac{\partial}{\partial x}f(t,x)+\sigma^2\dfrac{\partial^2}{\partial x^2}f(t,x).$$
I'd very much appreciate it if anyone could help me find a density $p(t,x)$ from the above Kolmogorov backward equation in both of these cases.
Thank you.