Analogous form of Hardy-Littlewood maximal inequality (weak/strong type) on affine subspaces I'm using some online notes (Professor Schlag, Yale University) to study harmonic analysis by myself. He introduced the following claim as an exercise:
For any function $f \in L^{1}(\mathbb{R}^{d})$ and fixed $1 \leq k \leq d$, let's consider an "analogous" form of the Hardy-Littlewood function $\mathcal{M}_{k}f$ defined as follows:
$$\mathcal{M}_{k}f(x) = \sup_{r > 0}\frac{1}{r^k}\int_{B(x,r)}|f(y)|dy$$
Fix an arbitrary affine subspace $L \subseteq \mathbb{R}^{d}$ of dimension $k$. Let $m_{L}$ denote its Lebesgue measure. Then we have that there exists some constant $C>0$, such that for any $\lambda >0$, the following "analogous" form of weak-type Hardy-Littlewood maximal inequality holds:
$$m_{L}(\{x \in L \ | \ \mathcal{M}_{k}f(x) > \lambda\}) \leq \frac{C}{\lambda}||f||_{L^1(\mathbb{R}^{d})}$$
I have attempted this exercise by taking the intersection of the $k$-dim subspace $L$ and an arbitrary
$d$-dim ball to derive some bounds, but it seems that it doesn't help much.

Any idea on this problem? Moreover, can we also develop some similar
form of strong-type Hardy-Littlewood maximal function with respect to
an arbitrary affine subspace?

 A: The proof of the Weak Type inequality is essentially the same as the usual case:
For convenience, let $\Lambda = \{ x\in L | \mathcal{M}_k f(x) > \lambda \}$.
Then there exists $r:\Lambda \to (0,\infty)$ such that $\lambda r^k < \int_{B(x,r)} |f| ~dx$.
Apply the Vitali covering lemma to $\Lambda \subset L$, so there is a countable set of $(x_i)_{i\in \mathbb{N}} \subset \Lambda$ such that $B(x_i, r(x_i))$ are disjoint, but $B(x_i, 5 r(x_i))$ covers $\Lambda$.
And so
$$ m_L(\Lambda) \leq \sum m_L(B(x_i, 5r(x_i))) \leq C \sum r(x_i)^k  \leq \frac{C}{\lambda} \sum \int_{B(x_i, r(x_i)}  |f| ~dx $$
Since the balls are disjoint, we have that the sum of the integrals is equal to the integral on the union, and thus is dominated by $\|f\|_{L^1}$.

For the strong type inequality: that $\mathcal{M}_k : L^\infty(\mathbb{R}^d) \to L^\infty(L)$ is obvious. The first half proves that it is $L^1(\mathbb{R}^d) \to L^1_\infty(L)$. So you can apply Marcinkiewicz (real) interpolation and immediately get strong type inequality.
