One of NSW's most senior public servants shared in $2.5 million payments from a charity he directed, payments that potentially breach state law and that are the subject of an ongoing state government investigation.

Fairfax can reveal that Jim Longley, chief executive of the $2.7-billion Department of Ageing, Disability and Home Care, is part of a charity payments probe which has already triggered the resignation of the national RSL President. The affair has now been referred to the NSW Police and is the subject of an ongoing NSW Fair Trading investigation, Fairfax Media has learned.

Jim Longley, a former Liberal minister and top bureaucrat, was an RSL LifeCare director.

Mr Longley, a former state Liberal MP, was one of 10 directors of charity nursing home provider RSL LifeCare who shared in a total pool of more than $2.5 million in "consultancy fees", financial statements show. Annual instalments of up to $370,000 were divided between all 10 directors of the company from 2010 to 2016.

State law prohibits directors of a charity from being remunerated unless they have express approval from a government minister.