"And if your lordship has brought in the mention of my book in a chapter, intitled, “Objections against the Trinity, in Point of Reason, answered;” when, in my whole Essay, I think there is not to be found any thing like an objection against the Trinity: I have the more to acknowledge to your lordship, who would not let the foreignness of the subject hinder your lordship from endeavouring to set me right, as to some errours your lordship apprehends in my book; when other writers using some notions like mine, gave you that which was occasion enough for you to do me the favour to take notice of what you dislike in my Essay...If your lordship had showed me any thing in my book, that contained or implied any opposition in it to any thing revealed in holy writ concerning the Trinity, or any other doctrine contained in the bible, I should have been thereby obliged to your lordship for freeing me from that mistake, and for affording me an opportunity to own to the world that obligation, by publicly retracting my errour."
Locke believed inerrancy of the Bible, which no doubt teaches The Trinity:
"The holy scripture is to me, and always will be, the constant guide of my assent; and I shall always hearken to it, as containing infallible truth, relating to things of the highest concernment. And I wish I could say, there were no mysteries in it: I acknowledge there are to me, and I fear always will be. But where I want the evidence of things, there yet is ground enough for me to believe, because God has said it: and I shall presently condemn and quit any opinion of mine, as soon as I am shown that it is contrary to any revelation in the holy scripture. But I must confess to your lordship, that I do not perceive any such contrariety in any thing in my Essay of Human Understanding."~Postscript to "A Letter to the Right Rev. Edward ... concerning some passages relating to Mr. Locke's 'Essay on Human Understanding.'"
The evidence that Locke was an arian or socinian is not from his own words, but opinions from people from a faulty foundation, such as: his unitarian friends, like Isaac Newton, and his library containing books on unitarianism. He spent his entire life fighting the label of arian or socinian.
"I expound, [Edwards] says, John 14.9 &c. after the Antitrinitarian Mode: And I make Christ and Adam to be Sons of God, in the same sense, and by their Birth, as the Racovians [i.e. Socinians] generally do. I know not but it may be true, that the Antitrinitarians and Racovians understand those places as I do: But ’tismore than I know that they do so. I took not those Texts from those Writers, but from the Scripture itself, giving Light to its own meaning, by one place compared with another: What in this way appears to me its true meaning, I shall not decline, because I am told, that it is so understood by the Racovians, whom I never yet read."(Writings on Religion, p. 219)
This particular quote by Locke doesn't prove he was anti-trinitarian, but that he didn't know what particular Anti-Trinitarian, and Racovian writers believed. If he believed the Bible taught anti-trinitarianism, he blatantly contradicted himself in his Letter to the Right Rev. Edwards, as he says he never wrote against the trinity. What is more believable, did he or didn't he contradict himself? Was Locke familiar with Racovian literature on the Trinity? He says he never read their literature.