[PATCH v2 6/6] x86/entry: Fix NMI vs IRQ state tracking

2020-05-28 Thread Peter Zijlstra
While the nmi_enter() users did trace_hardirqs_{off_prepare,on_finish}() there was no matching lockdep_hardirqs_*() calls to complete the picture. Introduce idtentry_{enter,exit}_nmi() to enable proper IRQ state tracking across the NMIs. Signed-off-by: Peter Zijlstra (Intel) --- arch/x86/entry/

[PATCH v2 2/6] x86/entry: Rename trace_hardirqs_off_prepare()

2020-05-28 Thread Peter Zijlstra
The typical pattern for trace_hardirqs_off_prepare() is: ENTRY lockdep_hardirqs_off(); // because hardware ... do entry magic instrumentation_begin(); trace_hardirqs_off_prepare(); ... do actual work trace_hardirqs_on_prepare(); lockdep_hardirqs_on_prepare(); inst

Re: [PATCH 0/3] make vm_committed_as_batch aware of vm overcommit policy

2020-05-28 Thread Qian Cai
] LTP: starting oom01 [ 3160.306977][T106365] KK as:-59683 as_sum:6896 check:-32768 batch:256 [ 3160.307161][T106365] [ cut here ] [ 3160.307184][T106365] memory commitment underflow [ 3160.307216][T106365] WARNING: CPU: 103 PID: 106365 at mm/util.c:858 __vm_eno

Re: [PATCH v4 03/36] mm: Allow hpages to be arbitrary order

2020-05-28 Thread Zi Yan
On 15 May 2020, at 9:16, Matthew Wilcox wrote: > From: "Matthew Wilcox (Oracle)" > > Remove the assumption in hpage_nr_pages() that compound pages are > necessarily PMD sized. Move the relevant parts of mm.h to before the > include of huge_mm.h so we can use an inline function rather than a macr

Re: [PATCH v2] x86/tsc: Allow quick PIT calibration despite interruptions

2020-05-28 Thread Guilherme G. Piccoli
Hi Jan and all involved here, I'd like to know if there was any news on this patch - seems users are still facing this issue on AMD systems. Thanks in advance, Guilherme

Re: [PATCH v3 03/10] dmaengine: Introduce min burst length capability

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:14AM +0300, Serge Semin wrote: > Some hardware aside from default 0/1 may have greater minimum burst > transactions length constraints. Here we introduce the DMA device > and slave capability, which if required can be initialized by the DMA > engine driver with the dev

Re: [PATCH 1/2] dt-bindings: sound: tlv320adcx140: Add GPI config property

2020-05-28 Thread Dan Murphy
Rob On 5/28/20 9:05 AM, Rob Herring wrote: On Tue, May 26, 2020 at 03:09:16PM -0500, Dan Murphy wrote: Add an array property that configures the General Purpose Input (GPI) register. The device has 4 GPI pins and each pin can be configured in 1 of 7 different ways. Dan seems to have trouble r

Re: [PATCH 0/8] R8A7742 add support for HSUSB and USB2.0/3.0

2020-05-28 Thread Lorenzo Pieralisi
On Sun, May 24, 2020 at 10:37:49PM +0100, Lad Prabhakar wrote: > Hi All, > > This patch series adds support for HSUSB, USB2.0 and USB3.0 to > R8A7742 SoC DT. > > This patch series applies on-top of [1]. > > [1] https://patchwork.kernel.org/project/linux-renesas-soc/list/?series=288491 I think G

[PATCH] clk: qcom: Add missing msm8998 ufs_unipro_core_clk_src

2020-05-28 Thread Jeffrey Hugo
ufs_unipro_core_clk_src is required to allow UFS to clock scale for power savings. Fixes: b5f5f525c547 ("clk: qcom: Add MSM8998 Global Clock Control (GCC) driver") Signed-off-by: Jeffrey Hugo --- drivers/clk/qcom/gcc-msm8998.c | 27 include/dt-bindings/clock/qc

[PATCH v2 0/2] regmap: provide simple bitops and use them in a driver

2020-05-28 Thread Bartosz Golaszewski
From: Bartosz Golaszewski I noticed that oftentimes I use regmap_update_bits() for simple bit setting or clearing. In this case the fourth argument is superfluous as it's always 0 or equal to the mask argument. This series proposes to add simple bit operations for setting, clearing and testing s

[PATCH v2 2/2] net: ethernet: mtk-star-emac: use regmap bitops

2020-05-28 Thread Bartosz Golaszewski
From: Bartosz Golaszewski Shrink the code visually by replacing regmap_update_bits() with appropriate regmap bit operations where applicable. Signed-off-by: Bartosz Golaszewski --- drivers/net/ethernet/mediatek/mtk_star_emac.c | 80 --- 1 file changed, 35 insertions(+), 45 dele

[PATCH v2 1/2] regmap: provide helpers for simple bit operations

2020-05-28 Thread Bartosz Golaszewski
From: Bartosz Golaszewski In many instances regmap_update_bits() is used for simple bit setting and clearing. In these cases the last argument is redundant and we can hide it with a static inline function. This adds three new helpers for simple bit operations: set_bits, clear_bits and test_bits.

Re: [RFC 02/17] dma-fence: basic lockdep annotations

2020-05-28 Thread Daniel Vetter
On Thu, May 28, 2020 at 3:37 PM Thomas Hellström (Intel) wrote: > > On 2020-05-12 10:59, Daniel Vetter wrote: > > Design is similar to the lockdep annotations for workers, but with > > some twists: > > > > - We use a read-lock for the execution/worker/completion side, so that > >this explicit

Re: [PATCH v3 04/10] dmaengine: Introduce max SG list entries capability

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:15AM +0300, Serge Semin wrote: > Some devices may lack the support of the hardware accelerated SG list > entries automatic walking through and execution. In this case a burden of > the SG list traversal and DMA engine re-initialization lies on the > DMA engine driver (

Re: [RFC][PATCH 3/3] objtool: Add support for relocations without addends

2020-05-28 Thread Josh Poimboeuf
On Wed, May 27, 2020 at 09:42:33AM -0700, Matt Helsley wrote: > @@ -525,16 +556,8 @@ static int read_relocs(struct elf *elf) > return -1; > } > memset(reloc, 0, sizeof(*reloc)); > - > - if (!gelf_getrela(s

Re: [PATCH v3 0/8] kernel: taint when the driver firmware crashes

2020-05-28 Thread Luis Chamberlain
On Wed, May 27, 2020 at 02:36:42PM -0700, Jakub Kicinski wrote: > On Wed, 27 May 2020 03:19:18 + Luis Chamberlain wrote: > > I read your patch, and granted, I will accept I was under the incorrect > > assumption that this can only be used by networking devices, however it > > the devlink approa

[PATCH v4 0/3] hwmon: Add Baikal-T1 SoC Process, Voltage and Temp sensor support

2020-05-28 Thread Serge Semin
In order to keep track of Baikal-T1 SoC power consumption and make sure the chip heating is within the normal temperature limits, there is a dedicated hardware monitor sensor embedded into the SoC. It is based on the Analog Bits PVT sensor but equipped with a vendor-specific control wrapper, which

[PATCH v4 2/3] hwmon: Add notification support

2020-05-28 Thread Serge Semin
From: Guenter Roeck For hwmon drivers using the hwmon_device_register_with_info() API, it is desirable to have a generic notification mechanism available. This mechanism can be used to notify userspace as well as the thermal subsystem if the driver experiences any events, such as warning or criti

[PATCH v4 1/3] dt-bindings: hwmon: Add Baikal-T1 PVT sensor binding

2020-05-28 Thread Serge Semin
Baikal-T1 SoC is equipped with an embedded process, voltage and temperature sensor to monitor the chip internal environment like temperature, supply voltage and transistors performance. This bindings describes the external Baikal-T1 PVT control interfaces like MMIO registers space, interrupt reque

[PATCH v4 3/3] hwmon: Add Baikal-T1 PVT sensor driver

2020-05-28 Thread Serge Semin
Baikal-T1 SoC provides an embedded process, voltage and temperature sensor to monitor an internal SoC environment (chip temperature, supply voltage and process monitor) and on time detect critical situations, which may cause the system instability and even damages. The IP-block is based on the Anal

Re: [PATCH] perf script: Fix --call-trace for Intel PT

2020-05-28 Thread Arnaldo Carvalho de Melo
Em Wed, May 27, 2020 at 09:02:50PM +0300, Adrian Hunter escreveu: > Make process_attr() respect -F-ip, noting also that the condition in > process_attr() (callchain_param.record_mode != CALLCHAIN_NONE) is always > true so test the sample type directly. > > Example: > > Before: > > $ perf r

[PATCH] PCI: aardvark: Don't touch PCIe registers if no card connected

2020-05-28 Thread Pali Rohár
When there is no PCIe card connected and advk_pcie_rd_conf() or advk_pcie_wr_conf() is called for PCI bus which doesn't belong to emulated root bridge, the aardvark driver throws the following error message: advk-pcie d007.pcie: config read/write timed out Obviously accessing PCIe registers

Re: [PATCH 1/2] dt-bindings: sound: tlv320adcx140: Add GPI config property

2020-05-28 Thread Rob Herring
On Thu, May 28, 2020 at 8:20 AM Dan Murphy wrote: > > Rob > > On 5/28/20 9:05 AM, Rob Herring wrote: > > On Tue, May 26, 2020 at 03:09:16PM -0500, Dan Murphy wrote: > >> Add an array property that configures the General Purpose Input (GPI) > >> register. The device has 4 GPI pins and each pin can

KASAN: use-after-free Read in ib_uverbs_remove_one

2020-05-28 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:c11d28ab Add linux-next specific files for 20200522 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=12fc3e7210 kernel config: https://syzkaller.appspot.com/x/.config?x=3f6dbdea4159fb66 dashboard

Re: [PATCH net] net: mvpp2: Enable autoneg bypass for 1000BaseX/2500BaseX ports

2020-05-28 Thread Thomas Bogendoerfer
On Thu, 28 May 2020 14:56:08 +0100 Russell King - ARM Linux admin wrote: > On Thu, May 28, 2020 at 03:17:33PM +0200, Thomas Bogendoerfer wrote: > > On Thu, 28 May 2020 14:07:38 +0100 > > Russell King - ARM Linux admin wrote: > > > > > On Thu, May 28, 2020 at 02:11:21PM +0200, Thomas Bogendoerfe

Re: [PATCH 2/3] kasan: move kasan_report() into report.c

2020-05-28 Thread Josh Poimboeuf
On Thu, May 28, 2020 at 09:49:13AM -0400, Qian Cai wrote: > On Tue, May 12, 2020 at 05:33:20PM +0200, 'Andrey Konovalov' via kasan-dev > wrote: > > The kasan_report() functions belongs to report.c, as it's a common > > functions that does error reporting. > > > > Reported-by: Leon Romanovsky > >

Re: [PATCH net-next 6/8] net: phy: mscc: timestamping and PHC support

2020-05-28 Thread Richard Cochran
On Wed, May 27, 2020 at 06:41:56PM +0200, Antoine Tenart wrote: > +static struct vsc85xx_ptphdr *get_ptp_header(struct sk_buff *skb) > +{ > + struct ethhdr *ethhdr = eth_hdr(skb); > + struct iphdr *iphdr = ip_hdr(skb); > + struct udphdr *udphdr; > + __u8 proto; > + > + if (ethh

Re: [PATCH 1/2] workqueue: pin the pool while it is managing

2020-05-28 Thread Tejun Heo
Hello, On Thu, May 28, 2020 at 03:06:55AM +, Lai Jiangshan wrote: > @@ -2129,10 +2128,21 @@ __acquires(&pool->lock) > static bool manage_workers(struct worker *worker) > { > struct worker_pool *pool = worker->pool; > + struct work_struct *work = list_first_entry(&pool->worklist, >

Re: [PATCH 1/2] perf record: Respect --no-switch-events

2020-05-28 Thread Arnaldo Carvalho de Melo
Em Thu, May 28, 2020 at 03:08:58PM +0300, Adrian Hunter escreveu: > Context switch events are added automatically by Intel PT and Coresight. > Make it possible to suppress them. That is useful for tracing the > scheduler without the disturbance that the switch event processing > creates. > > Examp

Re: UBSAN: array-index-out-of-bounds in drivers/scsi/hpsa.c:4421:7

2020-05-28 Thread Qian Cai
On Thu, May 28, 2020 at 01:46:02PM +, don.br...@microchip.com wrote: > Working on this. > Can you send your configuration? > ssacli controller all show config detail https://raw.githubusercontent.com/cailca/linux-mm/master/kcsan.config # ssacli controller all show Smart Array P246br in Slot

[PATCH net-next] tipc: Fix NULL pointer dereference in __tipc_sendstream()

2020-05-28 Thread YueHaibing
tipc_sendstream() may send zero length packet, then tipc_msg_append() do not alloc skb, skb_peek_tail() will get NULL, msg_set_ack_required will trigger NULL pointer dereference. Reported-by: syzbot+8eac6d030e7807c21...@syzkaller.appspotmail.com Fixes: 0a3e060f340d ("tipc: add test for Nagle algor

Re: [PATCH RESEND v2] mtd: physmap: Add Baikal-T1 physically mapped ROMs support

2020-05-28 Thread Serge Semin
On Thu, May 28, 2020 at 04:35:41PM +0530, Vignesh Raghavendra wrote: > > > On 28/05/20 4:12 pm, Serge Semin wrote: > [...] > >>> + > >>> +static map_word __xipram bt1_rom_dummy_read(struct map_info *map, > >>> + unsigned long ofs) > >>> +{ > >>> + map_word ret; >

Re: [PATCH 2/2] perf intel-pt: Refine kernel decoding only warning message

2020-05-28 Thread Arnaldo Carvalho de Melo
Em Thu, May 28, 2020 at 03:08:59PM +0300, Adrian Hunter escreveu: > Stop the message displaying when user space is not being traced. > > Example: > > Prerequisites: > > sudo setcap > "cap_sys_rawio,cap_sys_admin,cap_sys_ptrace,cap_syslog,cap_ipc_lock=ep" > ~/bin/perf > sudo chmod +r

Re: [PATCH bpf 0/5] bpf: fix map permissions check and cleanup code around

2020-05-28 Thread Daniel Borkmann
On Wed, May 27, 2020 at 06:56:55PM +, Anton Protopopov wrote: > This series fixes a bug in the map_lookup_and_delete_elem() function which > should check for the FMODE_CAN_READ bit, because it returns data to user > space. > The rest of commits fix some typos and comment in selftests and exten

Re: [PATCH 1/2] seccomp: notify user trap about unused filter

2020-05-28 Thread Christian Brauner
On Thu, May 28, 2020 at 04:17:00PM +0200, Christian Brauner wrote: > On Wed, May 27, 2020 at 06:59:54PM -0700, Kees Cook wrote: > > On Thu, May 28, 2020 at 01:16:46AM +0200, Christian Brauner wrote: > > > I'm also starting to think this isn't even possible or currently doable > > > safely. > > > Th

Re: [v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Markus Elfring
> Can it matter to use separate callback functions for these cases? > https://elixir.bootlin.com/linux/v5.7-rc7/C/ident/rcu_free_pwq See also: https://elixir.bootlin.com/linux/v5.7-rc7/C/ident/rcu_free_wq Regards, Markus

Re: [PATCH] PCI: hv: Use struct_size() helper

2020-05-28 Thread Lorenzo Pieralisi
On Mon, May 25, 2020 at 11:43:19AM -0500, Gustavo A. R. Silva wrote: > One of the more common cases of allocation size calculations is finding > the size of a structure that has a zero-sized array at the end, along > with memory for some number of elements for that array. For example: > > struct h

Re: [PATCH v3 05/10] dmaengine: Introduce DMA-device device_caps callback

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:16AM +0300, Serge Semin wrote: > There are DMA devices (like ours version of Synopsys DW DMAC) which have > DMA capabilities non-uniformly redistributed amongst the device channels. > In order to provide a way of exposing the channel-specific parameters to > the DMA en

[PATCH 1/2] ARM: dts: Move watchdog from Kontron i.MX6UL/ULL board to SoM

2020-05-28 Thread Schrempf Frieder
From: Frieder Schrempf The watchdog's WDOG_ANY signal is used to trigger a POR of the SoC, if a soft reset is issued. As the SoM hardware connects the WDOG_ANY and the POR signals, the watchdog node itself and the pin configuration should be part of the common SoM devicetree. Let's move it from t

Re: [PATCH v11 4/4] power: supply: bq25150 introduce the bq25150

2020-05-28 Thread Andrew F. Davis
On 5/28/20 10:05 AM, Ricardo Rivera-Matos wrote: > +static int bq2515x_set_precharge_current(struct bq2515x_device *bq2515x, > + int val) > +{ > + int ret; > + unsigned int pchrgctrl; > + unsigned int icharge_range; > + unsigned int precharge_reg_

[PATCH 2/2] ARM: dts: Change WDOG_ANY signal from push-pull to open-drain

2020-05-28 Thread Schrempf Frieder
From: Frieder Schrempf The WDOG_ANY signal is connected to the RESET_IN signal of the SoM and baseboard. It is currently configured as push-pull, which means that if some external device like a programmer wants to assert the RESET_IN signal by pulling it to ground, it drives against the high leve

Re: [PATCH v2 1/2] regmap: provide helpers for simple bit operations

2020-05-28 Thread Mark Brown
On Thu, May 28, 2020 at 04:22:40PM +0200, Bartosz Golaszewski wrote: > + return (val & bits) == bits ? 1 : 0; The tenery here is redundant, it's converting a boolean value into a boolean value. Otherwise this looks good. signature.asc Description: PGP signature

Re: [v5] workqueue: Remove unnecessary kfree() call in rcu_free_wq()

2020-05-28 Thread Markus Elfring
> Yeah, regardless of who puts a wq the last time, the base reference is put > by destroy_workqueue() and thus it's guaranteed that a wq can't be rcu freed > without going through destroy_workqueue(). lol I'm undoing the revert. * Would you like to add such background information to the change des

[PATCH] PM: runtime: Replace pm_runtime_callbacks_present()

2020-05-28 Thread Rafael J. Wysocki
From: Rafael J. Wysocki The name of pm_runtime_callbacks_present() is confusing, because it suggests that the device has PM-runtime callbacks if 'true' is returned by that function, but in fact that may not be the case, so replace it with pm_runtime_has_no_callbacks() which is not ambiguous. No

[PATCH] dt-bindings: sound: tlv320adcx140: Fix dt-binding-check issue

2020-05-28 Thread Dan Murphy
Fix dt-binding-check issue ti,gpi-config:0:0: 4 is greater than the maximum of 1 ti,gpi-config:0:1: 5 is greater than the maximum of 1 ti,gpi-config:0:2: 6 is greater than the maximum of 1 ti,gpi-config:0:3: 7 is greater than the maximum of 1 Reported-by: Rob Herring Signed-off-by: Dan Murphy -

Re: [RFC PATCH v4] GCOV: profile by modules

2020-05-28 Thread Peter Oberparleiter
On 25.05.2020 12:00, gengc...@gmail.com wrote: > From: Cixi Geng > > The CONFIG_GCOV_PROFILE_ALL will compile kernel by profiling entire > kernel which will lead to kernel run slower.Use GCOV_PROFILE_PREREQS > to control part of the kernel modules to open gcov. Maybe rephrase the commit message

Re: [PATCHv3 0/2] Add support for replicators which loses context on clock removal

2020-05-28 Thread Rob Herring
On Mon, May 25, 2020 at 10:15:53AM -0600, Mathieu Poirier wrote: > Hi Sai, > > On Sat, May 23, 2020 at 12:06:50AM +0530, Sai Prakash Ranjan wrote: > > This series is mainly to add support for replicators > > which lose context on removing AMBA clock like on SC7180 > > SoC where replicator in AOSS

[PATCH] soc: qcom: rpmh-rsc: Don't use ktime for timeout in write_tcs_reg_sync()

2020-05-28 Thread Douglas Anderson
The write_tcs_reg_sync() may be called after timekeeping is suspended so it's not OK to use ktime. The readl_poll_timeout_atomic() macro implicitly uses ktime. This was causing a warning at suspend time. Change to just loop 100 times with a delay of 1 us between loops. This may give a timeou

[PATCH] arm64: dts: qcom: msm8998-mtp: Fix label on l15 regulator

2020-05-28 Thread Jeffrey Hugo
The label on the l15 regulator node does not follow the style of the rest of the regulator nodes. Luckily, no one has used the label yet, so lets fix it. Fixes: 31c1f0e33deb ("arm64: dts: qcom: msm8998: Add RPM and regulators for MTP") Signed-off-by: Jeffrey Hugo --- arch/arm64/boot/dts/qcom/m

Re: [PATCH net] net: mvpp2: Enable autoneg bypass for 1000BaseX/2500BaseX ports

2020-05-28 Thread Russell King - ARM Linux admin
On Thu, May 28, 2020 at 04:33:35PM +0200, Thomas Bogendoerfer wrote: > below is the dts part for the two network interfaces. The switch to > the outside has two ports, which correlate to the two internal ports. > And the switch propagates the link state of the external ports to > the internal ports

Re: [PATCH v2 1/2] regmap: provide helpers for simple bit operations

2020-05-28 Thread Bartosz Golaszewski
czw., 28 maj 2020 o 16:45 Mark Brown napisał(a): > > On Thu, May 28, 2020 at 04:22:40PM +0200, Bartosz Golaszewski wrote: > > > + return (val & bits) == bits ? 1 : 0; > > The tenery here is redundant, it's converting a boolean value into a > boolean value. Otherwise this looks good. Do you m

[PATCH 2/6] bus: bt1-apb: Fix show/store callback identations

2020-05-28 Thread Serge Semin
After fixing the sysfs calback return value the functions argumnets identations have been left as before the fix. That made the argments declarations being unaligned with respect to the space surrounded by the parentheses. Signed-off-by: Serge Semin Cc: Alexey Malahov Cc: Olof Johansson Cc: And

[PATCH 6/6] bus: bt1-axi: Use sysfs_streq instead of strncmp

2020-05-28 Thread Serge Semin
There is a ready-to-use method to compare a retrieved from a sysfs node string with another string. It treats both NUL and newline-then-NUL as equivalent string terminations. So use it instead of manually truncating the line length in the strncmp() method. Signed-off-by: Serge Semin Cc: Alexey Ma

Re: [PATCH RFC] sched: Add a per-thread core scheduling interface

2020-05-28 Thread Joel Fernandes
On Sun, May 24, 2020 at 10:00:46AM -0400, Phil Auld wrote: > On Fri, May 22, 2020 at 05:35:24PM -0400 Joel Fernandes wrote: > > On Fri, May 22, 2020 at 02:59:05PM +0200, Peter Zijlstra wrote: > > [..] > > > > > It doens't allow tasks for form their own groups (by for example > > > > > setting > >

Re: [PATCH v3 2/2] soc: qcom: rpmh-rsc: Timeout after 1 second in write_tcs_reg_sync()

2020-05-28 Thread Doug Anderson
Hi, On Thu, May 28, 2020 at 4:44 AM Maulik Shah wrote: > > Hi Doug, > > During suspend-resume with this change on sc7180 using latest > linux-next, below warning was reported. > > WARNING: CPU: 0 PID: 5324 at kernel/time/timekeeping.c:754 > ktime_get+0x94/0x9c > ktime_get+0x94/0x9c > write_tc

[PATCH 1/6] bus: bt1-apb: Include linux/io.h

2020-05-28 Thread Serge Semin
It must be included since we are using readl() method here. Signed-off-by: Serge Semin Cc: Alexey Malahov Cc: Olof Johansson Cc: Andy Shevchenko Cc: s...@kernel.org --- drivers/bus/bt1-apb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/bus/bt1-apb.c b/drivers/bus/bt1-apb.c inde

[PATCH 3/6] bus: bt1-apb: Use PTR_ERR_OR_ZERO to return from request-regs method

2020-05-28 Thread Serge Semin
Indeed it's more optimal to use the PTR_ERR_OR_ZERO() macro there instead of having two return points. Signed-off-by: Serge Semin Cc: Alexey Malahov Cc: Olof Johansson Cc: Andy Shevchenko Cc: s...@kernel.org --- drivers/bus/bt1-apb.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-)

[PATCH 5/6] bus: bt1-axi: Optimize the return points in the driver

2020-05-28 Thread Serge Semin
It's better to have a single return statement where it's applicable instead of returning from a conditional statement if-clause. Let's do this in the request registers, clock and IRQ methods. Signed-off-by: Serge Semin Cc: Alexey Malahov Cc: Olof Johansson Cc: Andy Shevchenko Cc: s...@kernel.o

[PATCH] arm64: dts: qcom: msm8998-clamshell: Fix label on l15 regulator

2020-05-28 Thread Jeffrey Hugo
The label on the l15 regulator node does not follow the style of the rest of the regulator nodes. Luckily, no one has used the label yet, so lets fix it. Fixes: 2c6d2d3a580a ("arm64: dts: qcom: Add Lenovo Miix 630") Signed-off-by: Jeffrey Hugo --- arch/arm64/boot/dts/qcom/msm8998-clamshell.dtsi

[PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread Colin King
From: Colin Ian King The allocation failure check for nhg->spare is currently checking the pointer nhg rather than nhg->spare which is never false. Fix this by checking nhg->spare instead. Addresses-Coverity: ("Logically dead code") Fixes: 430a049190de ("nexthop: Add support for nexthop groups")

[PATCH 4/6] bus: bt1-apb: Use sysfs_streq instead of strncmp

2020-05-28 Thread Serge Semin
There is a ready-to-use method to compare a retrieved from a sysfs node string with another string. It treats both NUL and newline-then-NUL as equivalent string terminations. So use it instead of manually truncating the line length in the strncmp() method. Signed-off-by: Serge Semin Cc: Alexey Ma

[PATCH 0/4] selftests, sysctl, lib: Fix prime_numbers and sysctl test to run

2020-05-28 Thread Masami Hiramatsu
Hi, Recently, I found some tests were always skipped. Here is a series of patches to fix those issues. The prime_numbers test is skipped in some cases because prime_numbers.ko is not always compiled. Since the CONFIG_PRIME_NUMBERS is not independently configurable item (it has no title and help),

Re: [PATCH v3 09/10] dmaengine: dw: Introduce max burst length hw config

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:20AM +0300, Serge Semin wrote: > IP core of the DW DMA controller may be synthesized with different > max burst length of the transfers per each channel. According to Synopsis > having the fixed maximum burst transactions length may provide some > performance gain. At

[PATCH 1/4] lib: Make prime number generator independently selectable

2020-05-28 Thread Masami Hiramatsu
Make prime number generator independently selectable from kconfig. This allows us to enable CONFIG_PRIME_NUMBERS=m and run the tools/testing/selftests/lib/prime_numbers.sh without other DRM selftest modules. Signed-off-by: Masami Hiramatsu --- lib/math/Kconfig |7 ++- 1 file changed, 6 i

[PATCH 3/4] selftests/sysctl: Fix to load test_sysctl module

2020-05-28 Thread Masami Hiramatsu
Fix to load test_sysctl.ko module correctly. sysctl.sh checks whether the test module is embedded (or loaded already) or not at first, and if not, it returns skip error instead of trying modprobe. Thus, there is no chance to load the test_sysctl test module. Instead, this removes that module embe

[PATCH] ftrace,bug: Improve traceoff_on_warn

2020-05-28 Thread Peter Zijlstra
Hai, While doing some tracing, I found a huge portion of the per-cpu buffer was taken by printk/serial output because we're disabling the trace far too late (after printing the CUT string). Improve matters for architectures that have GENERIC_BUG + _BUG_FLAGS by killing the tracer in the exception

[PATCH 4/4] selftests/sysctl: Make sysctl test driver as a module

2020-05-28 Thread Masami Hiramatsu
Fix config file to require CONFIG_TEST_SYSCTL=m instead of y because this driver introduces a test sysctl interfaces which are normally not used, and only used for the selftest. Signed-off-by: Masami Hiramatsu --- tools/testing/selftests/sysctl/config |2 +- 1 file changed, 1 insertion(+), 1

[PATCH 2/4] lib: Make test_sysctl initialized as module

2020-05-28 Thread Masami Hiramatsu
test_sysctl.c is expected to be used as a module, but since it does not use module_init(), it never be registered as a module and not appeared under /sys/module/. In the result, the selftests/sysctl/sysctl.sh always fails to find the test module and is skipped. This makes test_sysctl.c initialized

Re: [PATCH v3 08/10] dmaengine: dw: Add dummy device_caps callback

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:19AM +0300, Serge Semin wrote: > Since some DW DMA controllers (like one installed on Baikal-T1 SoC) may > have non-uniform DMA capabilities per device channels, let's add > the DW DMA specific device_caps callback to expose that specifics up to > the DMA consumer. It'

Re: [PATCHv3 2/2] dt-bindings: arm: coresight: Add support to skip trace unit power up

2020-05-28 Thread Rob Herring
On Fri, 15 May 2020 21:52:33 +0530, Sai Prakash Ranjan wrote: > From: Tingwei Zhang > > Add "qcom,skip-power-up" property to identify systems which can > skip powering up of trace unit since they share the same power > domain as their CPU core. This is required to identify such > systems with har

Re: [PATCH] sbp-target: add the missed kfree() in an error path

2020-05-28 Thread Bart Van Assche
On 2020-05-28 03:20, Chuhong Yuan wrote: > sbp_fetch_command() forgets to call kfree() in an error path. > Add the missed call to fix it. Hi Chris, The changelog of the code under drivers/target/sbp makes we wonder whether this driver has ever had any other users than its original author. Do you

Re: [PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread Nikolay Aleksandrov
On 28/05/2020 17:51, Colin King wrote: > From: Colin Ian King > > The allocation failure check for nhg->spare is currently checking > the pointer nhg rather than nhg->spare which is never false. Fix > this by checking nhg->spare instead. > > Addresses-Coverity: ("Logically dead code") > Fixes: 4

Re: [PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread David Ahern
On 5/28/20 8:53 AM, Nikolay Aleksandrov wrote: > On 28/05/2020 17:51, Colin King wrote: >> From: Colin Ian King >> >> The allocation failure check for nhg->spare is currently checking >> the pointer nhg rather than nhg->spare which is never false. Fix >> this by checking nhg->spare instead. >> >>

Re: [RFC v3 3/3] dt-bindings: usb: dwc3: Add entry for tx-fifo-resize

2020-05-28 Thread Rob Herring
On Wed, 27 May 2020 18:46:03 -0700, Wesley Cheng wrote: > Re-introduce the comment for the tx-fifo-resize setting for the DWC3 > controller. This allows for vendors to control if they require the TX FIFO > resizing logic on their HW, as the default FIFO size configurations may > already be suffici

Re: [PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread Nikolay Aleksandrov
On 28/05/2020 17:53, Nikolay Aleksandrov wrote: > On 28/05/2020 17:51, Colin King wrote: >> From: Colin Ian King >> >> The allocation failure check for nhg->spare is currently checking >> the pointer nhg rather than nhg->spare which is never false. Fix >> this by checking nhg->spare instead. >> >>

[patch 0/5] x86/idt: Cleanups and consolidation

2020-05-28 Thread Thomas Gleixner
IDT functionality is spread out to places which results in way too many globals. This series cleans that up, fixes comments and a few other oddities which I noticed while working on that code. Thanks, tglx --- include/asm/desc.h | 47 kernel/cpu/common.c | 17

Re: [PATCH v3 10/10] dmaengine: dw: Initialize max_sg_nents with nollp flag

2020-05-28 Thread Andy Shevchenko
On Wed, May 27, 2020 at 01:50:21AM +0300, Serge Semin wrote: > Multi-block support provides a way to map the kernel-specific SG-table so > the DW DMA device would handle it as a whole instead of handling the > SG-list items or so called LLP block items one by one. So if true LLP > list isn't suppor

[patch 4/5] x86/idt: Cleanup trap_init()

2020-05-28 Thread Thomas Gleixner
No point in having all the IDT cruft in trap_init(). Move it into the IDT code, get rid of the extra global function and fixup the comments. Signed-off-by: Thomas Gleixner --- arch/x86/include/asm/desc.h |2 -- arch/x86/kernel/idt.c | 26 +++--- arch/x86/kernel/tr

[patch 5/5] x86/idt: Consolidate idt functionality

2020-05-28 Thread Thomas Gleixner
- Move load_current_idt() out of line and replace the hideous comment with a lockdep assert. - Move debug IDT cruft into the IDT code and simplify it. This makes debug_idt_ctr static and removes one function call. - Move the idt descriptor table definition to spare the extra #ifdef s

[patch 2/5] x86/idt: Add comments about early #PF handling

2020-05-28 Thread Thomas Gleixner
The difference between 32 and 64 bit vs. early #PF handling is not documented. Replace the FIXME at idt_setup_early_pf() with proper comments. Signed-off-by: Thomas Gleixner --- arch/x86/kernel/idt.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) --- a/arch/x86/kernel/idt.c

Re: [PATCH v2 1/3] scsi: ufs: remove max_t in ufs_get_device_desc

2020-05-28 Thread Bart Van Assche
On 2020-05-28 04:56, Bean Huo wrote: > From: Bean Huo > > For the UFS device, the maximum descriptor size is 255, max_t called in > ufs_get_device_desc() is useless. > > Signed-off-by: Bean Huo > --- > drivers/scsi/ufs/ufshcd.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > dif

[patch 1/5] x86/idt: Mark init only functions __init

2020-05-28 Thread Thomas Gleixner
Since 8175cfbbbfcb ("x86/idt: Remove update_intr_gate()") set_intr_gate() and idt_setup_from_table() are only called from __init functions. Mark them as well. Signed-off-by: Thomas Gleixner --- arch/x86/kernel/idt.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/arch/x86/ker

[patch 3/5] x86/idt: Use proper constants for table sizes

2020-05-28 Thread Thomas Gleixner
Use the actual struct size to calculate the IDT table sizes instead of two different hardcoded values. Signed-off-by: Thomas Gleixner --- arch/x86/kernel/idt.c | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) --- a/arch/x86/kernel/idt.c +++ b/arch/x86/kernel/idt.c @@ -51,6 +5

Re: [PATCH v3 4/4] kdb: Switch kdb_msg_write() to use safer polling I/O

2020-05-28 Thread Petr Mladek
On Thu 2020-05-28 12:26:20, Daniel Thompson wrote: > On Thu, May 28, 2020 at 11:48:48AM +0530, Sumit Garg wrote: > > On Wed, 27 May 2020 at 19:01, Daniel Thompson > > wrote: > > > > > > On Wed, May 27, 2020 at 11:55:59AM +0530, Sumit Garg wrote: > > > > In kgdb NMI context, calling console handler

[PATCH v7 0/5] iio: magnetometer: ak8975: Add gpio reset support

2020-05-28 Thread Jonathan Albrieux
v7: - fix documentation style, removing documentation unnecessary parts v6: - reword documentation for gpios, add interrupt documentation https://lore.kernel.org/linux-iio/20200525151117.32540-1-jonathan.albri...@gmail.com/ v5: - add maintainer https://lore.kernel.org/linux-iio/20200520163417.

drivers/misc/xilinx_sdfec.c:736:15: sparse: sparse: incorrect type in argument 2 (different address spaces)

2020-05-28 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: b0c3ba31be3e45a130e13b278cf3b90f69bda6f6 commit: a6b07e89fd8530b943217ccd4909d1bf65acc45d misc: xilinx_sdfec: add missing __user annotation date: 5 months ago config: m68k-randconfig-s031-20200528

[PATCH v7 1/5] dt-bindings: iio: magnetometer: ak8975: reword gpios, add interrupts, fix style

2020-05-28 Thread Jonathan Albrieux
Reword gpios documentation, add interrupt documentation and fix styles. Update example to use interrupts instead of gpios. Signed-off-by: Jonathan Albrieux Reviewed-by: Rob Herring --- .../bindings/iio/magnetometer/ak8975.txt | 19 +-- 1 file changed, 13 insertions(+), 6 de

RE: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Avri Altman
Hi, > From: Bean Huo > > At UFS initialization stage, to get the length of the descriptor, > ufshcd_read_desc_length() being called 6 times. May I suggest one more clarifying sentence to your commit log: "Instead, we will capture the descriptor size the first time we'll read it." >This patch is

Re: [PATCH 2/3] kasan: move kasan_report() into report.c

2020-05-28 Thread Peter Zijlstra
On Thu, May 28, 2020 at 09:33:41AM -0500, Josh Poimboeuf wrote: > On Thu, May 28, 2020 at 09:49:13AM -0400, Qian Cai wrote: > > On Tue, May 12, 2020 at 05:33:20PM +0200, 'Andrey Konovalov' via kasan-dev > > wrote: > > > The kasan_report() functions belongs to report.c, as it's a common > > > funct

[PATCH v7 2/5] dt-bindings: iio: magnetometer: ak8975: convert format to yaml, add maintainer

2020-05-28 Thread Jonathan Albrieux
Converts documentation from txt format to yaml. Signed-off-by: Jonathan Albrieux --- .../bindings/iio/magnetometer/ak8975.txt | 37 - .../iio/magnetometer/asahi-kasei,ak8975.yaml | 77 +++ 2 files changed, 77 insertions(+), 37 deletions(-) delete mode 100644 Docum

[PATCH v6 1/3] gpiolib: Introduce gpiochip_irqchip_add_domain()

2020-05-28 Thread Michael Walle
The function connects an IRQ domain to a gpiochip and reuses gpiochip_to_irq() which is provided by gpiolib. gpiochip_irqchip_* and regmap_irq partially provide the same functionality. This function will help to connect just the minimal functionality of the gpiochip_irqchip which is needed to work

[PATCH v7 3/5] dt-bindings: iio: magnetometer: ak8975: add gpio reset support

2020-05-28 Thread Jonathan Albrieux
Add reset-gpio support. Without reset's deassertion during ak8975_power_on(), driver's probe fails on ak8975_who_i_am() while checking for device identity for AK09911 chip. AK09911 has an active low reset gpio to handle register's reset. AK09911 datasheet says that, if not used, reset pin should

[PATCH v6 0/3] gpio: generic regmap implementation

2020-05-28 Thread Michael Walle
This series is a split off of the sl28cpld series: https://lore.kernel.org/linux-gpio/20200423174543.17161-1-mich...@walle.cc/ I wasn't sure if I should also include the gpiochip_irqchip_add_domain() patch here. So feel free to skip it. OTOH if you use interrupts with gpio-regmap it is quite handy

Re: mm: mkfs.ext4 invoked oom-killer on i386 - pagecache_get_page

2020-05-28 Thread Michal Hocko
[Sorry for a late reply - was offline for few days] On Thu 21-05-20 17:58:55, Johannes Weiner wrote: > On Thu, May 21, 2020 at 01:06:28PM -0700, Hugh Dickins wrote: [...] > >From d9e7ed15d1c9248a3fd99e35e82437549154dac7 Mon Sep 17 00:00:00 2001 > From: Johannes Weiner > Date: Thu, 21 May 2020 17:

Re: [PATCH v2 2/3] scsi: ufs: delete ufshcd_read_desc()

2020-05-28 Thread Bart Van Assche
On 2020-05-28 04:56, Bean Huo wrote: > Delete ufshcd_read_desc(). Instead, let caller directly call > ufshcd_read_desc_param(). Reviewed-by: Bart van Assche

[PATCH v6 2/3] gpio: add a reusable generic gpio_chip using regmap

2020-05-28 Thread Michael Walle
There are quite a lot simple GPIO controller which are using regmap to access the hardware. This driver tries to be a base to unify existing code into one place. This won't cover everything but it should be a good starting point. It does not implement its own irq_chip because there is already a ge

[PATCH v6 3/3] MAINTAINERS: Add gpio regmap section

2020-05-28 Thread Michael Walle
Add myself as a reviewer for the gpio regmap. Signed-off-by: Michael Walle --- MAINTAINERS | 6 ++ 1 file changed, 6 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 3a003f310574..f3458debb0c9 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -7340,6 +7340,12 @@ S: Maintained F

[PATCH V5 9/9] Documentation/dax: Update DAX enablement for ext4

2020-05-28 Thread ira . weiny
From: Ira Weiny Update the document to reflect ext4 and xfs now behave the same. Reviewed-by: Jan Kara Signed-off-by: Ira Weiny --- Changes from RFC: Update with ext2 text... --- Documentation/filesystems/dax.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[PATCH V5 8/9] fs/ext4: Introduce DAX inode flag

2020-05-28 Thread ira . weiny
From: Ira Weiny Add a flag ([EXT4|FS]_DAX_FL) to preserve FS_XFLAG_DAX in the ext4 inode. Set the flag to be user visible and changeable. Set the flag to be inherited. Allow applications to change the flag at any time except if it conflicts with the set of mutually exclusive flags (Currently V

[PATCH V5 5/9] fs/ext4: Only change S_DAX on inode load

2020-05-28 Thread ira . weiny
From: Ira Weiny To prevent complications with in memory inodes we only set S_DAX on inode load. FS_XFLAG_DAX can be changed at any time and S_DAX will change after inode eviction and reload. Add init bool to ext4_set_inode_flags() to indicate if the inode is being newly initialized. Assert tha

<    3   4   5   6   7   8   9   10   11   12   >