To make room, infielder-outfielder Garin Cecchini was returned to Pawtucket.
The 25-year-old Barnes made his first major-league start Monday. The right-hander had pitched 21 games in relief for the Red Sox this season.
Cook, acquired in a trade from Oakland at the non-waiver deadline, has made three relief appearances in two different stints on the roster.
The 26-year-old Hembree is with the club for the fourth time this season.