1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 11:34:59 +00:00

Kernel: Refactor storage stack with u64 as file operations offset

This commit is contained in:
Jean-Baptiste Boric 2021-03-17 13:18:51 +01:00 committed by Andreas Kling
parent 999c57ef2d
commit b05b4d4b24
43 changed files with 83 additions and 83 deletions

View file

@ -46,7 +46,7 @@ InodeFile::~InodeFile()
{
}
KResultOr<size_t> InodeFile::read(FileDescription& description, size_t offset, UserOrKernelBuffer& buffer, size_t count)
KResultOr<size_t> InodeFile::read(FileDescription& description, u64 offset, UserOrKernelBuffer& buffer, size_t count)
{
if (Checked<off_t>::addition_would_overflow(offset, count))
return EOVERFLOW;
@ -61,7 +61,7 @@ KResultOr<size_t> InodeFile::read(FileDescription& description, size_t offset, U
return nread;
}
KResultOr<size_t> InodeFile::write(FileDescription& description, size_t offset, const UserOrKernelBuffer& data, size_t count)
KResultOr<size_t> InodeFile::write(FileDescription& description, u64 offset, const UserOrKernelBuffer& data, size_t count)
{
if (Checked<off_t>::addition_would_overflow(offset, count))
return EOVERFLOW;