Re: [RFC] fs: move super_block and inode definitions to central fs.h header

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jan 25, 2016 at 09:40:26AM +0100, Yegor Yefremov wrote:
> On Mon, Jan 25, 2016 at 9:20 AM, Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> wrote:
> > On Sun, Jan 24, 2016 at 08:55:22PM +0100, Yegor Yefremov wrote:
> >> On Sun, Jan 24, 2016 at 8:24 PM, Yegor Yefremov
> >> <yegorslists@xxxxxxxxxxxxxx> wrote:
> >> > Both super_block and inode are common to various file systems, so
> >> > move them to the central place.
> >> >
> >> > Signed-off-by: Yegor Yefremov <yegorslists@xxxxxxxxxxxxxx>
> >> > ---
> >> >  fs/ubifs/ubifs.h | 134 +------------------------------------------------------
> >> >  include/fs.h     | 134 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
> >> >  2 files changed, 135 insertions(+), 133 deletions(-)
> >>
> >> I'm trying to port SquashFS to Barebox. SquashFS uses at least both
> >> super_block structure as also inode structure. Does it make sense to
> >> introduce include/linux/fs.h?
> >
> > I think not. Using include/linux/ for header files is good for stuff
> > directly taken from the kernel, but I think the fs related structures in
> > barebox are quite different from the ones in the kernel.
> 
> So you're OK about moving super_block and inode to inculde/fs?

Sorry, I should have read the patch before replying to your followup.
You were talking about the struct inode/superblock in ubifs which indeed
are taken from the kernel and not actively used by barebox. These should
indeed go to include/linux/.

> 
> >> What to do with struct timespec? It is defined in uapi part. Should it
> >> go to include/linux/barebox-wrapper.h?
> >
> > barebox-wrapper.h contains no-op wrappers for stuff from the kernel that
> > we want to keep around just to be able to compile kernel code with less
> > modifications. struct timespec doesn't really fall into that category, I
> > rather suggest its original place: include/linux/time.h
> 
> OK. Then I'll move it there. Should I also add timeval and related
> marcos as well?

I would rather take the lazy approach and add them as needed.

Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux