Skin-friction generation by attached eddies in turbulent channel flow