Re: [PATCH v2] seq_file: Unconditionally use vmalloc for buffer

From: Michal Hocko
Date: Tue Mar 16 2021 - 09:02:24 EST

On Tue 16-03-21 12:43:12, Al Viro wrote:
> AFAICS, Kees wants to protect against ->show() instances stomping beyond
> the page size. What I don't get is what do you get from using seq_file
> if you insist on doing raw access to the buffer rather than using
> seq_printf() and friends. What's the point?

I do not think there is any and as you have said in other response we
should really make seq_get_buf internal thing to seq_file and be done
with that. If there is a missing functionality that users workaround by
abusing seq_get_buf then it should be added into seq_file interface.
Michal Hocko