History log of /haiku/src/add-ons/kernel/file_systems/xfs/Inode.cpp
Revision Date Author Comments
# 641b9f70 27-Mar-2024 priyanshu-gupta07 <guptapiyush.0707@gmail.com>

xfs: Inode Structure updated

background: Inodes structure needs to be updated in the same on Disk format for uniforming the code.

Inode structure is Updated to the OnDisk format same as that of Extent Header and the relative Changes are made to Inode class.

Change-Id: I1e89c514a7abe29479b152c6b038ff8b7c94abce
Reviewed-on: https://review.haiku-os.org/c/haiku/+/7552
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Haiku-Format: Haiku-format Bot <no-reply+haikuformatbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# 43a88749 02-May-2023 Mashijams <raghavself28@gmail.com>

xfs: remove unnecessary macros

No functional changes just remove all the clutter caused by macros and flags that are never used

Change-Id: Iac0cc3fd873dbf11a379b33e4371902fa1181804
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6405
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Reviewed-by: John Scipione <jscipione@gmail.com>


# 0849c914 14-Feb-2023 Adrien Destugues <adrien.destugues@opensource.viveris.fr>

xfs: Enable -Werror, fix all warnings

Define a dedicated OnDiskData structure for each on-disk structure. This
must match the on-disk layout, except for endianness, which is handled
by _SwapEndian methods. These structure are "plain old data" so we can
use offsetof on them. They are wrapped in an easier to use C++ API.

This resolves a lot of problems with the previous code: warnings caused
by the use of offsetof as well as a much simpler instanciation of the
objects from on-disk data.

Also fixed another problem with UUIDs, where the UUIDs were handled by
pointers in a lot of place where it was not necessary. Use references
instead. The V4 structures which don't have an UUID will return a "null"
(zero-filled) one.

Change-Id: Ifb2bf6ab94906ca50410dd3446d3566615392ca2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/6021
Reviewed-by: Raghav Sharma <raghavself28@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 88131dc3 01-Sep-2022 Mashijams <raghavself28@gmail.com>

xfs: Node xattrs

- Implemented node based extended attributes support

- Both Versions of xfs node based extended attributes can be read now

Change-Id: I2d2915029435e7722cf463b1e2b5579b361dd592
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5606
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# b4b3f69f 25-Aug-2022 Mashijams <raghavself28@gmail.com>

xfs: extended attributes necessary hooks and shortform attributes support

- Implemented all necessary hooks for extended attributes in kernel_interface.cpp

- Implemented an abstract class attribute which will act as an interface between all forms of extended attributes in xfs

- An attempt to read shortform extended attributes

Change-Id: Icff9329b790f9fcfc0b078f61059795af9d9e486
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5570
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# b65cc53f 13-Aug-2022 Mashijams <raghavself28@gmail.com>

xfs: fixing bugs, Enable Werror

Fixed bug on reading files inside Haiku using CAT command on shell

Fixed bug on reading small directories inside Haiku

Node directories can now be read fine, which fixes #17839

LongBlock verification is now through common VerifyHeader function

Change-Id: I1eb651bd084580c86d0facb919825e94488e43d2
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5546
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# c912a3f2 18-Jul-2022 Mashijams <raghavself28@gmail.com>

xfs: Node, B+Tree based directories and v5 files support

-Implemented node and B+Tree based directories support for xfs v5

-Implemented file read support for xfs v5

-Implemented common template function for all data headers check

This patch completes #17783 and #17703

Change-Id: Id4389168d07f31a97e8867e3cb3321b4523b13c0
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5483
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# acdb3654 04-Jul-2022 Mashijams <raghavself28@gmail.com>

xfs: V5 block and leaf directories

- Implemented V5 Block directory fields and virtual extent data header class to handle both V4 and V5 block directories.

- Implemented V5 leaf directory fields and virtual extent leaf header class to handle both V4 and V5 leaf directories.

- Implemented all checks for buffer headers.

Change-Id: I8f994d9ba792f40ba827cd5cee915b7b11796ce3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5432
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# 6c478b54 24-Jun-2022 Mashijams <raghavself28@gmail.com>

xfs: version 3 Inodes and shortform directory

- Implemented xfs v5 inodes (known as v3 inodes) and necessary metadata integrity checks

- Implemented correct data fork pointer which handles both xfs v4 and v5 directories

- We can now read inodes and shortform directories for both xfs versions completely fine

Change-Id: I8a75ec1dc663d567d3bf6db64be4a27b55d709b3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5396
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>


# 9c4a46b3 31-May-2022 Mashijams <raghavself28@gmail.com>

xfs : version 5 superblock, checksum header file

- Implemented version 5 superblock fields and necessary macros.

- Checksum functions are implemented which will be used for crc verification and crc updates.

- fssh_kernal_priv.h ROUNDDOWN macro definition is consistent with kernal.h definition.

Change-Id: I49b7c939bfd3ea1bffc85b3db42bc678dcce75cd
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5350
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>


# b666bf3f 28-Apr-2022 Mashijams <raghavself28@gmail.com>

xfs : Enabling -Werror and fixing all build issues that result

This patch will fix almost all warnings we have in xfs code.
There are some which I haven't fixed yet, I added comments on
part of code which is giving error and its type as well.

I tested all the changes on xfs_shell and everything is
working fine.

Change-Id: I1af1d09e7eab7f2c2397193bd5a584c5d40c424c
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5257
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 2cecdeed 13-Apr-2022 Mashijams <raghavself28@gmail.com>

xfs : fix build with trace enabled, improve error checks

- Remove referencing an undeclared identifier

- Instead of an assert, just log an error for XFS V5 filesystems
and don't try to mount them

Change-Id: I67303aff89b81a28b7333569fea8113b6020dc54
Reviewed-on: https://review.haiku-os.org/c/haiku/+/5204
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# bd76cde0 23-Aug-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Implemented reading of B+Tree based files

This patch adds the functionality to read B+Trees based files.
It shares similarity with extent based file reading functionality. Just
the way the extents are read is different.

Change-Id: I9b7ebe20171a8860fdc35024f7018540248aed61
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3170
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 68c3f45d 17-Aug-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Attempt at reading extent based files

There are 2 issues right now. One is that I have to give cat command the
entire file size for it to print the entire file. The second issue is
that I am getting segmentation fault for some reason, and it doesn't
even have to do with xfs_read().

For more info: https://review.haiku-os.org/c/haiku/+/3154

Change-Id: I8e3acd658730ed2339dabbd671820c409332f296
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3154
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 4a2870fc 16-Aug-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Check Permissions

Implemented the xfs_access hook and we now check for permissions where
required.

Change-Id: Idaa71f300e0a73951d13073b66cb9ff37dbfa3ec
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3151
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 8897bed7 01-Aug-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Fixes and refactoring some parts

Found some bugs while testing different possible cases of Extent based
directories (1 extentmap case). Also did some refactoring.

Change-Id: Icb3b6e21de100c1bee93779c419bb2e86c694ae6
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3118
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# bd0708fd 12-Jul-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Attempt at reading Leaf Directories

We can read leaf directories now but I've only checked for a single
block working right now. I might make a few more changes in an upcoming
patch.

Change-Id: I325de8a6fad4ef9298e7810256cba47a87c45187
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3027
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# fc87b4a2 05-Jul-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Read Block directories

Block directories can now be read.
Change-Id: I9aa898638e6ac39cb903f2dd58cd184785e1a06b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2992
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 9593c05a 02-Jul-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: An attempt to read block directories

Map entries can be read, most structures are in place. Next is to
actually work with the directory block.

Change-Id: I700ee2e003bdef97838b1f06a95e53a5e4293658
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2981
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# a060fa96 25-Jun-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Read Short Form Directories

We can now read short form directories.
Change-Id: I23eb6ef52e8bb07643213e603ed0185f536c649f
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2952
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 7e1b5cf8 13-Jun-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: An attempt at reading shortform dir

This patch gets read_dir, lookup and few others to work. Entries cannot
be listed yet except the root.

Change-Id: Ic4b7b61a794a1b75849e45777a383b3315b15aa8
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2915
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# e3e93916 01-Jun-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: get_vnode and read_stat hook

This patch aimed at implementing the get_vnode and read_stat hook.
read_stat seems to work well, get_vnode can be checked after working on
dir.

Change-Id: I487915b7e8f6ee6f97349b0c638676d5389cd2df
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2859
Reviewed-by: Chế Vũ Gia Hy <cvghy116@gmail.com>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 406d14d4 18-May-2020 CruxBox <shubhambhagat111@yahoo.com>

xfs: Reading Inodes

This patch successfully reads inodes. There are also some style fixes.
The inodes aren't published and some useful hooks are yet to implement.

Change-Id: I73e6c68f1c2177871fbd0b241a67826aea1b17be
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2738
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>