Sow flour into a deep bowl, grate frozen butter there, and grow well with your hands adding ice water and salt. Knead the dough. Put it in a bag and refrigerate for 1 hour.
Grate potatoes on a coarse grater, fry in oil, salt, and pepper. Chop the onion finely, fry with mushrooms until tender. Grate cheese on a coarse grater.
Beat eggs with cream, salt. Roll out the dough into a layer, put in a mold, pierce with a fork in several places. Put in the oven at 180C and bake for 15 minutes. Then take out, sprinkle with some of the cheese, then potatoes, again some of the cheese, mushrooms, and onions, and again the remaining cheese. Pour it all over with eggs and cream. Sprinkle with herbs. Bake for another 40 minutes.