  Recently, subfiled codes of linear code over GF$ (q) $ with good parameters
were studied, and many optimal subfield codes were obtained. In this paper, Our
mainly motivation is to generlize the results of the subfield codes of
hyperoval in Ding and Heng (Finite Fields Their Appl. 56, 308-331 (2019)), and
generlize the results of two families of subfield codes in Xiang and Yin
(Cryptogr. Commun. 13(1), 117-127 (2021)) to $ p $-ary where $ p $ is odd. We
get the parameters and weight distribution of these subfield codes. At the same
time, the parameters of their dual codes are also studied. When $ m=1 $, The
dual codes of these subfield codes are almost MDS code, when $ m>1 $ and $ p $
odd, these dual codes are dimension-optimal with respect to the sphere-backing
bound.
