diff --git a/Kernel/FileSystem/ProcFS.cpp b/Kernel/FileSystem/ProcFS.cpp index 9e5fe17c37..2ed82dffd8 100644 --- a/Kernel/FileSystem/ProcFS.cpp +++ b/Kernel/FileSystem/ProcFS.cpp @@ -795,7 +795,6 @@ static bool procfs$all(InodeIdentifier, KBufferBuilder& builder) thread_object.add("state", thread.state_string()); thread_object.add("cpu", thread.cpu()); thread_object.add("priority", thread.priority()); - thread_object.add("effective_priority", thread.effective_priority()); thread_object.add("syscall_count", thread.syscall_count()); thread_object.add("inode_faults", thread.inode_faults()); thread_object.add("zero_faults", thread.zero_faults()); diff --git a/Kernel/Scheduler.cpp b/Kernel/Scheduler.cpp index f4823f443c..54576f40a0 100644 --- a/Kernel/Scheduler.cpp +++ b/Kernel/Scheduler.cpp @@ -161,7 +161,7 @@ void Scheduler::queue_runnable_thread(Thread& thread) ASSERT(g_scheduler_lock.own_lock()); if (&thread == Processor::current().idle_thread()) return; - auto priority = thread_priority_to_priority_index(thread.effective_priority()); + auto priority = thread_priority_to_priority_index(thread.priority()); ScopedSpinLock lock(g_ready_queues_lock); ASSERT(thread.m_runnable_priority < 0); @@ -260,8 +260,7 @@ bool Scheduler::pick_next() dbgln("Scheduler[{}j]: Runnables:", Processor::id()); Scheduler::for_each_runnable([](Thread& thread) -> IterationDecision { - dbgln(" {:3}/{:2} {:12} @ {:04x}:{:08x}", - thread.effective_priority(), + dbgln(" {:2} {:12} @ {:04x}:{:08x}", thread.priority(), thread.state_string(), thread.tss().cs, diff --git a/Kernel/Thread.h b/Kernel/Thread.h index 11605fe6b8..1cd6e182ba 100644 --- a/Kernel/Thread.h +++ b/Kernel/Thread.h @@ -105,8 +105,6 @@ public: void set_priority(u32 p) { m_priority = p; } u32 priority() const { return m_priority; } - u32 effective_priority() const { return m_priority; } - void detach() { ScopedSpinLock lock(m_lock); diff --git a/Userland/Applications/SystemMonitor/ProcessModel.cpp b/Userland/Applications/SystemMonitor/ProcessModel.cpp index 2c2c9a2d5c..d8eb125efe 100644 --- a/Userland/Applications/SystemMonitor/ProcessModel.cpp +++ b/Userland/Applications/SystemMonitor/ProcessModel.cpp @@ -102,8 +102,6 @@ String ProcessModel::column_name(int column) const return "User"; case Column::Priority: return "Pr"; - case Column::EffectivePriority: - return "EPr"; case Column::Virtual: return "Virtual"; case Column::Physical: @@ -175,7 +173,6 @@ GUI::Variant ProcessModel::data(const GUI::ModelIndex& index, GUI::ModelRole rol case Column::PGID: case Column::SID: case Column::Priority: - case Column::EffectivePriority: case Column::Virtual: case Column::Physical: case Column::DirtyPrivate: @@ -223,8 +220,6 @@ GUI::Variant ProcessModel::data(const GUI::ModelIndex& index, GUI::ModelRole rol return thread.current_state.user; case Column::Priority: return thread.current_state.priority; - case Column::EffectivePriority: - return thread.current_state.effective_priority; case Column::Virtual: return (int)thread.current_state.amount_virtual; case Column::Physical: @@ -296,8 +291,6 @@ GUI::Variant ProcessModel::data(const GUI::ModelIndex& index, GUI::ModelRole rol return thread.current_state.user; case Column::Priority: return thread.current_state.priority; - case Column::EffectivePriority: - return thread.current_state.effective_priority; case Column::Virtual: return pretty_byte_size(thread.current_state.amount_virtual); case Column::Physical: @@ -398,7 +391,6 @@ void ProcessModel::update() state.cpu = thread.cpu; state.cpu_percent = 0; state.priority = thread.priority; - state.effective_priority = thread.effective_priority; state.state = thread.state; sum_ticks_scheduled += thread.ticks_user + thread.ticks_kernel; sum_ticks_scheduled_kernel += thread.ticks_kernel; diff --git a/Userland/Applications/SystemMonitor/ProcessModel.h b/Userland/Applications/SystemMonitor/ProcessModel.h index 11f39cac76..a7db7aebca 100644 --- a/Userland/Applications/SystemMonitor/ProcessModel.h +++ b/Userland/Applications/SystemMonitor/ProcessModel.h @@ -53,7 +53,6 @@ public: Processor, State, Priority, - EffectivePriority, User, PID, TID, @@ -127,7 +126,6 @@ private: String veil; u32 cpu; u32 priority; - u32 effective_priority; size_t amount_virtual; size_t amount_resident; size_t amount_dirty_private; diff --git a/Userland/Libraries/LibCore/ProcessStatisticsReader.cpp b/Userland/Libraries/LibCore/ProcessStatisticsReader.cpp index 566053d3af..69a723eab2 100644 --- a/Userland/Libraries/LibCore/ProcessStatisticsReader.cpp +++ b/Userland/Libraries/LibCore/ProcessStatisticsReader.cpp @@ -97,7 +97,6 @@ Optional> ProcessStatisticsReader::get_a thread.ticks_kernel = thread_object.get("ticks_kernel").to_u32(); thread.cpu = thread_object.get("cpu").to_u32(); thread.priority = thread_object.get("priority").to_u32(); - thread.effective_priority = thread_object.get("effective_priority").to_u32(); thread.syscall_count = thread_object.get("syscall_count").to_u32(); thread.inode_faults = thread_object.get("inode_faults").to_u32(); thread.zero_faults = thread_object.get("zero_faults").to_u32(); diff --git a/Userland/Libraries/LibCore/ProcessStatisticsReader.h b/Userland/Libraries/LibCore/ProcessStatisticsReader.h index b6e506cd9d..9c574229c7 100644 --- a/Userland/Libraries/LibCore/ProcessStatisticsReader.h +++ b/Userland/Libraries/LibCore/ProcessStatisticsReader.h @@ -51,7 +51,6 @@ struct ThreadStatistics { String state; u32 cpu; u32 priority; - u32 effective_priority; String name; }; diff --git a/Userland/Libraries/LibWeb/DOM/Node.cpp b/Userland/Libraries/LibWeb/DOM/Node.cpp index ea26fbd761..ce2d864514 100644 --- a/Userland/Libraries/LibWeb/DOM/Node.cpp +++ b/Userland/Libraries/LibWeb/DOM/Node.cpp @@ -183,6 +183,12 @@ RefPtr Node::append_child(NonnullRefPtr node, bool notify) return node; } +RefPtr Node::remove_child(NonnullRefPtr node) +{ + TreeNode::remove_child(node); + return node; +} + RefPtr Node::insert_before(NonnullRefPtr node, RefPtr child, bool notify) { if (!child) diff --git a/Userland/Libraries/LibWeb/DOM/Node.h b/Userland/Libraries/LibWeb/DOM/Node.h index d29f0a471f..a62c220fe1 100644 --- a/Userland/Libraries/LibWeb/DOM/Node.h +++ b/Userland/Libraries/LibWeb/DOM/Node.h @@ -82,6 +82,7 @@ public: RefPtr append_child(NonnullRefPtr, bool notify = true); RefPtr insert_before(NonnullRefPtr node, RefPtr child, bool notify = true); + RefPtr remove_child(NonnullRefPtr); virtual RefPtr create_layout_node(); diff --git a/Userland/Libraries/LibWeb/DOM/Node.idl b/Userland/Libraries/LibWeb/DOM/Node.idl index 2ba27688e6..3165b3131d 100644 --- a/Userland/Libraries/LibWeb/DOM/Node.idl +++ b/Userland/Libraries/LibWeb/DOM/Node.idl @@ -11,6 +11,6 @@ interface Node : EventTarget { Node appendChild(Node node); Node insertBefore(Node node, Node? child); - + Node removeChild(Node child); };