Use of lower quality primer that has inadequate adhesion and flexibility over thinning or overspreading the paint. or appropriate primer was not used. Inadequate surface preparation, or applying the paint to the surfaces without first applying a primer.
Remedy
Remove loose and flaking paint with a scraper or wire brush, sanding the surface and feathering the edges. If the flaking occurs in multiple layers of paint, using a filler may be necessary. Prime the surfaces before repainting. Use of a top quality primer and top coat should prevent a recurrence of the problem.