From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: [patch 18/21] vfs: seq_file: add helpers for data filling Date: Mon, 21 Sep 2009 11:03:01 +0100 Message-ID: <20090921100301.GI5858@ZenIV.linux.org.uk> References: <200909182006.n8IK604x019735@imap1.linux-foundation.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org, mszeredi@suse.cz, Valdis.Kletnieks@vt.edu, agruen@suse.de, hch@lst.de, hugh.dickins@tiscali.co.uk, matthew@wil.cx To: akpm@linux-foundation.org Return-path: Received: from zeniv.linux.org.uk ([195.92.253.2]:54077 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755880AbZIUKDA (ORCPT ); Mon, 21 Sep 2009 06:03:00 -0400 Content-Disposition: inline In-Reply-To: <200909182006.n8IK604x019735@imap1.linux-foundation.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, Sep 18, 2009 at 01:06:00PM -0700, akpm@linux-foundation.org wrote: > From: Miklos Szeredi > > Add two helpers that allow access to the seq_file's own buffer, but > hides the internal details of seq_files. > > This allows easier implementation of special purpose filling > functions. It also cleans up some existing functions which duplicated > the seq_file logic. Nice, but I suspect that exporting those two would be the right thing. That, or inlining them - we are not actually hiding anything here, seeing that struct seq_file is declared right there in the seq_file.h. I'm certainly fine with these helpers and associated cleanup. Unless somebody has realistic plans of actually hiding the seq_file implementation[1], I'd simply inline those two in seq_file.h. Miklos? [1] one obvious obstacle is that callers of seq_open() may want at least to set seq_file->private; that can be solved, of course, but I won't swear that we have nothing beyond that