For the p-dimensional filiform Lie algebra m 2 (p) over a field F of prime characteristic p ≥ 5 with nonzero Lie brackets [e 1 , e i ] = e i+1 for 1 < i < p and [e 2 , e i ] = e i+2 for 2 < i < p − 1, we show that there is a family m λ 2 (p) of restricted Lie algebra structures parameterized by elements λ ∈ F p . We explicitly describe bases for the ordinary and restricted 1-and 2-cohomology spaces with trivial coefficients, and give formulas for the bracket and [p]-operations in the corresponding restricted one-dimensional central extensions.