Why is buffer stock created by the government?

Buffer stock is the stock of grains that is stored by the government in the granaries of Food Corporation of India. This stocking is done by buying grains directly from the farmers and even from the market in case of any emergencies. The stock is used for distribution of grains to the poor at subsidized rates through the public distribution system. This grain is also used in case of any calamities like flood, drought, war etc.