All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
The expenses of operating the mill, like the cost of fuel, the wages of the workers and what you spend on its maintenance are all not included when calculating the Zakah.
The method of calculating the Zakah on the profit of this mill is to calculate the profit when the Zakah becomes due and then you deduct from it whatever expenses that were already due and you have not paid yet, then if what remains from it reaches a Nisaab (i.e. the minimum amount liable for Zakah) and a whole lunar year has already elapsed over it, then you pay out of it 2.5 %.
Allaah Knows best.