Hello!
Have you got Nikon “Active D-Lighting” switched on, as your curve seems to show its effect, namely to boost the brightness gradient for low brightness levels, while stopping bright areas from reaching “fully white”?
If this is the problem, then switching off “Active D-Lighting” should solve the problem, and give a linear response.
Good wishes,
Peter Lyon