All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/15] Enable Memory Bandwidth Allocation in Xen
@ 2017-08-24  1:14 Yi Sun
  2017-08-24  1:14 ` [PATCH v2 01/15] docs: create Memory Bandwidth Allocation (MBA) feature document Yi Sun
                   ` (14 more replies)
  0 siblings, 15 replies; 64+ messages in thread
From: Yi Sun @ 2017-08-24  1:14 UTC (permalink / raw)
  To: xen-devel
  Cc: kevin.tian, wei.liu2, andrew.cooper3, dario.faggioli,
	ian.jackson, Yi Sun, julien.grall, mengxu, jbeulich, chao.p.peng,
	roger.pau

Hi, all,

We plan to bring a new PSR (Platform Shared Resource) feature called
Intel Memory Bandwidth Allocation (MBA) to Xen.

Besides the MBA enabling, we change some interfaces to make them more
general but not only for CAT.

Any comments are welcome!

You can find this patch set at:
https://github.com/yisun-git/xen_mba mba_v2-2

---
Acked and Reviewed list before V2:

a - Acked-by
r - Reviewed-by

  ar patch 2  - Rename PSR sysctl/domctl interfaces and xsm policy to make them be general
  r  patch 3  - x86: rename 'cbm_type' to 'psr_val_type' to make it general
  ar patch 12 - tools: rename 'xc_psr_cat_type' to 'xc_psr_val_type'
  a  patch 13 - tools: implement new generic get value interface and MBA get value command
  a  patch 15 - docs: add MBA description in docs

---
V2 change list:

Patch 1:
    - declare 'HW' in Terminology.
      (suggested by Chao Peng)
    - replace 'COS ID of VCPU' to 'COS ID of domain'.
      (suggested by Chao Peng)
    - replace 'COS register' to 'Thrtl MSR'.
      (suggested by Chao Peng)
    - add description for 'psr-mba-show' to state that the decimal value is
      shown for linear mode but hexadecimal value is shown for non-linear mode.
      (suggested by Chao Peng)
    - remove content in 'Areas for improvement'.
      (suggested by Chao Peng)
    - use '<>' to specify mandatory argument to a command.
      (suggested by Wei Liu)
Patch3:
    - replace 'PSR_VAL_TYPE_{L3, L2}' to 'PSR_VAL_TYPE_{L3, L2}_CBM'.
      (suggested by Chao Peng)
Patch 4:
    - modify commit message to replace 'cos register' to 'thrtl register' to
      make it accurate.
      (suggested by Chao Peng)
    - restore the place of the sentence to assign value to 'feat->cbm_len'
      because the MBA init flow is splitted out as a separate function in v1.
      (suggested by Chao Peng)
    - add comment to explain what the MBA thrtl defaul value '0' stands for.
      (suggested by Chao Peng)
    - check 'thrtl_max' under linear mode. It could not be euqal or larger than
      100.
      (suggested by Chao Peng)
Patch 5:
    - use 'XEN_SYSCTL_PSR_MBA_LINEAR' to set MBA feature HW info.
      (suggested by Chao Peng)
Patch 7:
    - remove linear mode 'thrtl_max' check in 'mba_check_thrtl' because it has
      been checked in 'mba_init_feature'.
      (suggested by Chao Peng)
    - for non-linear mode, check if '*thrtl' is not 0 in 'mba_check_thrtl'. If
      it is 0, we do not need to change it.
      (suggested by Chao Peng)
    - move comments to explain changes of 'cos_write_info' from psr.c to commit
      message.
      (suggested by Chao Peng)
Patch 8:
    - remove '_INFO' in 'libxl_psr_feat_type' and make corresponding
      changes in 'libxl_psr_hw_info'.
      (suggested by Chao Peng)
Patch 9:
    - split this patch out from a big patch in v1.
      (suggested by Wei Liu)
    - change 'CAT_INFO' and 'MBA_INFO' to 'CAT' and 'MBA'.
      (suggested by Chao Peng)
Patch 10:
    - split this patch out from a big patch in v1.
      (suggested by Wei Liu)
    - change 'CAT_INFO'/'MBA_INFO' to 'CAT' and 'MBA. Also the libxl structure
      name 'cat_info'/'mba_info' is changed to 'cat'/'mba'.
      (suggested by Chao Peng)
    - call 'libxl_psr_hw_info_list_free' in 'libxl_psr_cat_get_info' to free
      allocated resources.
      (suggested by Chao Peng)
Patch 11:
    - split out this patch from a big patch in v1.
      (suggested by Wei Liu)
    - change 'MBA_INFO' to 'MBA'. Also, change 'mba_info' to 'mba'.
      (suggested by Chao Peng)
Patch 13:
    - change 'CAT_INFO'/'MBA_INFO' to 'CAT'/'MBA'. The related structure names
      are changed too.
      (suggested by Chao Peng)
Patch 15:
    - state the value type shown by 'psr-mba-show'. For linear mode,
      it shows decimal value. For non-linear mode, it shows hexadecimal
      value.
      (suggested by Chao Peng)

Yi Sun (15):
  docs: create Memory Bandwidth Allocation (MBA) feature document
  Rename PSR sysctl/domctl interfaces and xsm policy to make them be
    general
  x86: rename 'cbm_type' to 'psr_val_type' to make it general
  x86: implement data structure and CPU init flow for MBA
  x86: implement get hw info flow for MBA
  x86: implement get value interface for MBA
  x86: implement set value flow for MBA
  tools: create general interfaces to support psr allocation features
  tools: implement the new libxc get hw info interface
  tools: implement the new libxl get hw info interface
  tools: implement the new xl get hw info interface
  tools: rename 'xc_psr_cat_type' to 'xc_psr_val_type'
  tools: implement new generic get value interface and MBA get value
    command
  tools: implement new generic set value interface and MBA set value
    command
  docs: add MBA description in docs

 docs/features/intel_psr_mba.pandoc  | 256 +++++++++++++++++++++++++
 docs/man/xl.pod.1.in                |  34 ++++
 docs/misc/xl-psr.markdown           |  63 +++++++
 tools/flask/policy/modules/dom0.te  |   4 +-
 tools/libxc/include/xenctrl.h       |  47 +++--
 tools/libxc/xc_psr.c                |  88 ++++++---
 tools/libxl/libxl.h                 |  35 +++-
 tools/libxl/libxl_psr.c             | 229 ++++++++++++++++++----
 tools/libxl/libxl_types.idl         |  22 +++
 tools/xl/xl.h                       |   2 +
 tools/xl/xl_cmdtable.c              |  12 ++
 tools/xl/xl_psr.c                   | 279 +++++++++++++++++++++------
 xen/arch/x86/domctl.c               |  65 ++++---
 xen/arch/x86/psr.c                  | 366 +++++++++++++++++++++++++++---------
 xen/arch/x86/sysctl.c               |  47 +++--
 xen/include/asm-x86/msr-index.h     |   1 +
 xen/include/asm-x86/psr.h           |  22 ++-
 xen/include/public/domctl.h         |  14 +-
 xen/include/public/sysctl.h         |  20 +-
 xen/xsm/flask/hooks.c               |   8 +-
 xen/xsm/flask/policy/access_vectors |   8 +-
 21 files changed, 1318 insertions(+), 304 deletions(-)
 create mode 100644 docs/features/intel_psr_mba.pandoc

-- 
1.9.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

^ permalink raw reply	[flat|nested] 64+ messages in thread

end of thread, other threads:[~2017-09-04  8:43 UTC | newest]

Thread overview: 64+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-24  1:14 [PATCH v2 00/15] Enable Memory Bandwidth Allocation in Xen Yi Sun
2017-08-24  1:14 ` [PATCH v2 01/15] docs: create Memory Bandwidth Allocation (MBA) feature document Yi Sun
2017-08-29 11:46   ` Roger Pau Monné
2017-08-30  5:20     ` Yi Sun
2017-08-30  7:42       ` Roger Pau Monn�
2017-08-24  1:14 ` [PATCH v2 02/15] Rename PSR sysctl/domctl interfaces and xsm policy to make them be general Yi Sun
2017-08-29 12:00   ` Roger Pau Monné
2017-08-30  5:23     ` Yi Sun
2017-08-30  7:47       ` Roger Pau Monn�
2017-08-30  8:14         ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 03/15] x86: rename 'cbm_type' to 'psr_val_type' to make it general Yi Sun
2017-08-29 12:15   ` Roger Pau Monné
2017-08-30  5:47     ` Yi Sun
2017-08-30  7:51       ` Roger Pau Monn�
2017-08-30  8:14         ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 04/15] x86: implement data structure and CPU init flow for MBA Yi Sun
2017-08-29 13:44   ` Roger Pau Monné
2017-08-29 13:58     ` Jan Beulich
2017-08-30  6:07       ` Yi Sun
2017-08-30  5:31     ` Yi Sun
2017-08-30  7:55       ` Roger Pau Monn�
2017-08-30  8:19         ` Yi Sun
2017-08-30  8:45         ` Jan Beulich
2017-08-24  1:14 ` [PATCH v2 05/15] x86: implement get hw info " Yi Sun
2017-08-29 15:01   ` Roger Pau Monné
2017-08-30  5:33     ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 06/15] x86: implement get value interface " Yi Sun
2017-08-29 15:04   ` Roger Pau Monné
2017-08-24  1:14 ` [PATCH v2 07/15] x86: implement set value flow " Yi Sun
2017-08-30  8:31   ` Roger Pau Monné
2017-08-31  2:20     ` Yi Sun
2017-08-31  8:30       ` Roger Pau Monn�
2017-08-31  9:13         ` Yi Sun
2017-08-31  9:30           ` Roger Pau Monn�
2017-08-31 10:10             ` Yi Sun
2017-08-31 10:19               ` Roger Pau Monn�
2017-08-24  1:14 ` [PATCH v2 08/15] tools: create general interfaces to support psr allocation features Yi Sun
2017-08-30  8:42   ` Roger Pau Monné
2017-08-31  2:38     ` Yi Sun
2017-08-31  8:37       ` Roger Pau Monn�
2017-09-04  2:09         ` Yi Sun
2017-09-04  8:43           ` Wei Liu
2017-08-24  1:14 ` [PATCH v2 09/15] tools: implement the new libxc get hw info interface Yi Sun
2017-08-30  8:58   ` Roger Pau Monné
2017-08-31  3:05     ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 10/15] tools: implement the new libxl " Yi Sun
2017-08-30  9:15   ` Roger Pau Monné
2017-08-31  3:16     ` Yi Sun
2017-08-31  8:40       ` Roger Pau Monn�
2017-08-31  9:19         ` Yi Sun
2017-08-31  9:32           ` Roger Pau Monn�
2017-08-31 10:11             ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 11/15] tools: implement the new xl " Yi Sun
2017-08-30  9:23   ` Roger Pau Monné
2017-08-31  5:57     ` Yi Sun
2017-08-31  8:43       ` Roger Pau Monn�
2017-08-31  9:24         ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 12/15] tools: rename 'xc_psr_cat_type' to 'xc_psr_val_type' Yi Sun
2017-08-30  9:24   ` Roger Pau Monné
2017-08-24  1:14 ` [PATCH v2 13/15] tools: implement new generic get value interface and MBA get value command Yi Sun
2017-08-24  1:14 ` [PATCH v2 14/15] tools: implement new generic set value interface and MBA set " Yi Sun
2017-08-30  9:47   ` Roger Pau Monné
2017-08-31  5:58     ` Yi Sun
2017-08-24  1:14 ` [PATCH v2 15/15] docs: add MBA description in docs Yi Sun

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.