DCP error: product is complex

Let H = [1 i;-i 1], which is Hermitian semidefinite.
Let w2 be the real vector [1;1].
Then w2'*H = [1-i 1+i]
Therefore,w2'*H*w is a linear function of w, but is complex, not real. As mentioned in response to one of your previous questions DCP error: {complex affine} >= {constant} , you can not have complex expressions in an inequality in CVX.