mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:17:35 +00:00
Kernel/SysFS: Expose file size of ACPI tables in /sys/firmware/acpi
It costs us nothing, and some utilities (such as the known file utility) rely on the exposed file size (after doing lstat on it), to show anything useful besides saying the file is "empty".
This commit is contained in:
parent
11a5f2c508
commit
462802ef0c
1 changed files with 2 additions and 0 deletions
|
@ -37,6 +37,8 @@ public:
|
|||
virtual StringView name() const override { return m_table_name->view(); }
|
||||
virtual ErrorOr<size_t> read_bytes(off_t, size_t, UserOrKernelBuffer&, OpenFileDescription*) const override;
|
||||
|
||||
virtual size_t size() const override final { return m_length; }
|
||||
|
||||
protected:
|
||||
ErrorOr<NonnullOwnPtr<KBuffer>> try_to_generate_buffer() const;
|
||||
ACPISysFSComponent(NonnullOwnPtr<KString> table_name, PhysicalAddress, size_t table_size);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue