lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180622111839.10071-1-osalvador@techadventures.net>
Date:   Fri, 22 Jun 2018 13:18:35 +0200
From:   osalvador@...hadventures.net
To:     akpm@...ux-foundation.org
Cc:     mhocko@...e.com, vbabka@...e.cz, pasha.tatashin@...cle.com,
        Jonathan.Cameron@...wei.com, arbab@...ux.vnet.ibm.com,
        linux-mm@...ck.org, linux-kernel@...r.kernel.org,
        Oscar Salvador <osalvador@...e.de>
Subject: [PATCH v2 0/4] Small cleanup for memoryhotplug

From: Oscar Salvador <osalvador@...e.de>

Hi,

I this is a small cleanup for the memhotplug's code.
A lot more could be done, but it is better to start somewhere.
I tried to unify/remove duplicated code.

The following is what this patchset does:

1) add_memory_resource() has code to allocate a node in case it was offline.
   Since try_online_node has some code for that as well, I just made add_memory_resource() to
   use that so we can remove duplicated code..
   This is better explained in patch 1/4.

2) register_mem_sect_under_node() will be called only from link_mem_sections()

3) Make register_mem_sect_under_node() a callback of walk_memory_range()

4) Drop unnecessary checks from register_mem_sect_under_node()

I have done some tests and I could not see anything broken because of
this patchset.

Signed-off-by: Oscar Salvador <osalvador@...e.de>
Tested-by: Jonathan Cameron <Jonathan.Cameron@...wei.com>

Changes since v1:
- Address issues/suggestions in the provided feedback (Pavel Tatashin)
- Rebased

Oscar Salvador (4):
  mm/memory_hotplug: Make add_memory_resource use __try_online_node
  mm/memory_hotplug: Call register_mem_sect_under_node
  mm/memory_hotplug: Make register_mem_sect_under_node a cb of
    walk_memory_range
  mm/memory_hotplug: Drop unnecessary checks from
    register_mem_sect_under_node

 drivers/base/memory.c |  2 --
 drivers/base/node.c   | 49 ++++----------------------
 include/linux/node.h  | 12 ++++---
 mm/memory_hotplug.c   | 96 +++++++++++++++++++++++++--------------------------
 4 files changed, 60 insertions(+), 99 deletions(-)

-- 
2.13.6

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ