The regular p-gonal prism tilings and their optimal hyperball packings in the hyperbolic 3-space