2019-04-28 14:53:50 +02:00
|
|
|
#include <Kernel/File.h>
|
2019-06-07 09:36:51 +02:00
|
|
|
#include <Kernel/FileSystem/FileDescription.h>
|
2019-04-28 14:53:50 +02:00
|
|
|
|
|
|
|
File::File()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
File::~File()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2019-06-21 18:37:47 +02:00
|
|
|
KResultOr<NonnullRefPtr<FileDescription>> File::open(int options)
|
2019-04-28 14:53:50 +02:00
|
|
|
{
|
|
|
|
UNUSED_PARAM(options);
|
2019-06-07 09:36:51 +02:00
|
|
|
return FileDescription::create(this);
|
2019-04-28 14:53:50 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
void File::close()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2019-06-07 09:36:51 +02:00
|
|
|
int File::ioctl(FileDescription&, unsigned, unsigned)
|
2019-04-28 14:53:50 +02:00
|
|
|
{
|
|
|
|
return -ENOTTY;
|
|
|
|
}
|
|
|
|
|
2019-06-07 12:56:50 +02:00
|
|
|
KResultOr<Region*> File::mmap(Process&, FileDescription&, VirtualAddress, size_t, size_t, int)
|
2019-04-28 14:53:50 +02:00
|
|
|
{
|
|
|
|
return KResult(-ENODEV);
|
|
|
|
}
|