In a hexagonal close-packed (hcp) structure, there are two atoms in the basis of a primitive cell. This is because, while the hcp lattice has a total of 6 atoms in a unit cell, when accounting for the fractional contributions of atoms at the edges and corners, the number of atoms in the primitive cell (basis) is reduced to 2.
Therefore, the correct answer is 2.