A reactive control technique with localised actuators and sensors is used to delay the transition to turbulence in a flat-plate boundary-layer flow. Through extensive direct numerical simulations, it is shown that an adaptive technique, which computes the control law on-line, is able to significantly reduce skin-friction drag in the presence of random three-dimensional perturbation fields with linear and weakly nonlinear behaviour. An energy budget analysis is performed in order to assess the net energy saving capabilities of the linear control approach. When considering a model of the dielectric-barrier-discharge (DBD) plasma actuator, the energy spent to create appropriate actuation force inside the boundary layer is of the same order as the energy gained from reducing skin-friction drag. With a model of an ideal actuator a net energy gain of three orders of magnitude can be achieved by efficiently damping small-amplitude disturbances upstream. The energy analysis in this study thus provides an upper limit for what we can expect in terms of drag-reduction efficiency for linear control of transition as a means for drag reduction.