Re: [PATCH] hwmon (ina3221) Add single-shot mode support

2018-11-16 Thread Nicolin Chen
Hello Guenter, On Wed, Nov 14, 2018 at 09:23:30AM -0800, Guenter Roeck wrote: > > An alternative way (without the sysfs node), after looking at > > other hwmon code, could be to have a timed polling thread and > > read data using an update_interval value from ABI. This might > > turn out to be mor

[PATCH v3 7/7] cgroup: document cgroup v2 freezer interface

2018-11-16 Thread Roman Gushchin
Describe cgroup v2 freezer interface in the cgroup v2 admin guide. Signed-off-by: Roman Gushchin Cc: Tejun Heo Cc: linux-doc@vger.kernel.org Cc: kernel-t...@fb.com --- Documentation/admin-guide/cgroup-v2.rst | 26 + 1 file changed, 26 insertions(+) diff --git a/Document

[PATCH 2/2] Documentation: intel_pstate: Clarify coordination of P-State limits

2018-11-16 Thread Srinivas Pandruvada
Explain influence of per-core P-states and hyper threading on the effective performance. Signed-off-by: Srinivas Pandruvada --- Documentation/admin-guide/pm/intel_pstate.rst | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Documentation/admin-guide/pm/intel_pstate.rs

[PATCH 1/2] cpufreq: intel_pstate: Force HWP min perf before offline

2018-11-16 Thread Srinivas Pandruvada
Force HWP Request MAX = HWP Request MIN = HWP Capability MIN and EPP to 0xFF. In this way the performance limits on the offlined CPU will not influence performance limits on its sibling CPU, which is still online. If the sibling CPU is calling for higher performance, it will impact the max core pe

Re: [PATCH v8 09/13] arch/resctrl: Update the RESCTRL config parameter

2018-11-16 Thread Randy Dunlap
On 11/16/18 12:54 PM, Moger, Babu wrote: > CONFIG_RESCTRL will be used for both Intel and AMD to enable > Resource Control feature. Update the details and condition accordingly. > > Signed-off-by: Babu Moger > --- > arch/x86/Kconfig | 19 ++- > 1 file changed, 14 insertions(+), 5

[PATCH v8 05/13] arch/resctrl: Rename config parameter INTEL_RDT to RESCTRL

2018-11-16 Thread Moger, Babu
Now Resource control feature is supported by both Intel and AMD. Rename the INTEL_RDT to vendor neutral RESCTRL. Signed-off-by: Babu Moger --- arch/x86/Kconfig | 4 ++-- arch/x86/include/asm/resctrl_sched.h | 4 ++-- arch/x86/kernel/cpu/Makefile | 4 ++-- include/linu

[PATCH v8 04/13] arch/resctrl: Bring all the macros to resctrl.h

2018-11-16 Thread Moger, Babu
Bring all the macros to resctrl.h and rename for consistency. Signed-off-by: Babu Moger --- arch/x86/kernel/cpu/resctrl.c | 3 --- arch/x86/kernel/cpu/resctrl.h | 5 + arch/x86/kernel/cpu/resctrl_monitor.c | 7 ++- 3 files changed, 7 insertions(+), 8 deletions(-) diff --

[PATCH v8 12/13] Documentation: Rename and update intel_rdt_ui.txt to resctrl_ui.txt

2018-11-16 Thread Moger, Babu
Rename intel_rdt_ui.txt to generic resctrl_ui.txt and update the documentation for AMD. Signed-off-by: Babu Moger --- Documentation/x86/{intel_rdt_ui.txt => resctrl_ui.txt} | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) rename Documentation/x86/{intel_rdt_ui.txt => resctrl_ui.tx

[PATCH v8 02/13] arch/resctrl: Rename the RDT functions and definitions

2018-11-16 Thread Moger, Babu
As AMD is starting to support RDT(or QOS) features, rename the RDT functions and definitions to more generic names. Replace intel_rdt to resctrl where applicable. Signed-off-by: Babu Moger Reviewed-by: Borislav Petkov --- arch/x86/include/asm/resctrl_sched.h | 24 ar

[PATCH v8 10/13] arch/resctrl: Add AMD feature bit X86_FEATURE_MBA in cpuid bits array

2018-11-16 Thread Moger, Babu
From: Sherry Hurwitz The feature bit X86_FEATURE_MBA is detected via CPUID leaf 0x8008 EBX Bit 06. This bit indicates the support of AMD's MBA feature. This feature is supported by both Intel and AMD. But they are detected in different CPUID leaves. Signed-off-by: Sherry Hurwitz Signed-off

[PATCH v8 03/13] arch/resctrl: Re-arrange RDT init code

2018-11-16 Thread Moger, Babu
Separate the call sequence for rdt_quirks and MBA feature. This is in preparation to handle vendor differences in these call sequences. Signed-off-by: Babu Moger --- arch/x86/kernel/cpu/resctrl.c | 27 +-- 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/arc

[PATCH v8 11/13] arch/resctrl: Introduce QOS feature for AMD

2018-11-16 Thread Moger, Babu
Enables QOS feature on AMD. Following QoS sub-features are supported in AMD if the underlying hardware supports it. - L3 Cache allocation enforcement - L3 Cache occupancy monitoring - L3 Code-Data Prioritization support - Memory Bandwidth Enforcement(Allocation) The specification for this feat

[PATCH v8 06/13] arch/resctrl: Initialize the resource functions that are different

2018-11-16 Thread Moger, Babu
Initialize the resource functions that are different between the vendors. Some features are initialized differently between the vendors. Add _intel suffix to Intel specific functions. For example, MBA feature varies significantly between Intel and AMD. Separate the initialization of these resource

[PATCH v8 07/13] arch/resctrl: Bring cbm_validate function into the resource structure

2018-11-16 Thread Moger, Babu
Idea is to bring all the functions that are different between the vendors into resource structure and initialize them dynamically. Add _intel suffix to Intel specific functions. Following function is implemented separately for each vendors. cbm_validate : Cache bitmask validate function. AMD allo

[PATCH v8 13/13] MAINTAINERS: Update the file and documentation names in arch/x86

2018-11-16 Thread Moger, Babu
Update the MAINTAINERS to reflect the changed file(and documentation) names in arch/x86/kernel/cpu. The file names have changed from intel_rdt* to resctrl*. Signed-off-by: Babu Moger --- MAINTAINERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINE

[PATCH v8 01/13] arch/resctrl: Start renaming the rdt files to more generic names

2018-11-16 Thread Moger, Babu
New generation of AMD processors start supporting RDT(or QOS) features. With more than one vendors supporting these features, it seems more appropriate to rename these files. Changed intel_rdt to resctrl where applicable. Signed-off-by: Babu Moger Reviewed-by: Borislav Petkov --- arch/x86/incl

[PATCH v8 08/13] arch/resctrl: Add vendor check for MBA software controller

2018-11-16 Thread Moger, Babu
MBA software controller support is available only on Intel. Suggested-by: Fenghua Yu Signed-off-by: Babu Moger --- arch/x86/kernel/cpu/resctrl_rdtgroup.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/arch/x86/kernel/cpu/resctrl_rdtgroup.c b/arch/x86/kernel/cpu/resctrl

[PATCH v8 09/13] arch/resctrl: Update the RESCTRL config parameter

2018-11-16 Thread Moger, Babu
CONFIG_RESCTRL will be used for both Intel and AMD to enable Resource Control feature. Update the details and condition accordingly. Signed-off-by: Babu Moger --- arch/x86/Kconfig | 19 ++- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/arch/x86/Kconfig b/arch/x86

[PATCH v8 00/13] arch/resctrl: AMD QoS support

2018-11-16 Thread Moger, Babu
This series adds support for AMD64 architectural extensions for Platform Quality of Service. These extensions are intended to provide for the monitoring of the usage of certain system resources by one or more processors and for the separate allocation and enforcement of limits on the use of certain

[PATCH v8 07/14] integrity: Select CONFIG_KEYS instead of depending on it

2018-11-16 Thread Thiago Jung Bauermann
This avoids a dependency cycle in soon-to-be-introduced CONFIG_IMA_APPRAISE_MODSIG: it will select CONFIG_MODULE_SIG_FORMAT which in turn selects CONFIG_KEYS. Kconfig then complains that CONFIG_INTEGRITY_SIGNATURE depends on CONFIG_KEYS. Signed-off-by: Thiago Jung Bauermann Signed-off-by: Mimi Zo

[PATCH v8 10/14] ima: Add modsig appraise_type option for module-style appended signatures

2018-11-16 Thread Thiago Jung Bauermann
Introduce the modsig keyword to the IMA policy syntax to specify that a given hook should expect the file to have the IMA signature appended to it. Here is how it can be used in a rule: appraise func=KEXEC_KERNEL_CHECK appraise_type=imasig|modsig With this rule, IMA will accept either a signature

[PATCH v8 12/14] ima: Add new "d-sig" template field

2018-11-16 Thread Thiago Jung Bauermann
Define new "d-sig" template field which holds the digest that is expected to match the one contained in the modsig. Suggested-by: Mimi Zohar Signed-off-by: Thiago Jung Bauermann --- Documentation/security/IMA-templates.rst | 5 security/integrity/ima/ima.h | 9 +++ secu

[PATCH v8 13/14] ima: Write modsig to the measurement list

2018-11-16 Thread Thiago Jung Bauermann
Add modsig support to the "sig" template field, allowing the the contents of the modsig to be included in the measurement list. Suggested-by: Mimi Zohar Signed-off-by: Thiago Jung Bauermann --- security/integrity/ima/ima.h | 7 +++ security/integrity/ima/ima_modsig.c | 1

[PATCH v8 11/14] ima: Implement support for module-style appended signatures

2018-11-16 Thread Thiago Jung Bauermann
Implement the appraise_type=imasig|modsig option, allowing IMA to read and verify modsig signatures. In case a file has both an xattr signature and an appended modsig, IMA will only use the appended signature if the key used by the xattr signature isn't present in the IMA keyring. Signed-off-by:

[PATCH v8 14/14] ima: Store the measurement again when appraising a modsig

2018-11-16 Thread Thiago Jung Bauermann
If the IMA template contains the 'sig' field, then the modsig should be added to the measurement list when the file is appraised, and that is what normally happens. But If a measurement rule caused a file containing a modsig to be measured before a different rule causes it to be appraised, the res

[PATCH v8 08/14] ima: Introduce is_signed()

2018-11-16 Thread Thiago Jung Bauermann
With the introduction of another IMA signature type (modsig), some places will need to check for both of them. It is cleaner to do that if there's a helper function to tell whether an xattr_value represents an IMA signature. Suggested-by: Mimi Zohar Signed-off-by: Thiago Jung Bauermann --- secu

[PATCH v8 09/14] ima: Export func_tokens

2018-11-16 Thread Thiago Jung Bauermann
ima_read_modsig() will need it so that it can show an error message. Signed-off-by: Thiago Jung Bauermann --- security/integrity/ima/ima.h| 2 ++ security/integrity/ima/ima_policy.c | 12 ++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/security/integrity/ima/

[PATCH v8 04/14] integrity: Introduce struct evm_xattr

2018-11-16 Thread Thiago Jung Bauermann
Even though struct evm_ima_xattr_data includes a fixed-size array to hold a SHA1 digest, most of the code ignores the array and uses the struct to mean "type indicator followed by data of unspecified size" and tracks the real size of what the struct represents in a separate length variable. The on

[PATCH v8 06/14] integrity: Introduce asymmetric_sig_has_known_key()

2018-11-16 Thread Thiago Jung Bauermann
IMA will only look for a modsig if the xattr sig references a key which is not in the expected kernel keyring. To that end, introduce asymmetric_sig_has_known_key(). The logic of extracting the key used in the xattr sig is factored out from asymmetric_verify() so that it can be used by the new fun

[PATCH v8 05/14] integrity: Introduce integrity_keyring_from_id()

2018-11-16 Thread Thiago Jung Bauermann
IMA will need to obtain the keyring used to verify file signatures so that it can verify the module-style signature appended to files. Signed-off-by: Thiago Jung Bauermann Signed-off-by: Mimi Zohar --- security/integrity/digsig.c| 28 +--- security/integrity/integrit

[PATCH v8 03/14] PKCS#7: Introduce pkcs7_get_digest()

2018-11-16 Thread Thiago Jung Bauermann
IMA will need to access the digest of the PKCS7 message (as calculated by the kernel) before the signature is verified, so introduce pkcs7_get_digest() for that purpose. Also, modify pkcs7_digest() to detect when the digest was already calculated so that it doesn't have to do redundant work. Verif

[PATCH v8 02/14] PKCS#7: Refactor verify_pkcs7_signature() and add pkcs7_get_message_sig()

2018-11-16 Thread Thiago Jung Bauermann
IMA will need to verify a PKCS#7 which has already been parsed. For this reason, factor out the code which does that from verify_pkcs7_signature() into a new function which takes a struct pkcs7_message instead of a data buffer. In addition, IMA will need to know the key that signed a given PKCS#7

[PATCH v8 01/14] MODSIGN: Export module signature definitions

2018-11-16 Thread Thiago Jung Bauermann
IMA will use the module_signature format for append signatures, so export the relevant definitions and factor out the code which verifies that the appended signature trailer is valid. Also, create a CONFIG_MODULE_SIG_FORMAT option so that IMA can select it and be able to use validate_module_sig()

[PATCH v8 00/14] Appended signatures support for IMA appraisal

2018-11-16 Thread Thiago Jung Bauermann
Hello, v8 is just a rebase on top of today's linux-integrity/next-integrity. There aren't any noteworthy changes since v7, which is why I'm keeping its description below: The main difference in v7 is the addition of the last patch, which ensures that there will always be a measurement entry conta

Re: [PATCH RFC 0/6] mm/kdump: allow to exclude pages that are logically offline

2018-11-16 Thread David Hildenbrand
On 14.11.18 22:16, David Hildenbrand wrote: > Right now, pages inflated as part of a balloon driver will be dumped > by dump tools like makedumpfile. While XEN is able to check in the > crash kernel whether a certain pfn is actuall backed by memory in the > hypervisor (see xen_oldmem_pfn_is_ram) an

Re: [PATCH 3/9] drm: replace "drm_dev_unref" function with "drm_dev_put"

2018-11-16 Thread Fernando
On Fri, Nov 16, 2018, at 11:15 AM, Lucas Stach wrote: > Am Donnerstag, den 15.11.2018, 23:16 +0100 schrieb Fernando Ramos: > > This patch unifies the naming of DRM functions for reference counting as > > requested on Documentation/gpu/todo.rst > > > > > Signed-off-by: Fernando Ramos > > --- > >  

Re: [PATCH v10 0/9] Add the I3C subsystem

2018-11-16 Thread Boris Brezillon
On Fri, 16 Nov 2018 12:31:42 + vitor wrote: > Hi Boris, > > > On 15/11/18 19:00, Boris Brezillon wrote: > > On Thu, 15 Nov 2018 18:03:47 + > > vitor wrote: > > > >> Hi Boris, > >> > >> > >> On 15/11/18 15:28, Boris Brezillon wrote: > >>> On Thu, 15 Nov 2018 16:01:37 +0100 > >>> Wol

Re: [PATCH v10 0/9] Add the I3C subsystem

2018-11-16 Thread Przemyslaw Gaj
Hi Vitor, On 11/16/18, 1:32 PM, "vitor" wrote: EXTERNAL MAIL Hi Boris, On 15/11/18 19:00, Boris Brezillon wrote: > On Thu, 15 Nov 2018 18:03:47 + > vitor wrote: > >> Hi Boris, >> >> >> On 15/11/18 15:28, Boris Brezillon wrote:

Re: [PATCH v10 0/9] Add the I3C subsystem

2018-11-16 Thread vitor
Hi Boris, On 15/11/18 19:00, Boris Brezillon wrote: On Thu, 15 Nov 2018 18:03:47 + vitor wrote: Hi Boris, On 15/11/18 15:28, Boris Brezillon wrote: On Thu, 15 Nov 2018 16:01:37 +0100 Wolfram Sang wrote: Hi Boris, What we could do though, is expose I3C devices that do not have

Re: [PATCH v17 00/23] Intel SGX1 support

2018-11-16 Thread Jarkko Sakkinen
For unknown reason this never reached any MLs (used the same command line for git send-email as usual). /Jarkko On Fri, Nov 16, 2018 at 03:38:08AM +0200, Jarkko Sakkinen wrote: > Intel(R) SGX is a set of CPU instructions that can be used by applications > to set aside private regions of code and

Re: [PATCH 3/9] drm: replace "drm_dev_unref" function with "drm_dev_put"

2018-11-16 Thread Lucas Stach
Am Donnerstag, den 15.11.2018, 23:16 +0100 schrieb Fernando Ramos: > This patch unifies the naming of DRM functions for reference counting as > requested on Documentation/gpu/todo.rst > > > Signed-off-by: Fernando Ramos > --- >  drivers/gpu/drm/arc/arcpgu_drv.c | 4 ++-- >  drivers/gpu