What will be the condition of $m$ and $c$ to satisfy, if the line $y=mx +c$ touches the circle $x^2+y^2=2ax$?

As given,

$$y=mx+c\\\tag{1}$$

$$x^2+y^2=2ax\\\tag{2}$$

Put value of $y$ from Eq(1) in Eq(2) results in:

$$x^2 + (mx+c)^2=2ax$$

$$x^2 + m^2x^2+c^2+2mxc = 2ax$$

$$x^2(1+m^2) + x(2mc-2a) + c^2=0$$

This is Quadratic equation and as line touches the circle hence its discriminant ($b^2-4ac$) will be zero and will have only repeated real number solution, hence:

$$(2mc-2a)^2-4c^2(1+m^2)=0$$

After simplification it becomes,

$$4a^2-4c^2=8mca$$

$$a^2-c^2=2mca$$

or

$$ c^2=a^2-2mca$$

This is the condition for both $m$ and $c$, which will yield a line touching the circle $(x^2+y^2-2ax=0)$.