Re: [PATCH 03/24] leds: dt-bindings: Add LED_FUNCTION definitions

2018-11-08 Thread Rob Herring
On Tue, Nov 6, 2018 at 4:07 PM Jacek Anaszewski wrote: > > Add common LED function definitions for use in Device Tree. > The function names were extracted from existing dts files > after eliminating oddities. > > Signed-off-by: Jacek Anaszewski > Cc: Baolin Wang > Cc: Daniel Mack > Cc: Dan Murp

Re: RFC: userspace exception fixups

2018-11-08 Thread Jarkko Sakkinen
On Wed, Nov 07, 2018 at 01:40:59PM -0800, Sean Christopherson wrote: > > In that case it seems like the only way to use SGX that's not a gaping > > security hole is to run the SGX enclave in its own fully-seccomp (or > > equivalent) process, with no host application in the same address > > space. S

Re: [patch 0/2] Documentation/process: Add subsystem/tree handbook

2018-11-08 Thread Peter Zijlstra
On Thu, Nov 08, 2018 at 07:49:20AM -0700, Jonathan Corbet wrote: > Might it be worth asking Ted for a kernel summit slot to talk about this > next week? Ah, on that, let me complain :-) My plumbers schedule is already 100% booked with MCs and other things. There is no kernel-summit schedule detai

Re: [PATCH 01/10] irqdomain: Add interface to request an irq domain

2018-11-08 Thread Richter, Robert
Julien, thanks for your review. See my comments below. On 08.11.18 10:19:52, Julien Thierry wrote: > On 07/11/18 22:03, Robert Richter wrote: > >This patch introduces a new interface to allow irq domain > >initialization regardless of order dependencies. This is done by > >requesting a domain and

Re: RFC: userspace exception fixups

2018-11-08 Thread Jarkko Sakkinen
On Wed, Nov 07, 2018 at 12:56:58PM -0800, Dave Hansen wrote: > On 11/7/18 11:01 AM, Sean Christopherson wrote: > > Going off comments in similar code related to UMIP, we'd need to figure > > out how to handle protection keys. > > There are two options: > 1. Don't depend on the userspace mapping.

Re: [PATCH v2] x86/cpu: fix prototype warning

2018-11-08 Thread Borislav Petkov
On Thu, Nov 08, 2018 at 09:12:28AM +0800, Yi Wang wrote: > This patch fix the following build warnings which because of missing > include file: > > arch/x86/kernel/cpu/cacheinfo.c:647:6: warning: no previous prototype for > ‘cacheinfo_amd_init_llc_id’ [-Wmissing-prototypes] > arch/x86/kernel/cpu/

Re: [PATCH v5 08/17] tpm: access command header through struct in tpm_try_transmit()

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: Instead of accessing fields of the command header through offsets to the raw buffer, it is a better idea to use the header struct pointer that is already used elsewhere in the function. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --

Re: [PATCH v3 3/3] MAINTAINERS: Add entry for i2c-omap driver

2018-11-08 Thread Tony Lindgren
* Vignesh R [181108 12:28]: > > > On 08/11/18 2:53 PM, Wolfram Sang wrote: > > On Thu, Nov 08, 2018 at 02:49:31PM +0530, Vignesh R wrote: > >> Add separate entry for i2c-omap and add my name as reviewer for this > >> driver. > > > > Thanks for stepping up, yet out of curiosity: why not maintain

Re: [PATCH v5 07/17] tpm: declare struct tpm_header

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: Decleare struct tpm_header that replaces struct tpm_input_header and struct tpm_output_header. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm-interface.c | 9 - drivers/char/tpm/tpm.h|

Re: [PATCH v2] of, numa: Validate some distance map rules

2018-11-08 Thread John Garry
On 08/11/2018 13:41, Anshuman Khandual wrote: On 11/08/2018 03:47 PM, John Garry wrote: Currently the NUMA distance map parsing does not validate the distance table for the distance-matrix rules 1-2 in [1]. Right. However the arch NUMA code may enforce some of these rules, but not all. Ei

Re: [PATCH] pinctrl: zynq: Use define directive for PIN_CONFIG_IO_STANDARD

2018-11-08 Thread Nathan Chancellor
On Thu, Nov 08, 2018 at 07:45:42AM +0100, Michal Simek wrote: > On 07. 11. 18 18:48, Nick Desaulniers wrote: > > On Wed, Nov 7, 2018 at 1:01 AM Michal Simek wrote: > >> > >> On 07. 11. 18 9:55, Nathan Chancellor wrote: > >>> On Wed, Nov 07, 2018 at 09:46:12AM +0100, Michal Simek wrote: > On 0

Re: [PATCH 3/7] mtd: spi-nor: add restriction for nmaps in smpt parser

2018-11-08 Thread Tudor.Ambarus
On 11/08/2018 04:54 PM, Boris Brezillon wrote: > On Thu, 8 Nov 2018 14:48:11 + > wrote: > >> + > > Maybe I missed something but it sounds like this change is just > optimizing the SPMT parsing a bit, and to be honest, I'm not sure this > is really needed. Most of t

Re: [PATCH v5 06/17] tpm: clean up tpm_try_transmit() error handling flow

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: Move locking, locality handling and power management to tpm_transmit() in order to simplify the flow. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm-interface.c | 71 1 file

Re: [PATCH 02/23] x86/fpu: Remove fpu->initialized usage in __fpu__restore_sig()

2018-11-08 Thread Borislav Petkov
On Wed, Nov 07, 2018 at 08:48:37PM +0100, Sebastian Andrzej Siewior wrote: > This is a preparation for the removal of the ->initialized member in the > fpu struct. > __fpu__restore_sig() is deactivating the FPU via fpu__drop() and then > setting manually ->initialized followed by fpu__restore(). Th

Re: [PATCH v5 05/17] tpm: print tpm2_commit_space() error inside tpm2_commit_space()

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: The error logging for tpm2_commit_space() is in a wrong place. This commit moves it inside that function. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm-interface.c | 8 ++-- drivers/char/tpm/tpm2-space.

Re: [PATCH v5 04/17] tpm: call tpm2_flush_space() on error in tpm_try_transmit()

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: Always call tpm2_flush_space() on failure in tpm_try_transmit() so that the volatile memory of the TPM gets cleared. If /dev/tpm0 does not have sufficient permissions (usually it has), this could lead to the leakage of TPM objects. Through /dev/tpmrm0 th

Re: [RFC 0/2] Add RISC-V cpu topology

2018-11-08 Thread Nick Kossifidis
Στις 2018-11-07 14:28, Sudeep Holla έγραψε: On Wed, Nov 07, 2018 at 04:31:34AM +0200, Nick Kossifidis wrote: [...] Mark and Sudeep thanks a lot for your feedback, I guess you convinced me that having a device tree binding for the scheduler is not a correct approach. Thanks :) It's not a

Re: [PATCH v2] ext4: missing !bh check in ext4_xattr_inode_write()

2018-11-08 Thread Theodore Y. Ts'o
On Thu, Nov 08, 2018 at 09:46:30AM +0300, Vasily Averin wrote: > diff --git a/fs/ext4/xattr.c b/fs/ext4/xattr.c > index 0b9688683526..415f73d4c9e6 100644 > --- a/fs/ext4/xattr.c > +++ b/fs/ext4/xattr.c > @@ -1384,6 +1384,12 @@ static int ext4_xattr_inode_write(handle_t *handle, > struct inode *ea_

Re: [PATCH 3/7] mtd: spi-nor: add restriction for nmaps in smpt parser

2018-11-08 Thread Boris Brezillon
On Thu, 8 Nov 2018 14:48:11 + wrote: > + > >>> > >>> Maybe I missed something but it sounds like this change is just > >>> optimizing the SPMT parsing a bit, and to be honest, I'm not sure this > >>> is really needed. Most of the time, smpt_len will be rather small, so > >>> trying

Re: [PATCH v4 2/6] tpm: remove definition of TPM2_ACTIVE_PCR_BANKS

2018-11-08 Thread Roberto Sassu
On 11/8/2018 3:03 PM, Jarkko Sakkinen wrote: On Thu, Nov 08, 2018 at 04:02:08PM +0200, Jarkko Sakkinen wrote: On Tue, Nov 06, 2018 at 04:01:55PM +0100, Roberto Sassu wrote: tcg_efi_specid_event and tcg_pcr_event2 declaration contains static arrays for a list of hash algorithms used for event lo

Re: [PATCH v5 03/17] tpm: return 0 from pcrs_show() when tpm1_pcr_read() fails

2018-11-08 Thread Stefan Berger
On 11/8/18 9:15 AM, Jarkko Sakkinen wrote: Do not print partial list of PCRs when tpm1_pcr_read() fails but instead return 0 from pcrs_show(). This is consistent behavior with other sysfs functions. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm-sysfs

Re: [patch 0/2] Documentation/process: Add subsystem/tree handbook

2018-11-08 Thread Jonathan Corbet
On Wed, 7 Nov 2018 21:51:38 +0100 (CET) Thomas Gleixner wrote: > So I agree with Dan, that we should collect as much documentation from > subsystems/maintainers and get it into the tree so we can: > >- give contributors immediate access to subsystem/maintainer specific > quirks > >

Re: [PATCH 3/7] mtd: spi-nor: add restriction for nmaps in smpt parser

2018-11-08 Thread Tudor.Ambarus
On 11/08/2018 04:15 PM, Boris Brezillon wrote: > On Thu, 8 Nov 2018 13:58:45 + > wrote: > >> On 11/08/2018 02:54 PM, Boris Brezillon wrote: >>> On Thu, 8 Nov 2018 11:07:11 + >>> wrote: >>> The map selector is limited to a maximum of 8 bits, allowing for a maximum of 256 po

Re: [PATCH v4 6/6] tpm: ensure that the output of PCR read contains the correct digest size

2018-11-08 Thread Roberto Sassu
On 11/8/2018 3:08 PM, Jarkko Sakkinen wrote: On Tue, Nov 06, 2018 at 04:01:59PM +0100, Roberto Sassu wrote: This patch protects against data corruption that could happen in the bus, by checking that that the digest size returned by the TPM during a PCR read matches the size of the algorithm pass

Re: [PATCH v8 0/8] arm64: untag user pointers passed to the kernel

2018-11-08 Thread Andrey Konovalov
On Thu, Nov 8, 2018 at 3:36 PM, Andrey Konovalov wrote: [...] > Changes in v8: > - Rebased onto 65102238 (4.20-rc1). > - Added a note to the cover letter on why syscall wrappers/shims that untag > user pointers won't work. > - Added a note to the cover letter that this patchset has been merged

[Resend PATCH V5 10/10] KVM/MMU: Flush tlb directly in the kvm_zap_gfn_range()

2018-11-08 Thread lantianyu1986
From: Lan Tianyu Originally, flush tlb is done by slot_handle_level_range(). This patch is to flush tlb directly in the kvm_zap_gfn_range() when range flush is available. Signed-off-by: Lan Tianyu --- Change since v4: Move operation of setting flush_tlb out of for loop. --- arch/x86/kv

[Resend PATCH V5 9/10] KVM/MMU: Flush tlb directly in the kvm_set_pte_rmapp()

2018-11-08 Thread lantianyu1986
From: Lan Tianyu This patch is to flush tlb directly in the kvm_set_pte_rmapp() and return 0. Signed-off-by: Lan Tianyu --- arch/x86/kvm/mmu.c | 5 + 1 file changed, 5 insertions(+) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index b13b419166c4..39e0e2572710 100644 --- a/arch/x86

[Resend PATCH V5 8/10] KVM/MMU: Move tlb flush in kvm_set_pte_rmapp() to kvm_mmu_notifier_change_pte()

2018-11-08 Thread lantianyu1986
From: Lan Tianyu This patch is to move tlb flush in kvm_set_pte_rmapp() to kvm_mmu_notifier_change_pte() in order to avoid redundant tlb flush. Signed-off-by: Lan Tianyu --- arch/x86/kvm/mmu.c | 8 ++-- virt/kvm/kvm_main.c | 5 - 2 files changed, 6 insertions(+), 7 deletions(-) diff

Re: [PATCH 1/2] perf/x86/intel/uncore: Add more IMC PCI IDs for KabyLake and CoffeeLake

2018-11-08 Thread Peter Zijlstra
On Thu, Nov 08, 2018 at 08:35:40AM -0500, Liang, Kan wrote: > Hi All, > > Ping. > Any comments for the series. Got them now. Thanks!

Re: [PATCH v16 18/22] platform/x86: Intel SGX driver

2018-11-08 Thread Jarkko Sakkinen
On Wed, Nov 07, 2018 at 10:00:57AM -0800, Sean Christopherson wrote: > What do we gain by a single buffer vs. separate buffers? The ioctl() > would be slightly smaller but it seems like the actual code would be > more complex. I'm fine with either. It was just a suggestion. > The enclave build p

[PATCH] arm/mach-sa1100/hackkit.c: Remove duplicate header

2018-11-08 Thread Brajeswar Ghosh
Remove linux/tty.h which is included more than once Signed-off-by: Brajeswar Ghosh --- arch/arm/mach-sa1100/hackkit.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/mach-sa1100/hackkit.c b/arch/arm/mach-sa1100/hackkit.c index 643d5f2d9af9..0016d25e7deb 100644 --- a/arch/arm/mach-sa1

[[PATCH]] mips: Fix switch to NO_BOOTMEM for SGI-IP27/loongons3 NUMA

2018-11-08 Thread Thomas Bogendoerfer
Commit bcec54bf3118 ("mips: switch to NO_BOOTMEM") broke SGI-IP27 and NUMA enabled loongson3 by doing memblock_set_current_limit() before max_low_pfn has been evaluated. Both platforms need to do the memblock_set_current_limit() in platform specific code. For consistency the call to memblock_set_cu

[PATCH 2/2] tracing: Check keys for variable references in expressions too

2018-11-08 Thread Tom Zanussi
From: Tom Zanussi There's an existing check for variable references in keys, but it doesn't go far enough. It checks whether a key field is a variable reference but doesn't check whether it's an expression containing variable references, which can cause the same problems for callers. Use the ex

[PATCH 0/2] tracing: Fix NULL pointer bug in hist key expressions

2018-11-08 Thread Tom Zanussi
From: Tom Zanussi Hi Steve, This is a fix for a user-reported bug in the hist triggers, where if a variable reference is used in an expression in a histogram key, it results in a NULL pointer dereference and subsequent Oops. I separated the fix into two small patches, the first preventing the i

[PATCH 1/2] tracing: Prevent hist_field_var_ref() from accessing NULL tracing_map_elts

2018-11-08 Thread Tom Zanussi
From: Tom Zanussi hist_field_var_ref() is an implementation of hist_field_fn_t(), which can be called with a null tracing_map_elt elt param when assembling a key in event_hist_trigger(). In the case of hist_field_var_ref() this doesn't make sense, because a variable can only be resolved by looki

Re: [PATCH] arm64: dts: meson-axg: add secure monitor

2018-11-08 Thread Neil Armstrong
On 08/11/2018 14:07, Jerome Brunet wrote: > Add the secure monitor device to the axg platform. > With this, we can read the SoC serial number. > > Signed-off-by: Jerome Brunet > --- > arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 4 > 1 file changed, 4 insertions(+) > > diff --git a/arch/ar

Re: [PATCH v4 1/6] tpm: dynamically allocate active_banks array

2018-11-08 Thread Roberto Sassu
On 11/8/2018 2:50 PM, Nayna Jain wrote: On 11/07/2018 03:11 PM, Roberto Sassu wrote: On 11/7/2018 7:14 AM, Nayna Jain wrote: On 11/06/2018 08:31 PM, Roberto Sassu wrote: This patch removes the hard-coded limit of the active_banks array size. The hard-coded limit in static array active_b

Re: [PATCH v1] PCI: Move Rohm vendor ID to generic list

2018-11-08 Thread Mark Brown
On Wed, Nov 07, 2018 at 09:58:56PM +0200, Andy Shevchenko wrote: > Move the Rohm vendor ID to pci_ids.h from dozen of drivers. > > Signed-off-by: Andy Shevchenko Acked-by: Mark Brown signature.asc Description: PGP signature

Re: [RFC PATCH] ptrace: add PTRACE_GET_SYSCALL_INFO request

2018-11-08 Thread Oleg Nesterov
On 11/07, Andy Lutomirski wrote: > > > On Nov 7, 2018, at 8:44 AM, Oleg Nesterov wrote: > > > > Not sure I understand you... I do not like "compat" too, but this patch uses > > is_compat/etc and I agree with any naming. > > My point is: returning a value to user code that is: > > 0 if the kernel a

Re: [PATCH 2/2] ubi: Expose the bitrot interface

2018-11-08 Thread Richard Weinberger
Am Donnerstag, 8. November 2018, 15:26:42 CET schrieb Boris Brezillon: > On Wed, 7 Nov 2018 23:16:19 +0100 > Richard Weinberger wrote: > > > +/** > > + * ubi_bitflip_check - Check an eraseblock for bitflips and scrub it if > > needed. > > + * @ubi: UBI device description object > > + * @pnum: t

Re: [PATCH v7 0/7] clocksource: rework Atmel TCB timer driver

2018-11-08 Thread Sebastian Andrzej Siewior
On 2018-11-08 15:09:35 [+0100], Alexandre Belloni wrote: > It is not part of that series as I prefer to keep the discussion of how > to configure that for later. This has been raised previously without any > conclusion and I'd really like to see this rework enter upstream soon. Okay. Does it make

Re: [PATCH v3 2/3] iio: adc: Add ad7124 support

2018-11-08 Thread Popa, Stefan Serban
On Sb, 2018-11-03 at 12:16 +, Jonathan Cameron wrote: > On Mon, 29 Oct 2018 18:38:31 +0200 > Stefan Popa wrote: > > > > > The ad7124-4 and ad7124-8 are a family of 4 and 8 channel sigma-delta > > ADCs > > with 24-bit precision and reference. > > > > Three power modes are available which in

Re: [PATCH V3] binder: ipc namespace support for android binder

2018-11-08 Thread Christian Brauner
On Thu, Nov 08, 2018 at 01:02:32PM +, chouryzhou(周威) wrote: > We are working for running android in container, but we found that binder is > not isolated by ipc namespace. Since binder is a form of IPC and therefore > should > be tied to ipc namespace. With this patch, we can run more than o

Re: [PATCH anybus v3 5/6] dt-bindings: anybuss-host: document devicetree binding

2018-11-08 Thread Arnd Bergmann
On Thu, Nov 8, 2018 at 3:21 PM Sven Van Asbroeck wrote: > > Hi Arnd, thank you for the review and the feedback ! > > > > > To allow describing connected devices, I think we need a #address-cells > > and #size-cells property here, with fixed values. > > I'm not sure I understand. Connected devices

Re: [PATCH 2/2] ubi: Expose the bitrot interface

2018-11-08 Thread Boris Brezillon
On Wed, 7 Nov 2018 23:16:19 +0100 Richard Weinberger wrote: > +/** > + * ubi_bitflip_check - Check an eraseblock for bitflips and scrub it if > needed. > + * @ubi: UBI device description object > + * @pnum: the physical eraseblock to schedule > + * @force_scrub: force scrubbing if non-zero, sch

Re: [PATCH v4 1/6] tpm: dynamically allocate active_banks array

2018-11-08 Thread Roberto Sassu
On 11/8/2018 2:46 PM, Jarkko Sakkinen wrote: Orrayn Tue, Nov 06, 2018 at 04:01:54PM +0100, Roberto Sassu wrote: This patch removes the hard-coded limit of the active_banks array size. It stores in the tpm_chip structure the number of active PCR banks, determined in tpm2_get_pcr_allocation(), and

Re: [PATCH anybus v3 5/6] dt-bindings: anybuss-host: document devicetree binding

2018-11-08 Thread Sven Van Asbroeck
Hi Arnd, thank you for the review and the feedback ! > > To allow describing connected devices, I think we need a #address-cells > and #size-cells property here, with fixed values. I'm not sure I understand. Connected devices aren't described in the devicetree. The anybus specification defines an

Re: [PATCH 3/3] lockdep: Use line-buffered printk() for lockdep messages.

2018-11-08 Thread Sergey Senozhatsky
On (11/08/18 21:44), Sergey Senozhatsky wrote: > > If lockdep and OOM people will ACK buffered printk transition in > its current form, then we can go ahead. That printk_safe approach in lockdep, BTW, does not change (convert) any printk-s within lockdep, thus Peter's earlycon should not be affec

Re: [PATCH anybus v3 6/6] misc: support HMS Profinet IRT industrial controller

2018-11-08 Thread Arnd Bergmann
On Sun, Nov 4, 2018 at 4:55 PM wrote: > + > +struct msgEthConfig { > + u32 ip_addr, subnet_msk, gateway_addr; > +} __packed; The __packed attribute makes it slower to access but doesn't change the layout, so better drop it. > +struct msgMacAddr { > + u8 addr[6]; > +} __packed; > + >

Re: [PATCH] arm64/numa: Add more vetting in numa_set_distance()

2018-11-08 Thread Anshuman Khandual
On 11/01/2018 04:57 PM, Will Deacon wrote: > [ Nit: Please wrap your lines when replying -- I've done it for you here ] > > On Tue, Oct 30, 2018 at 08:16:21AM +0530, Anshuman Khandual wrote: >> On 10/29/2018 08:14 PM, John Garry wrote: >>>  I think we should either factor out the sanity che

[PATCH v5 17/17] tpm: remove @flags from tpm_transmit()

2018-11-08 Thread Jarkko Sakkinen
Remove @flags from tpm_transmit() API. It is no longer used for anything. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-chip.c | 32 ++--- drivers/char/tpm/tpm-dev-common.c | 2 +- drivers/char/tpm/tpm-interface.c | 18 drivers/char/tpm/tpm-sysfs.c

[PATCH v5 16/17] tpm: take TPM chip power gating out of tpm_transmit()

2018-11-08 Thread Jarkko Sakkinen
Call tpm_chip_start() and tpm_chip_stop() in * tpm_try_get_ops() and tpm_put_ops() * tpm_chip_register() * tpm2_del_space() And remove these calls from tpm_transmit(). The core reason for this change is that in tpm_vtpm_proxy a locality change requires a virtual TPM command (a command made up jus

[PATCH v5 15/17] tpm: introduce tpm_chip_start() and tpm_chip_stop()

2018-11-08 Thread Jarkko Sakkinen
Encapsulate power gating and locality functionality to tpm_chip_start() and tpm_chip_stop() in order to clean up the branching mess in tpm_transmit(). Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-chip.c | 110 +++ drivers/char/tpm/tpm-interface.c | 87

[PATCH v5 14/17] tpm: remove TPM_TRANSMIT_UNLOCKED flag

2018-11-08 Thread Jarkko Sakkinen
Added locking as part of tpm_try_get_ops() and tpm_put_ops() as they are anyway used in most of the call sites except in tpmrm_release() where we take the locks manually. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-chip.c | 2 ++ drivers/char/tpm/tpm-dev-common.c | 4 +--- dr

[PATCH v5 13/17] tpm: use tpm_try_get_ops() in tpm-sysfs.c.

2018-11-08 Thread Jarkko Sakkinen
Use tpm_try_get_ops() in tpm-sysfs.c so that we can consider moving other decorations (locking, localities, power management for example) inside it. This direction can be of course taken only after other call sites for tpm_transmit() have been treated in the same way. Signed-off-by: Jarkko Sakkine

[PATCH v5 11/17] tpm: move TPM space code out of tpm_transmit()

2018-11-08 Thread Jarkko Sakkinen
Prepare and commit TPM space before and after calling tpm_transmit() instead of doing that inside tpm_transmit(). After this change we can remove TPM_TRANSMIT_NESTED flag from tpm2_prepare_space() and tpm2_commit_space() and replace it with TPM_TRANSMIT_UNLOCKED. Signed-off-by: Jarkko Sakkinen --

[PATCH v5 12/17] tpm: remove @space from tpm_transmit()

2018-11-08 Thread Jarkko Sakkinen
Remove @space from tpm_transmit() API` in order to completely remove the bound between low-level transmission functionality and TPM spaces. The only real dependency existing is the amount of data saved before trying to send a command to the TPM. It doesn't really matter if we save always a bit mor

[PATCH v5 10/17] tpm: encapsulate tpm_dev_transmit()

2018-11-08 Thread Jarkko Sakkinen
Encapsulate tpm_transmit() call pattern to tpm_dev_transmit() because it is identically used from two places. Use unlocked version of tpm_transmit() so that we are able to move the calls to tpm2_prepare_space() and tpm2_commit_space() later on to this new function. Signed-off-by: Jarkko Sakkinen

[PATCH v5 09/17] tpm: move tpm_validate_commmand() to tpm2-space.c

2018-11-08 Thread Jarkko Sakkinen
Move tpm_validate_command() to tpm2-space.c and make it part of the tpm2_prepare_space() flow. Make cc resolution as part of the TPM space functionality in order to detach it from rest of the tpm_transmit() flow. Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm

[PATCH v5 08/17] tpm: access command header through struct in tpm_try_transmit()

2018-11-08 Thread Jarkko Sakkinen
Instead of accessing fields of the command header through offsets to the raw buffer, it is a better idea to use the header struct pointer that is already used elsewhere in the function. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-interface.c | 4 ++-- 1 file changed, 2 insertions(+),

[PATCH v5 07/17] tpm: declare struct tpm_header

2018-11-08 Thread Jarkko Sakkinen
Decleare struct tpm_header that replaces struct tpm_input_header and struct tpm_output_header. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-interface.c | 9 - drivers/char/tpm/tpm.h| 27 --- drivers/char/tpm/tpm2-cmd.c | 4 ++-- dri

[PATCH v5 06/17] tpm: clean up tpm_try_transmit() error handling flow

2018-11-08 Thread Jarkko Sakkinen
Move locking, locality handling and power management to tpm_transmit() in order to simplify the flow. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-interface.c | 71 1 file changed, 35 insertions(+), 36 deletions(-) diff --git a/drivers/char/tpm/tpm-in

[PATCH v5 05/17] tpm: print tpm2_commit_space() error inside tpm2_commit_space()

2018-11-08 Thread Jarkko Sakkinen
The error logging for tpm2_commit_space() is in a wrong place. This commit moves it inside that function. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-interface.c | 8 ++-- drivers/char/tpm/tpm2-space.c| 9 ++--- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git

[PATCH v5 03/17] tpm: return 0 from pcrs_show() when tpm1_pcr_read() fails

2018-11-08 Thread Jarkko Sakkinen
Do not print partial list of PCRs when tpm1_pcr_read() fails but instead return 0 from pcrs_show(). This is consistent behavior with other sysfs functions. Signed-off-by: Jarkko Sakkinen --- drivers/char/tpm/tpm-sysfs.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --

[PATCH v5 01/17] tpm: use tpm_buf in tpm_transmit_cmd() as the IO parameter

2018-11-08 Thread Jarkko Sakkinen
Since we pass an initialized struct tpm_buf instance in every call site now, it is cleaner to pass that directly to the tpm_transmit_cmd() as the TPM command/response buffer. Fine-tune a little bit tpm_transmit() and tpm_transmit_cmd() comments while doing this. Signed-off-by: Jarkko Sakkinen Re

Re: [PATCH v4 4/6] tpm: modify tpm_pcr_read() definition to pass a TPM hash algorithm

2018-11-08 Thread Roberto Sassu
On 11/8/2018 3:04 PM, Jarkko Sakkinen wrote: On Tue, Nov 06, 2018 at 04:01:57PM +0100, Roberto Sassu wrote: Currently the TPM driver allows other kernel subsystems to read only the SHA1 PCR bank. This patch modifies the parameters of tpm_pcr_read() and tpm2_pcr_read() to pass a tpm_digest struct

[PATCH v5 04/17] tpm: call tpm2_flush_space() on error in tpm_try_transmit()

2018-11-08 Thread Jarkko Sakkinen
Always call tpm2_flush_space() on failure in tpm_try_transmit() so that the volatile memory of the TPM gets cleared. If /dev/tpm0 does not have sufficient permissions (usually it has), this could lead to the leakage of TPM objects. Through /dev/tpmrm0 this issue does not raise any new security conc

[PATCH v5 02/17] tpm: fix invalid return value in pubek_show()

2018-11-08 Thread Jarkko Sakkinen
Return zero when tpm_buf_init() fails as we do for other functions in tpm-sysfs.c. Fixes: da379f3c1db0c ("tpm: migrate pubek_show to struct tpm_buf") Signed-off-by: Jarkko Sakkinen Reviewed-by: Stefan Berger --- drivers/char/tpm/tpm-sysfs.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletion

[PATCH v5 00/17] Remove nested TPM operations

2018-11-08 Thread Jarkko Sakkinen
[was Detach TPM space code out of the tpm_transmit() flow but the scope expanded a bit.] Make the changes necessary to detach TPM space code and TPM activation code out of the tpm_transmit() flow because of both of these can cause nested tpm_transmit() calls. The nesteds calls make the whole flow

Re: [PATCH 3/7] mtd: spi-nor: add restriction for nmaps in smpt parser

2018-11-08 Thread Boris Brezillon
On Thu, 8 Nov 2018 13:58:45 + wrote: > On 11/08/2018 02:54 PM, Boris Brezillon wrote: > > On Thu, 8 Nov 2018 11:07:11 + > > wrote: > > > >> The map selector is limited to a maximum of 8 bits, allowing > >> for a maximum of 256 possible map configurations. The total > >> number of map

Re: [PATCH V3 2/3] dt-bindings: mmc: sdhci-msm: Add entries for passing load values

2018-11-08 Thread Veerabhadrarao Badiganti
On 10/12/2018 8:25 PM, Rob Herring wrote: On Mon, Oct 08, 2018 at 06:48:58PM +0530, Veerabhadrarao Badiganti wrote: From: Vijay Viswanath The load a particular sdhc controller should request from a regulator is device specific and hence each device should individually vote for the required

Re: [PATCH anybus v3 5/6] dt-bindings: anybuss-host: document devicetree binding

2018-11-08 Thread Arnd Bergmann
On Sun, Nov 4, 2018 at 4:55 PM wrote: > --- > .../bindings/bus/arcx,anybuss-host.txt| 36 +++ > 1 file changed, 36 insertions(+) > create mode 100644 > Documentation/devicetree/bindings/bus/arcx,anybuss-host.txt > > diff --git a/Documentation/devicetree/bindings/bus/ar

Re: [PATCH v7 0/7] clocksource: rework Atmel TCB timer driver

2018-11-08 Thread Alexandre Belloni
On 08/11/2018 13:43:27+0100, Sebastian Andrzej Siewior wrote: > On 2018-09-25 22:14:56 [+0200], Alexandre Belloni wrote: > > On 22/09/2018 13:29:48+0200, Daniel Lezcano wrote: > > > You say for rt the PIT is not suitable because of the shared irq but in > > > the driver, the interrupt is flagged as

Re: [PATCH v4 6/6] tpm: ensure that the output of PCR read contains the correct digest size

2018-11-08 Thread Jarkko Sakkinen
On Tue, Nov 06, 2018 at 04:01:59PM +0100, Roberto Sassu wrote: > This patch protects against data corruption that could happen in the bus, > by checking that that the digest size returned by the TPM during a PCR read > matches the size of the algorithm passed as argument to tpm2_pcr_read(). > > Th

Re: [PATCH anybus v3 4/6] bus: support HMS Anybus-S bus

2018-11-08 Thread Arnd Bergmann
On Sun, Nov 4, 2018 at 4:55 PM wrote: > From: Sven Van Asbroeck > +struct anybus_mbox_hdr { > + u16 id; > + u16 info; > + u16 cmd_num; > + u16 data_size; > + u16 frame_count; > + u16 frame_num; > + u16 offset_high; > + u16 offset_low; > + u16

Re: [PATCH v4 4/6] tpm: modify tpm_pcr_read() definition to pass a TPM hash algorithm

2018-11-08 Thread Jarkko Sakkinen
On Tue, Nov 06, 2018 at 04:01:57PM +0100, Roberto Sassu wrote: > Currently the TPM driver allows other kernel subsystems to read only the > SHA1 PCR bank. This patch modifies the parameters of tpm_pcr_read() and > tpm2_pcr_read() to pass a tpm_digest structure, which contains the desired > hash alg

Re: [PATCH v4 2/6] tpm: remove definition of TPM2_ACTIVE_PCR_BANKS

2018-11-08 Thread Jarkko Sakkinen
On Thu, Nov 08, 2018 at 04:02:08PM +0200, Jarkko Sakkinen wrote: > On Tue, Nov 06, 2018 at 04:01:55PM +0100, Roberto Sassu wrote: > > tcg_efi_specid_event and tcg_pcr_event2 declaration contains static arrays > > for a list of hash algorithms used for event logs and event log digests. > > However,

Re: [RFC PATCH v1 2/2] proc: add /proc//thread_state

2018-11-08 Thread Li, Aubrey
On 2018/11/8 18:17, Peter Zijlstra wrote: > On Thu, Nov 08, 2018 at 07:32:46AM +0100, Ingo Molnar wrote: >> >> * Aubrey Li wrote: >> >>> Expose the per-task cpu specific thread state value, it's helpful >>> for userland to classify and schedule the tasks by different policies >> >> That's pretty v

Re: [PATCH v4 2/6] tpm: remove definition of TPM2_ACTIVE_PCR_BANKS

2018-11-08 Thread Jarkko Sakkinen
On Tue, Nov 06, 2018 at 04:01:55PM +0100, Roberto Sassu wrote: > tcg_efi_specid_event and tcg_pcr_event2 declaration contains static arrays > for a list of hash algorithms used for event logs and event log digests. > However, according to TCG EFI Protocol Specification, these arrays have > variable

Re: [PATCH 3/7] mtd: spi-nor: add restriction for nmaps in smpt parser

2018-11-08 Thread Tudor.Ambarus
On 11/08/2018 02:54 PM, Boris Brezillon wrote: > On Thu, 8 Nov 2018 11:07:11 + > wrote: > >> The map selector is limited to a maximum of 8 bits, allowing >> for a maximum of 256 possible map configurations. The total >> number of map configurations should be addressable by the >> total numb

Re: [PATCH] ASoC: qcom: Set dai_link id to each dai_link

2018-11-08 Thread Srinivas Kandagatla
Hi Rohit, On 08/11/18 13:41, Rohit kumar wrote: Frontend dai_link id is used for closing ADM sessions. During concurrent usecase when one session is closed, it closes other ADM session associated with other usecase too. Dai_link->id should always point to Frontend dai id. Set cpu_dai id as dai_l

Re: [PATCH v4 1/6] tpm: dynamically allocate active_banks array

2018-11-08 Thread Nayna Jain
On 11/07/2018 03:11 PM, Roberto Sassu wrote: On 11/7/2018 7:14 AM, Nayna Jain wrote: On 11/06/2018 08:31 PM, Roberto Sassu wrote: This patch removes the hard-coded limit of the active_banks array size. The hard-coded limit in static array active_banks[] represents the maximum possible

[PATCH 0/4] arm64: dts: meson-axg: enable SCPI

2018-11-08 Thread Jerome Brunet
The goal of this patchset is to enable SCPI (dvfs and hwmon) the axg platform. The first patches in this series fix a few issues to acheive this. Jerome Brunet (4): arm64: dts: meson-axg: fix mailbox address arm64: dts: meson-axg: correct sram shared mem unit-address Documentation: bindings:

[PATCH 2/4] arm64: dts: meson-axg: correct sram shared mem unit-address

2018-11-08 Thread Jerome Brunet
Correct the unit-address in the node name of the SRAM shared memory Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi b/arch/arm64/boot/dts/amlogic/meson-

[PATCH 4/4] arm64: dts: meson-axg: enable SCPI

2018-11-08 Thread Jerome Brunet
Enable SCPI on the axg platform, with cpu clock and hwmon (core temperature) support Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 26 ++ 1 file changed, 26 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-axg.dtsi b/arch/arm64/bo

[PATCH 3/4] Documentation: bindings: Add missing Amlogic SCPI sensor bindings

2018-11-08 Thread Jerome Brunet
amlogic,meson-gxbb-scpi-sensors is both the driver and DT but is not documented. Just add it to amlogic's scpi documentation Signed-off-by: Jerome Brunet --- Documentation/devicetree/bindings/arm/amlogic,scpi.txt | 7 +++ 1 file changed, 7 insertions(+) diff --git a/Documentation/devicetree

[PATCH 1/4] arm64: dts: meson-axg: fix mailbox address

2018-11-08 Thread Jerome Brunet
MHU mailbox address is wrong. Fixing it enables the mailboxes on the A113. These mailboxes are needed for SCPI Fixes: 9d59b708500f ("arm64: dts: meson-axg: add initial A113D SoC DT support") Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-axg.dtsi | 4 ++-- 1 file changed, 2 i

Re: [PATCH v4 0/6] tpm: retrieve digest size of unknown algorithms from TPM

2018-11-08 Thread Jarkko Sakkinen
On Tue, Nov 06, 2018 at 04:01:53PM +0100, Roberto Sassu wrote: > The TPM driver currently relies on the crypto subsystem to determine the > digest size of supported TPM algorithms. In the future, TPM vendors might > implement new algorithms in their chips, and those algorithms might not > be suppor

Re: [PATCH v2 2/2] staging: iio: ad7780: generates pattern_mask from PAT bits

2018-11-08 Thread Ardelean, Alexandru
On Thu, 2018-11-08 at 11:03 -0200, Giuliano Belinassi wrote: > Previously, all pattern_masks and patterns in the chip_info table were > hardcoded. Now they are generated using the PAT macros, as described in > the datasheets. One comment about indentation/whitespace. Rest looks good. Alex > >

Re: [RFC 0/2] Add RISC-V cpu topology

2018-11-08 Thread Nick Kossifidis
Στις 2018-11-07 14:06, Mark Rutland έγραψε: On Wed, Nov 07, 2018 at 04:31:34AM +0200, Nick Kossifidis wrote: Mark and Sundeep thanks a lot for your feedback, I guess you convinced me that having a device tree binding for the scheduler is not a correct approach. It's not a device after all and I

Re: [PATCH v4 1/6] tpm: dynamically allocate active_banks array

2018-11-08 Thread Jarkko Sakkinen
Orrayn Tue, Nov 06, 2018 at 04:01:54PM +0100, Roberto Sassu wrote: > This patch removes the hard-coded limit of the active_banks array size. > It stores in the tpm_chip structure the number of active PCR banks, > determined in tpm2_get_pcr_allocation(), and replaces the static array > with a pointe

[PATCH 0/4] Fix common issue in MAX* extcon drivers

2018-11-08 Thread Marek Szyprowski
Hi All Most MAX* MUIC drivers unconditionally force UART path during probe. This approach causes some issues, especially when board is booted with non-UART cable connected to micro-USB port. For example, when USB cable is connected, UART TX/RX lines are unconditionally short-circuited to USB D+/D-

Re: [PATCH] z3fold: fix wrong handling of headless pages

2018-11-08 Thread Jongseok Kim
Yes, you are right. I think that's the best way to deal it. Thank you. Best regards, Jongseok > Den tors 8 nov. 2018 kl 13:34 skrev �� : > > > > Hi Vitaly, > > thank you for the reply. > > > > I agree your a new solution is more comprehensive and drop my patch is > > simple way. > > But, I t

[PATCH 4/4] extcon: max8997: Avoid forcing UART path on drive probe

2018-11-08 Thread Marek Szyprowski
Driver unconditionally forces UART path during probe, probably to ensure that one can get kernel serial log as soon as possible. This approach causes some issues, especially when board is booted with non-UART cable connected to micro-USB port. For example, when USB cable is connected, UART TX/RX l

[PATCH 3/4] extcon: max14577: Avoid forcing UART path on drive probe

2018-11-08 Thread Marek Szyprowski
Driver unconditionally forces UART path during probe, probably to ensure that one can get kernel serial log as soon as possible. This approach causes some issues, especially when board is booted with non-UART cable connected to micro-USB port. For example, when USB cable is connected, UART TX/RX l

[PATCH 1/4] extcon: max77843: Avoid forcing UART path on drive probe

2018-11-08 Thread Marek Szyprowski
Driver unconditionally forces UART path during probe, probably to ensure that one can get kernel serial log as soon as possible. This approach causes some issues, especially when board is booted with non-UART cable connected to micro-USB port. For example, when USB cable is connected, UART TX/RX l

[PATCH 2/4] extcon: max77693: Avoid forcing UART path on drive probe

2018-11-08 Thread Marek Szyprowski
Driver unconditionally forces UART path during probe, probably to ensure that one can get kernel serial log as soon as possible. This approach causes some issues, especially when board is booted with non-UART cable connected to micro-USB port. For example, when USB cable is connected, UART TX/RX l

Re: [PATCH 1/2] perf-bench: Add epoll parallel epoll_wait benchmark

2018-11-08 Thread Arnaldo Carvalho de Melo
Em Tue, Nov 06, 2018 at 04:13:25PM -0300, Arnaldo Carvalho de Melo escreveu: > Em Tue, Nov 06, 2018 at 10:23:49AM -0800, Davidlohr Bueso escreveu: > > Mind this fixlet for using et/oneshot and the multiq option. > > Yes sir, applied the fixup to the first patch in the series, applied the > second,

Re: [PATCH v2 1/2] staging: iio: ad7780: check if ad778x before gain update

2018-11-08 Thread Ardelean, Alexandru
On Thu, 2018-11-08 at 11:03 -0200, Giuliano Belinassi wrote: > Only the ad778x have the 'gain' status bit. Check it before updating > through a new variable is_ad778x in chip_info. > Looks good. Alex > Signed-off-by: Giuliano Belinassi > --- > Changes in v2: > - Squashed is_ad778x declar

[PATCH] arm64: dts: zynqmp: Fix node names which contain "_"

2018-11-08 Thread Michal Simek
s/_/-/ for node names. It fixes warnings like this: ... Warning (node_name_chars_strict): /cpu_opp_table: Character '_' not recommended in node name ... Issues reported by make dtbs W=12 Signed-off-by: Michal Simek --- dr_mode property is also reported but it is not fixed because code needs to

<    6   7   8   9   10   11   12   13   14   >