1.1 --- a/libexec/include/exec/external_pager.h Thu Feb 23 23:49:26 2023 +0100
1.2 +++ b/libexec/include/exec/external_pager.h Sat Feb 25 18:10:13 2023 +0100
1.3 @@ -22,6 +22,7 @@
1.4 #pragma once
1.5
1.6 #include <exec/pager.h>
1.7 +#include <fsserver/notification.h>
1.8
1.9 #include "notifier_interface.h"
1.10 #include "parent_pager_object_interface.h"
1.11 @@ -30,10 +31,11 @@
1.12
1.13 /* A simple system pager also acting as a region mapper. */
1.14
1.15 -class ExternalPager : public ExecPager, public ParentPagerObject
1.16 +class ExternalPager : public ExecPager, public ParentPagerObject,
1.17 + public NotificationSupport
1.18 {
1.19 protected:
1.20 - Notifier *_notifier = NULL;
1.21 + unsigned int _endpoint;
1.22
1.23 public:
1.24 explicit ExternalPager(address_t start = 0, address_t end = 0);
1.25 @@ -57,8 +59,11 @@
1.26
1.27 /* Notification methods. */
1.28
1.29 - virtual void set_notifier(Notifier *notifier)
1.30 - { _notifier = notifier; }
1.31 + virtual long subscribe(l4_cap_idx_t notifier, notify_flags_t flags)
1.32 + { return NotificationSupport::subscribe(notifier, flags, this, &_endpoint); }
1.33 +
1.34 + virtual long unsubscribe()
1.35 + { NotificationSupport::unsubscribe(_endpoint, this); return L4_EOK; }
1.36 };
1.37
1.38 /* vim: tabstop=2 expandtab shiftwidth=2