If you are interested in this I highly recommend studying SeL4. A practical industrial proven correct micro kernel used by billions of devices worldwide.