Calluses are caused by friction against the same area repeatedly. Corns are calluses caused by bones pressing the skin against your shoe.
Corns and calluses can usually be treated without surgery, but if they are caused by a deformity like hammertoe or by bone where bone isn’t normally surgery may be needed to remove them.