Re: [RFC KVM 18/27] kvm/isolation: function to copy page table entries for percpu buffer

2019-05-14 Thread Alexandre Chartre
On 5/14/19 10:34 AM, Andy Lutomirski wrote: On May 14, 2019, at 1:25 AM, Alexandre Chartre wrote: On 5/14/19 9:09 AM, Peter Zijlstra wrote: On Mon, May 13, 2019 at 11:18:41AM -0700, Andy Lutomirski wrote: On Mon, May 13, 2019 at 7:39 AM Alexandre Chartre wrote: pcpu_base_addr is alr

[PATCH] arm64: dts: meson: g12a: set uart_ao clocks

2019-05-14 Thread Jerome Brunet
Now that the AO clock controller is available, make the uarts of the always-on domain claim the appropriate peripheral clock. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/boot/dts/a

Re: [PATCH v12 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF MFD bindings

2019-05-14 Thread masonccyang
Hello, > >> There's precedence for such constructs being an MFD: please see > >> drivers/mfd/at91-usart.c, which registers a single MFD cell for either > >> serial or SPI. > >Thanks fir your example, Geert! :-) > > > okay, many thanks for your information. > > > > How about to patch RPF

Re: [PATCH v12 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF MFD bindings

2019-05-14 Thread masonccyang
Hi Sergei, > > > >Could you please indent with 1 or 2 tabs where you used 8 or 16 spaces? Sorry, I just copy this new DTS from git to my Notes email system, therefore, the "tabs space" is not alignment with original file. > > Patch new DTS to > =

From mrs maria johnson

2019-05-14 Thread Mrs Maria johnson
Dear friend. I am Mrs Maria Johnson an Active Banker, i saw your email address while browsing through the bank DTC Screen in my office yesterday so i decided to use this very chance to know you more, i have deal of ($10.5 million Dollars) to transfer into your account, if you are interested get ba

[PATCH] test_power: Add CURRENT and CHARGE_COUNTER properties

2019-05-14 Thread Lecopzer Chen
From: "Lecopzer Chen" Emulate battery current (variable) and battery CHARGE_COUNTER (same as battery_capacity) properties. Signed-off-by: Lecopzer Chen Cc: YJ Chiang --- drivers/power/supply/test_power.c | 33 +++ 1 file changed, 33 insertions(+) diff --git a/dri

Re: [PATCH v12 3/3] dt-bindings: mfd: Document Renesas R-Car Gen3 RPC-IF MFD bindings

2019-05-14 Thread Geert Uytterhoeven
Hi Mason, On Tue, May 14, 2019 at 11:46 AM wrote: > > >> There's precedence for such constructs being an MFD: please see > > >> drivers/mfd/at91-usart.c, which registers a single MFD cell for > > > second for the direct mapping read mode and > > > third for the write buffer ar

Re: [PATCH -tip v8 3/6] tracing/probe: Add ustring type for user-space string

2019-05-14 Thread Masami Hiramatsu
On Tue, 14 May 2019 09:24:26 +0200 Ingo Molnar wrote: > > * Masami Hiramatsu wrote: > > > +/* Return the length of string -- including null terminal byte */ > > +static nokprobe_inline int > > +fetch_store_strlen_user(unsigned long addr) > > +{ > > + return strnlen_unsafe_user((__force const

Re: [PATCH] ACPI / LPSS: Don't skip late system PM ops for hibernate on BYT/CHT

2019-05-14 Thread Hans de Goede
Hi, On 5/9/19 8:09 PM, Robert R. Howell wrote: Hi Hans On 5/9/19 2:50 AM, Hans de Goede wrote: Hi, On 09-05-19 06:24, Robert R. Howell wrote: On 4/30/19 8:39 AM, Hans de Goede wrote: I've just tried to reproduce the "Error i2c_dw_xfer call while suspended" error on suspend/resume on

[PATCH 3/3] arm64: dts: meson: sei510: enable i2c3

2019-05-14 Thread Jerome Brunet
Add the i2c bus used for RGB led controller. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dts | 6 ++ 1 file changed, 6 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dts b/arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dts index b

[PATCH 0/3] arm64: dts: meson: g12a: add i2c

2019-05-14 Thread Jerome Brunet
Add the i2c controllers and pinctrl definitions to the g12a DT then the busses present on the u200 and sei510. Notice the use of the pinconf DT property 'drive-strength-microamp'. Support for this property is not yet merged in meson pinctrl driver but the DT part as been acked by the DT maintainer

[PATCH 2/3] arm64: dts: meson: u200: enable i2c busses

2019-05-14 Thread Jerome Brunet
Add the 3 i2c busses present on the u200 reference design. Signed-off-by: Jerome Brunet --- .../boot/dts/amlogic/meson-g12a-u200.dts | 21 +++ 1 file changed, 21 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts b/arch/arm64/boot/dts/amlogic/meson-

[PATCH 1/3] arm64: dts: meson: g12a: add i2c nodes

2019-05-14 Thread Jerome Brunet
From: Guillaume La Roque Add pinctrl and nodes for i2c support on amlogic g12a Signed-off-by: Guillaume La Roque Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 268 1 file changed, 268 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic

[PATCH 2/7] tty: max310x: Introduce max310x_one port macro-wrapper

2019-05-14 Thread Serge Semin
uart_port structure instance is embedded into the max310x_one super-structure, which is accessed by some of the uart-port callback methods. In order to improve the callback's code readability lets define the to_max310x_port() wrapper which just translates the passed uart_port pointer to the max310x

[PATCH 6/7] tty: max310x: Optionally enable rs485 on startup

2019-05-14 Thread Serge Semin
UART port might be pre-configured with rs485 enabled flag at the time of the port starting up process. In this case we need to have the hardware rs485-related registers initialized in accordance with the rs485 flags and settings provided by the configs descriptor. Signed-off-by: Serge Semin ---

[PATCH 3/7] tty: max310x: Don't pass stacked buffers to SPI

2019-05-14 Thread Serge Semin
SPI transfer tx/rx buffers must be DMA-safe and the structure documentation clearly states this. Data declared on the system stack isn't DMA-safe [1]. Instead at least kernel memory should be used for the buffers. In order to fix this here we can create the buffers at the device probing stage and u

Re: [REGRESSION] usb: gadget: f_fs: Allow scatter-gather buffers

2019-05-14 Thread Andrzej Pietrasiewicz
Hi, W dniu 13.05.2019 o 20:09, John Stultz pisze: On Mon, May 13, 2019 at 7:08 AM Andrzej Pietrasiewicz wrote: Do you get "functionfs read size 512 > requested size 24, splitting request into multiple reads" message when problems happen? Unfortunately no. Actually that's a fortunate o

[PATCH 4/7] tty: max310x: Fix invalid baudrate divisors calculator

2019-05-14 Thread Serge Semin
Current calculator doesn't do it' job quite correct. First of all the max310x baud-rates generator supports the divisor being less than 16. In this case the x2/x4 modes can be used to double or quadruple the reference frequency. But the current baud-rate setter function just filters all these modes

[PATCH 0/7] tty: max310x: Simplify the code and fix a few bugs

2019-05-14 Thread Serge Semin
I started using this driver two years ago in kernek 4.4 and then in kernel 4.9. It didn't go well from the very beginning due to my platform peculiarities: DW SPI core with hardware CS and relatively slow MIPS-based SoC. This patchset is intended to fix some of the problems I found out during the m

[PATCH 1/7] tty: max310x: Simplify tx-work item code

2019-05-14 Thread Serge Semin
Since cmwq introduction in the kernel, workqueues've been turned into non-reentrant execution contexts [1]. It means any work item is guaranteed to be executed by at most one worker system-wide at any given time. Since tx-handler max310x_handle_tx() is called by a single work item we don't need it

[PATCH 5/7] tty: max310x: Add rx-during-tx rs485 flag support

2019-05-14 Thread Serge Semin
The driver currently sets the echo suppression bit by default when rs485 is enabled. Naturally it disables any data retrieval in rs485 mode while RTSn is pushed up. The receiver gate (RX_) can be enabled just by clearing (or not setting) the EchoSuprs bit of mode2 register. So by setting or clearin

[PATCH 7/7] tty: max310x: Split uart characters insertion loop

2019-05-14 Thread Serge Semin
Batch read mode doesn't check any conditions or flags except the Rx overflow one. But it may only happen after the last character is pushed into the RHR register. In this case we shouldn't push all the read characters with overrun flag set, but only the last one caused the FIFO overflow. This commi

Re: [PATCH stable 4.9] powerpc/lib: fix code patching during early init on PPC32

2019-05-14 Thread Michael Ellerman
Christophe Leroy writes: > [Backport of upstream commit b45ba4a51cde29b2939365ef0c07ad34c8321789] > > On powerpc32, patch_instruction() is called by apply_feature_fixups() > which is called from early_init() > > There is the following note in front of early_init(): > * Note that the kernel may be

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Gautham R Shenoy
Hi Michael, On Tue, May 14, 2019 at 05:00:19PM +1000, Michael Ellerman wrote: > "Gautham R. Shenoy" writes: > > From: "Gautham R. Shenoy" > > > > During a memory hotplug operations involving resizing of the HPT, we > > invoke a stop_machine() to perform the resizing. In this code path, we > > en

Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock acquisition in resize_hpt

2019-05-14 Thread Gautham R Shenoy
On Tue, May 14, 2019 at 05:02:16PM +1000, Michael Ellerman wrote: > "Gautham R. Shenoy" writes: > > From: "Gautham R. Shenoy" > > > > Subject: Re: [RESEND PATCH] powerpc/pseries: Fix cpu_hotplug_lock > > acquisition in resize_hpt > > ps. A "RESEND" implies the patch is unchanged and you're just

Re: [PATCH 0/3] arm64: dts: meson: g12a: add mmc B and C

2019-05-14 Thread Neil Armstrong
On 14/05/2019 11:16, Jerome Brunet wrote: > This patchset adds the MMC controller B and C to the g12a SoC as well > as the u200 and sei510 boards. > > MMC controller A has been left out on purpose. This controller is > special on this SoC family and will be added later on. > > Notice the use of t

Re: [PATCH] arm64: dts: meson: g12a: set uart_ao clocks

2019-05-14 Thread Neil Armstrong
On 14/05/2019 11:45, Jerome Brunet wrote: > Now that the AO clock controller is available, make the uarts of the > always-on domain claim the appropriate peripheral clock. > > Signed-off-by: Jerome Brunet > --- > arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 4 ++-- > 1 file changed, 2 insertion

Re: [RFC KVM 19/27] kvm/isolation: initialize the KVM page table with core mappings

2019-05-14 Thread Alexandre Chartre
On 5/13/19 6:47 PM, Alexandre Chartre wrote: On 5/13/19 5:50 PM, Dave Hansen wrote: +    /* + * Copy the mapping for all the kernel text. We copy at the PMD + * level since the PUD is shared with the module mapping space. + */ +    rv = kvm_copy_mapping((void *)__START_KERNEL_map

[GIT PULL] MFD for v5.2

2019-05-14 Thread Lee Jones
Enjoy! The following changes since commit e93c9c99a629c61837d5a7fc2120cd2b6c70dbdd: Linux 5.1 (2019-05-05 17:42:58 -0700) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git tags/mfd-next-5.2 for you to fetch changes up to ed835136ee679dc528333

Re: [PATCH v20 00/28] Intel SGX1 support

2019-05-14 Thread Jarkko Sakkinen
On Mon, May 13, 2019 at 01:29:26PM +0300, Jarkko Sakkinen wrote: > I did study through SDK's file format and realized that it does not > does make sense after all to embed one. > > To implement it properly you would probably need a new syscall (lets say > sgx_load_enclave) and also that enclaves a

Re: [PATCH 2/2] scsi: libsas: delete sas port if expander discover failed

2019-05-14 Thread John Garry
On 14/05/2019 03:42, Jason Yan wrote: The sas_port(phy->port) allocated in sas_ex_discover_expander() will not be deleted when the expander failed to discover. This will cause resource leak and a further issue of kernel BUG like below: [159785.843156] port-2:17:29: trying to add phy phy-2:17:29

Re: [PATCH 2/2] serial: 8250: Add support for 8250/16550 as MFD function

2019-05-14 Thread Lee Jones
On Tue, 14 May 2019, Esben Haabendal wrote: > Lee Jones writes: > > > On Tue, 07 May 2019, Esben Haabendal wrote: > > > >> Lee Jones writes: > >> > >> > On Fri, 26 Apr 2019, Esben Haabendal wrote: > >> > > >> >> The serial8250-mfd driver is for adding 8250/16550 UART ports as > >> >> function

[GIT PULL] Backlight for v5.2

2019-05-14 Thread Lee Jones
Enjoy! The following changes since commit 9e98c678c2d6ae3a17cb2de55d17f69dddaa231b: Linux 5.1-rc1 (2019-03-17 14:22:26 -0700) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight.git tags/backlight-next-5.2 for you to fetch changes up to 8fbc

[PATCH v2] EDAC, mc: Fix edac_mc_find() in case no device is found

2019-05-14 Thread Robert Richter
The function should return NULL in case no device is found, but it always returns the last checked mc device from the list even if the index did not match. This patch fixes this. I did some analysis why this did not raise any issues for about 3 years and the reason is that edac_mc_find() is mostly

[PATCH v2] tools/perf/util: null-terminate version char array upon error

2019-05-14 Thread Donald Yandt
If fgets fails due to any other error besides end-of-file, the version char array may not even be null-terminated. Signed-off-by: Donald Yandt --- tools/perf/util/machine.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/perf/util/machine.c b/tools/perf/util/machine.

Re: [PATCH] driver core: Fix use-after-free and double free on glue directory

2019-05-14 Thread Mukesh Ojha
++ On 5/4/2019 8:17 PM, Muchun Song wrote: Benjamin Herrenschmidt 于2019年5月2日周四 下午2:25写道: The basic idea yes, the whole bool *locked is horrid though. Wouldn't it work to have a get_device_parent_locked that always returns with the mutex held, or just move the mutex to the caller or something

[PATCH] usb: cp210x: Add cp2108 GPIOs support

2019-05-14 Thread Serge Semin
Each chip from the cp210x series got GPIOs on board. This commit provides the support for sixteen ones placed on the cp2108 four-ports serial console controller. All of the GPIOs are equally distributed to four USB interfaces in accordance with GPIOs alternative functions attachment. cp2108 GPIOs

Re: [PATCH] driver core: Fix use-after-free and double free on glue directory

2019-05-14 Thread Prateek Sood
On 5/14/19 4:26 PM, Mukesh Ojha wrote: > ++ > > On 5/4/2019 8:17 PM, Muchun Song wrote: >> Benjamin Herrenschmidt 于2019年5月2日周四 下午2:25写道: >> > The basic idea yes, the whole bool *locked is horrid though. > Wouldn't it > work to have a get_device_parent_locked that always returns with >

Re: [PATCH 3/3] KVM: LAPIC: Optimize timer latency further

2019-05-14 Thread Wanpeng Li
On Tue, 14 May 2019 at 09:45, Wanpeng Li wrote: > > On Tue, 14 May 2019 at 03:54, Sean Christopherson > wrote: > > > > On Thu, May 09, 2019 at 07:29:21PM +0800, Wanpeng Li wrote: > > > From: Wanpeng Li > > > > > > Advance lapic timer tries to hidden the hypervisor overhead between host > > > tim

Re: ext3/ext4 filesystem corruption under post 5.1.0 kernels

2019-05-14 Thread Ondrej Zary
On Tuesday 14 May 2019, Arthur Marsh wrote: > Apologies, I had forgotten to > > got bisect - - hard origin/master > > I am still seeing the corruption leading to the invalid block error on 5.1.0+ > kernels on both my machines. > > Arthur. I've been probably hit by the same bug. ext3 filesyste

Re: Linux 5.1 on APU runs in circles with Call Traces

2019-05-14 Thread Marc Haber
On Sun, May 12, 2019 at 09:32:03PM +0200, Marc Haber wrote: > I regret to inform you that I have now the third crippling issue in > Linux 5.1, with the fourth one in the process of being isolated. I had GPIOLIB missing in my kernel configuration. That was not autodetected and resulted just in a bu

Re: [PATCH] powerpc/powernv/npu: Fix reference leak

2019-05-14 Thread Michael Ellerman
Greg Kurz writes: > Michael, > > Any comments on this patch ? Should I repost with a shorter comment > as suggested by Alexey ? No the longer comment seems fine to me. I'm not a big fan of the patch, it's basically a hack :) But for a backportable fix I guess it is OK. I would be happier thoug

[PATCH 6/8] arm64: dts: meson: g12a: add pdm

2019-05-14 Thread Jerome Brunet
Add the pdm device node and the pinctrl definition for this capture interface g12a SoC family Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 177 1 file changed, 177 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/ar

[PATCH 0/8] arm64: dts: meson: g12a: add audio devices

2019-05-14 Thread Jerome Brunet
This patchset adds audio related devices to g12a SoC family. It adds the clock controller as well as the memory, tdm, spdif and pdm interfaces. At this stage, the HDMI and internal audio DAC are still missing. Notice the use of the pinconf DT property 'drive-strength-microamp'. Support for this p

[PATCH 8/8] arm64: dts: meson: g12a: enable hdmi_tx sound dai provider

2019-05-14 Thread Jerome Brunet
At the moment the sysnopsys hdmi i2s driver provides a single playback DAI. Add the corresponding sound-dai-cell to the hdmi device node. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/boot/dts/amlogic/m

Re: [PATCH v4 1/2] media: v4l2-subdev: Verify arguments of v4l2_subdev_call()

2019-05-14 Thread Sakari Ailus
Hi Janusz, On Sat, May 11, 2019 at 12:10:30PM +0200, Janusz Krzysztofik wrote: > Correctness of format type (try or active) and pad number parameters > passed to subdevice operation callbacks is now verified only for IOCTL > calls. However, those callbacks are also used by drivers, e.g., V4L2 > h

Re: [PATCH v4 1/2] media: v4l2-subdev: Verify arguments of v4l2_subdev_call()

2019-05-14 Thread Sakari Ailus
On Sat, May 11, 2019 at 12:10:30PM +0200, Janusz Krzysztofik wrote: > +static int check_get_fmt(struct v4l2_subdev *sd, > + struct v4l2_subdev_pad_config *cfg, > + struct v4l2_subdev_format *format) > +{ > + return check_format(sd, format) ? : > +

[PATCH 5/8] arm64: dts: meson: g12a: add spdifouts

2019-05-14 Thread Jerome Brunet
Add the devices nodes and pinctrl definitions for the spdif outputs of the g12a SoC family Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 60 + 1 file changed, 60 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/a

[PATCH 3/8] arm64: dts: meson: g12a: add audio fifos

2019-05-14 Thread Jerome Brunet
Add the playback and capture memory interfaces of the g12a SoC family. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 67 + 1 file changed, 67 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm64/boot/dts/amlogi

[PATCH 4/8] arm64: dts: meson: g12a: add tdm

2019-05-14 Thread Jerome Brunet
Add the devices and pinctrl definitions for the tdm interfaces of the g12a SoC family. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 658 1 file changed, 658 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm6

[PATCH 1/8] arm64: dts: meson: g12a: add audio clock controller

2019-05-14 Thread Jerome Brunet
Add the g12a clock controller dedicated to audio. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 36 + 1 file changed, 36 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi ind

[PATCH 2/8] arm64: dts: meson: g12a: add audio memory arbitrer

2019-05-14 Thread Jerome Brunet
Add the audio DDR memory arbitrer of the g12a SoC family. Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 9 + 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi b/arch/arm64/boot/dts/amlogic/meson-g12a.dtsi index 09a

[PATCH 7/8] arm64: dts: meson: g12a: add spdifin

2019-05-14 Thread Jerome Brunet
Add the spdif input device node and the pinctrl definition for this capture interface g12a SoC family Signed-off-by: Jerome Brunet --- arch/arm64/boot/dts/amlogic/meson-g12a.dtsi | 37 + 1 file changed, 37 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a.dts

Re: [PATCH RT v2] Fix a lockup in wait_for_completion() and friends

2019-05-14 Thread Peter Zijlstra
On Tue, May 14, 2019 at 11:12:19AM +0200, Sebastian Andrzej Siewior wrote: > On 2019-05-14 10:43:56 [+0200], Peter Zijlstra wrote: > > Now.. that will fix it, but I think it is also wrong. > > > > The problem being that it violates FIFO, something that might be more > > important on -RT than elsew

Re: [PATCH 2/2] scsi: libsas: delete sas port if expander discover failed

2019-05-14 Thread Jason Yan
On 2019/5/14 18:45, John Garry wrote: On 14/05/2019 03:42, Jason Yan wrote: The sas_port(phy->port) allocated in sas_ex_discover_expander() will not be deleted when the expander failed to discover. This will cause resource leak and a further issue of kernel BUG like below: [159785.843156]  p

Re: [v2 PATCH] mm: mmu_gather: remove __tlb_reset_range() for force flush

2019-05-14 Thread Peter Zijlstra
On Tue, May 14, 2019 at 02:01:34AM +, Nadav Amit wrote: > > diff --git a/mm/mmu_gather.c b/mm/mmu_gather.c > > index 99740e1dd273..cc251422d307 100644 > > --- a/mm/mmu_gather.c > > +++ b/mm/mmu_gather.c > > @@ -251,8 +251,9 @@ void tlb_finish_mmu(struct mmu_gather *tlb, > > * forcefully

Re: [PATCH 2/2] scsi: libsas: delete sas port if expander discover failed

2019-05-14 Thread John Garry
On 14/05/2019 12:37, Jason Yan wrote: On 2019/5/14 18:45, John Garry wrote: On 14/05/2019 03:42, Jason Yan wrote: The sas_port(phy->port) allocated in sas_ex_discover_expander() will not be deleted when the expander failed to discover. This will cause resource leak and a further issue of kern

Re: [v2 PATCH] mm: mmu_gather: remove __tlb_reset_range() for force flush

2019-05-14 Thread Peter Zijlstra
On Tue, May 14, 2019 at 07:21:33AM +, Nadav Amit wrote: > > On May 14, 2019, at 12:15 AM, Jan Stancek wrote: > > Replacing fullmm with need_flush_all, brings the problem back / reproducer > > hangs. > > Maybe setting need_flush_all does not have the right effect, but setting > fullmm and th

Re: [PATCH] driver core: Fix use-after-free and double free on glue directory

2019-05-14 Thread Muchun Song
Prateek Sood 于2019年5月14日周二 下午7:00写道: > > On 5/14/19 4:26 PM, Mukesh Ojha wrote: > > ++ > > > > On 5/4/2019 8:17 PM, Muchun Song wrote: > >> Benjamin Herrenschmidt 于2019年5月2日周四 下午2:25写道: > >> > > The basic idea yes, the whole bool *locked is horrid though. > > Wouldn't it > > work to h

Re: [v2 PATCH] mm: mmu_gather: remove __tlb_reset_range() for force flush

2019-05-14 Thread Peter Zijlstra
On Mon, May 13, 2019 at 05:38:04PM +0100, Will Deacon wrote: > On Fri, May 10, 2019 at 07:26:54AM +0800, Yang Shi wrote: > > diff --git a/mm/mmu_gather.c b/mm/mmu_gather.c > > index 99740e1..469492d 100644 > > --- a/mm/mmu_gather.c > > +++ b/mm/mmu_gather.c > > @@ -245,14 +245,39 @@ void tlb_finish

Re: [PATCH v2 0/3] initramfs: add support for xattrs in the initial ram disk

2019-05-14 Thread Roberto Sassu
On 5/14/2019 8:06 AM, Rob Landley wrote: On 5/13/19 7:47 AM, Roberto Sassu wrote: On 5/13/2019 11:07 AM, Rob Landley wrote: Wouldn't the below work even before enforcing signatures on external initramfs: 1. Create an embedded initramfs with an /init that does the xattr parsing/setting. This wil

Re: [PATCH v5 2/4] media: v4l2-subdev: WARN_ON invalid v4l2_subdev_call() arguments

2019-05-14 Thread Hans Verkuil
On 5/12/19 10:15 PM, Janusz Krzysztofik wrote: > Invalid arguments passed to v4l2_subdev_call generally mean bugs. Be > noisy if that happens. > > Signed-off-by: Janusz Krzysztofik > --- > drivers/media/v4l2-core/v4l2-subdev.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > >

Re: [PATCH v5 1/4] media: v4l2-subdev: Verify arguments in v4l2_subdev_call()

2019-05-14 Thread Hans Verkuil
On 5/12/19 10:15 PM, Janusz Krzysztofik wrote: > Correctness of format type (try or active) and pad ID parameters passed > to subdevice operation callbacks is now verified only for IOCTL calls. > However, those callbacks are also used by drivers, e.g., V4L2 host > interfaces. > > Since both subdev

Re: [PATCH v2 3/5] arm64: Fix incorrect irqflag restore for priority masking

2019-05-14 Thread Robin Murphy
On 14/05/2019 10:25, Julien Thierry wrote: [...] +static inline int arch_irqs_disabled_flags(unsigned long flags) +{ + int res; + + asm volatile(ALTERNATIVE( + "and %w0, %w1, #" __stringify(PSR_I_BIT) "\n" + "nop", + "cmp %w1, #" _

Re: [v2 PATCH] mm: mmu_gather: remove __tlb_reset_range() for force flush

2019-05-14 Thread Will Deacon
On Tue, May 14, 2019 at 01:52:23PM +0200, Peter Zijlstra wrote: > On Mon, May 13, 2019 at 05:38:04PM +0100, Will Deacon wrote: > > On Fri, May 10, 2019 at 07:26:54AM +0800, Yang Shi wrote: > > > diff --git a/mm/mmu_gather.c b/mm/mmu_gather.c > > > index 99740e1..469492d 100644 > > > --- a/mm/mmu_ga

Re: [PATCH] serial: 8250: Add support for using platform_device resources

2019-05-14 Thread Esben Haabendal
Andy Shevchenko writes: > On Tue, May 14, 2019 at 12:23 PM Andy Shevchenko > wrote: >> On Tue, May 14, 2019 at 10:24 AM Esben Haabendal wrote: > >> > Please take a look at https://lkml.org/lkml/2019/4/9/576 >> > ("[PATCH v2 2/4] mfd: ioc3: Add driver for SGI IOC3 chip") >> >> Thank you for this

Re: [PATCH 01/17] locking/lockdep: Add lock type enum to explicitly specify read or write locks

2019-05-14 Thread Peter Zijlstra
On Tue, May 14, 2019 at 09:31:48AM +0800, Yuyang Du wrote: > Thanks for review. > > On Mon, 13 May 2019 at 19:45, Peter Zijlstra wrote: > > > > On Mon, May 13, 2019 at 05:11:47PM +0800, Yuyang Du wrote: > > > + * Note that we have an assumption that a lock class cannot ever be both > > > + * read

Re: [PATCH v10 09/12] ima: Implement support for module-style appended signatures

2019-05-14 Thread Mimi Zohar
Hi Thiago, On Thu, 2019-04-18 at 00:51 -0300, Thiago Jung Bauermann wrote: > > @@ -326,6 +356,10 @@ int ima_appraise_measurement(enum ima_hooks func, > case INTEGRITY_UNKNOWN: > break; > case INTEGRITY_NOXATTRS:/* No EVM protected xattrs. */ > +

Re: [PATCH] serial: 8250: Add support for using platform_device resources

2019-05-14 Thread Esben Haabendal
Andy Shevchenko writes: > On Tue, May 14, 2019 at 10:24 AM Esben Haabendal wrote: >> Andy Shevchenko writes: >> > On Tue, May 07, 2019 at 02:22:18PM +0200, Esben Haabendal wrote: > >> We are on repeat here. I don't agree with you here. I have a simple >> generic 8250 (16550A) compatible devic

Re: [PATCH RT v2] Fix a lockup in wait_for_completion() and friends

2019-05-14 Thread Corey Minyard
On Tue, May 14, 2019 at 11:12:19AM +0200, Sebastian Andrzej Siewior wrote: > On 2019-05-14 10:43:56 [+0200], Peter Zijlstra wrote: > > Now.. that will fix it, but I think it is also wrong. > > > > The problem being that it violates FIFO, something that might be more > > important on -RT than elsew

Re: [PATCH] x86/build: Move _etext to actual end of .text

2019-05-14 Thread Johannes Hirte
On 2019 Apr 23, Kees Cook wrote: > When building x86 with Clang LTO and CFI, CFI jump regions are > automatically added to the end of the .text section late in linking. As a > result, the _etext position was being labelled before the appended jump > regions, causing confusion about where the bounda

Re: [PATCH v2] media/doc: Allow sizeimage to be set by v4l clients

2019-05-14 Thread Nicolas Dufresne
Le mardi 14 mai 2019 à 10:54 +0200, Hans Verkuil a écrit : > Hi Stanimir, > > On 4/12/19 5:59 PM, Stanimir Varbanov wrote: > > This changes v4l2_pix_format and v4l2_plane_pix_format sizeimage > > field description to allow v4l clients to set bigger image size > > in case of variable length compres

Re: [PATCH] mm/slub: avoid double string traverse in kmem_cache_flags()

2019-05-14 Thread Aaron Tomlin
On Tue 2019-04-30 22:31 -0700, Yury Norov wrote: > If ',' is not found, kmem_cache_flags() calls strlen() to find the end > of line. We can do it in a single pass using strchrnul(). > > Signed-off-by: Yury Norov > --- > mm/slub.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > di

Re: [PATCH v2] media/doc: Allow sizeimage to be set by v4l clients

2019-05-14 Thread Hans Verkuil
On 5/14/19 2:19 PM, Nicolas Dufresne wrote: > Le mardi 14 mai 2019 à 10:54 +0200, Hans Verkuil a écrit : >> Hi Stanimir, >> >> On 4/12/19 5:59 PM, Stanimir Varbanov wrote: >>> This changes v4l2_pix_format and v4l2_plane_pix_format sizeimage >>> field description to allow v4l clients to set bigger i

Re: [PATCH 2/2] serial: 8250: Add support for 8250/16550 as MFD function

2019-05-14 Thread Greg Kroah-Hartman
On Tue, May 14, 2019 at 11:47:41AM +0100, Lee Jones wrote: > On Tue, 14 May 2019, Esben Haabendal wrote: > > > Lee Jones writes: > > > > > On Tue, 07 May 2019, Esben Haabendal wrote: > > > > > >> Lee Jones writes: > > >> > > >> > On Fri, 26 Apr 2019, Esben Haabendal wrote: > > >> > > > >> >> T

Re: [RFC Patch] perf_event: fix a cgroup switch warning

2019-05-14 Thread Peter Zijlstra
On Mon, May 13, 2019 at 05:27:47PM -0700, Cong Wang wrote: > We have been consistently triggering the warning > WARN_ON_ONCE(cpuctx->cgrp) in perf_cgroup_switch() for a rather > long time, although we still have no clue on how to reproduce it. > > Looking into the code, it seems the only possibili

Re: [PATCH 5/5] IB/hfi1: Fix improper uses of smp_mb__before_atomic()

2019-05-14 Thread Dennis Dalessandro
On 5/9/2019 5:12 PM, Andrea Parri wrote: On Tue, Apr 30, 2019 at 01:16:57AM +0200, Andrea Parri wrote: Hi Mike, This barrier only applies to the read-modify-write operations; in particular, it does not apply to the atomic_read() primitive. Replace the barrier with an smp_mb(). This is one o

Re: [PATCH] serial: 8250: Add support for using platform_device resources

2019-05-14 Thread Andy Shevchenko
On Tue, May 14, 2019 at 02:02:36PM +0200, Esben Haabendal wrote: > Andy Shevchenko writes: > > On Tue, May 14, 2019 at 10:24 AM Esben Haabendal wrote: > >> Andy Shevchenko writes: > >> > On Tue, May 07, 2019 at 02:22:18PM +0200, Esben Haabendal wrote: > > > >> We are on repeat here. I don't agr

Re: [PATCH 2/2] serial: 8250: Add support for 8250/16550 as MFD function

2019-05-14 Thread Esben Haabendal
Greg Kroah-Hartman writes: > On Tue, May 14, 2019 at 11:47:41AM +0100, Lee Jones wrote: >> On Tue, 14 May 2019, Esben Haabendal wrote: >> >> > Lee Jones writes: >> > >> > > On Tue, 07 May 2019, Esben Haabendal wrote: >> > > >> > >> Lee Jones writes: >> > >> >> > >> > On Fri, 26 Apr 2019, Esb

Re: [PATCH] serial: 8250: Add support for using platform_device resources

2019-05-14 Thread Andy Shevchenko
On Tue, May 14, 2019 at 02:02:40PM +0200, Esben Haabendal wrote: > Andy Shevchenko writes: > > > On Tue, May 14, 2019 at 12:23 PM Andy Shevchenko > > wrote: > >> On Tue, May 14, 2019 at 10:24 AM Esben Haabendal > >> wrote: > > > >> > Please take a look at https://lkml.org/lkml/2019/4/9/576 > >

Re: [PATCH v2 v2 1/3] dt-bindings: i2c: extend existing opencore bindings.

2019-05-14 Thread Sagar Kadam
Hello Rob, Thank you for the review. On Tue, May 14, 2019 at 2:26 AM Rob Herring wrote: > > On Tue, May 07, 2019 at 08:45:06PM +0530, Sagar Shrikant Kadam wrote: > > Add FU540-C000 specific device tree bindings to already > > available i2-ocores file. This device is available on > > HiFive Unlea

Re: [PATCH] perf vendor events intel: Add uncore_upi JSON support

2019-05-14 Thread Arnaldo Carvalho de Melo
Em Mon, May 13, 2019 at 05:29:30PM -0400, Liang, Kan escreveu: > Hi Arnaldo, > > Could you please apply this fix? Sure, please next time specify which arch this should be tested on, as I tried it here on a skylake notebook (lenovo t480s) before your patch and got: [root@quaco ~]# perf stat -e UP

[PATCH] scsi: aic7xxx: Remove NULL check before kfree()

2019-05-14 Thread Quentin Deslandes
Fix the following coccinelle warning by removing NULL check before calling kfree(): NULL check before some freeing functions in not needed. Signed-off-by: Quentin Deslandes --- drivers/scsi/aic7xxx/aic7xxx_core.c | 16 +--- 1 file changed, 5 insertions(+), 11 deletions(-) diff --gi

Re: [PATCH v2 v2 1/3] dt-bindings: i2c: extend existing opencore bindings.

2019-05-14 Thread Andrew Lunn
> > > + */ > > > + i2c@1003 { > > > + compatible = "sifive,i2c0","sifive,fu540-c000-i2c"; > > > + reg = <0x0 0x1003 0x0 0x1000>; > > > + reg-names = "i2c-control"; > > > > Not doucmented. > In v1, I had added a new binding

Re: [PATCH] powerpc/powernv/npu: Fix reference leak

2019-05-14 Thread Greg Kurz
On Tue, 14 May 2019 21:13:40 +1000 Michael Ellerman wrote: > Greg Kurz writes: > > Michael, > > > > Any comments on this patch ? Should I repost with a shorter comment > > as suggested by Alexey ? > > No the longer comment seems fine to me. > > I'm not a big fan of the patch, it's basically

Re: [PATCH v11 1/4] MAINTAINERS: add an entry for for arm63 imx devicetrees

2019-05-14 Thread Fabio Estevam
On Mon, May 13, 2019 at 5:23 PM Angus Ainslie (Purism) wrote: > > Add an explicit reference to imx* devicetrees > > Signed-off-by: Angus Ainslie (Purism) There is a typo in the Subject: "arm63" --> "arm64". Reviewed-by: Fabio Estevam

Re: [PATCH v2 3/5] arm64: Fix incorrect irqflag restore for priority masking

2019-05-14 Thread Julien Thierry
On 14/05/2019 13:01, Robin Murphy wrote: > On 14/05/2019 10:25, Julien Thierry wrote: > [...] +static inline int arch_irqs_disabled_flags(unsigned long flags) +{ +    int res; + +    asm volatile(ALTERNATIVE( +    "and    %w0, %w1, #" __stringify(PSR_I_BIT) "\n"

Re: [PATCH v11 2/4] arm64: dts: fsl: librem5: Add a device tree for the Librem5 devkit

2019-05-14 Thread Fabio Estevam
On Mon, May 13, 2019 at 5:23 PM Angus Ainslie (Purism) wrote: > > This is for the development kit board for the Librem 5. The current level > of support yields a working console and is able to boot userspace from > the network or eMMC. > > Additional subsystems that are active : > > - Both USB por

Re: [PATCH, RFC 2/2] Implement sharing/unsharing of PMDs for FS/DAX

2019-05-14 Thread Kirill A. Shutemov
On Thu, May 09, 2019 at 09:05:33AM -0700, Larry Bassel wrote: > This is based on (but somewhat different from) what hugetlbfs > does to share/unshare page tables. > > Signed-off-by: Larry Bassel > --- > include/linux/hugetlb.h | 4 ++ > mm/huge_memory.c| 32 ++ > mm/hugetl

Re: [PATCH v4] x86/mm/KASLR: Fix the size of vmemmap section

2019-05-14 Thread Kirill A. Shutemov
On Wed, May 08, 2019 at 05:35:20PM +0800, Baoquan He wrote: > On 05/08/19 at 11:04am, Borislav Petkov wrote: > > On Wed, May 08, 2019 at 04:24:18PM +0800, Baoquan He wrote: > > > I think this's worth noticing stable tree: > > > > > > Cc: sta...@vger.kernel.org > > > > Fixes: ? > > Not sure which

[PATCH RFC v2 4/4] mm/ksm: add force merging/unmerging documentation

2019-05-14 Thread Oleksandr Natalenko
Document respective sysfs knob. Signed-off-by: Oleksandr Natalenko --- Documentation/admin-guide/mm/ksm.rst | 11 +++ 1 file changed, 11 insertions(+) diff --git a/Documentation/admin-guide/mm/ksm.rst b/Documentation/admin-guide/mm/ksm.rst index 9303786632d1..4302b92910ec 100644 --- a/

[PATCH RFC v2 0/4] mm/ksm: add option to automerge VMAs

2019-05-14 Thread Oleksandr Natalenko
By default, KSM works only on memory that is marked by madvise(). And the only way to get around that is to either: * use LD_PRELOAD; or * patch the kernel with something like UKSM or PKSM. Instead, lets implement a sysfs knob, which allows marking VMAs as mergeable. This can be used manually

[PATCH RFC v2 3/4] mm/ksm: introduce force_madvise knob

2019-05-14 Thread Oleksandr Natalenko
Present a new sysfs knob to mark task's anonymous memory as mergeable. To force merging task's VMAs, its PID is echoed in a write-only file: # echo PID > /sys/kernel/mm/ksm/force_madvise Force unmerging is done similarly, but with "minus" sign: # echo -PID > /sys/kernel/mm/ksm/force_madvi

Re: [PATCH, RFC 0/2] Share PMDs for FS/DAX on x86

2019-05-14 Thread Kirill A. Shutemov
On Thu, May 09, 2019 at 09:05:31AM -0700, Larry Bassel wrote: > This patchset implements sharing of page table entries pointing > to 2MiB pages (PMDs) for FS/DAX on x86. -EPARSE. How do you share entries? Entries do not take any space, page tables that cointain these entries do. Have you checked

[PATCH RFC v2 1/4] mm/ksm: introduce ksm_enter() helper

2019-05-14 Thread Oleksandr Natalenko
Move MADV_MERGEABLE part of ksm_madvise() into a dedicated helper since it will be further used for marking VMAs to be merged forcibly. This does not bring any functional changes. Signed-off-by: Oleksandr Natalenko --- mm/ksm.c | 60 +--- 1 fi

Re: 5.1 kernel: khugepaged stuck at 100%

2019-05-14 Thread Kirill A. Shutemov
On Thu, May 09, 2019 at 05:54:56AM -0400, Justin Piszcz wrote: > Hello, > > Kernel: 5.1 (self-compiled, no modules) > Arch: x86_64 > Distro: Debian Testing > > Issue: I was performing a dump of ext3 and ext4 filesystems and then > restoring them to a separate volume (testing)-- afterwards I notic

[PATCH RFC v2 2/4] mm/ksm: introduce ksm_leave() helper

2019-05-14 Thread Oleksandr Natalenko
Move MADV_UNMERGEABLE part of ksm_madvise() into a dedicated helper since it will be further used for unmerging VMAs forcibly. This does not bring any functional changes. Signed-off-by: Oleksandr Natalenko --- mm/ksm.c | 32 ++-- 1 file changed, 22 insertions(+), 10

Re: [PATCH RFC v2 3/4] mm/ksm: introduce force_madvise knob

2019-05-14 Thread Aaron Tomlin
On Tue 2019-05-14 15:16 +0200, Oleksandr Natalenko wrote: > Present a new sysfs knob to mark task's anonymous memory as mergeable. > > To force merging task's VMAs, its PID is echoed in a write-only file: > ># echo PID > /sys/kernel/mm/ksm/force_madvise > > Force unmerging is done similarly,

Re: [PATCH 2/3 v5] add a new template field buf to contain the buffer

2019-05-14 Thread Roberto Sassu
On 5/14/2019 7:07 AM, prakhar srivastava wrote: On Mon, May 13, 2019 at 6:48 AM Roberto Sassu wrote: On 5/11/2019 12:37 AM, Prakhar Srivastava wrote: From: Prakhar Srivastava The buffer(cmdline args) added to the ima log cannot be attested without having the actual buffer. Thus to make the

[PATCH v12 1/4] MAINTAINERS: add an entry for for arm64 imx devicetrees

2019-05-14 Thread Angus Ainslie (Purism)
Add an explicit reference to imx* devicetrees Signed-off-by: Angus Ainslie (Purism) Reviewed-by: Fabio Estevam --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 7707c28628b9..9fc30f82ab81 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -1624,6 +16

<    1   2   3   4   5   6   7   >