[PATCH 1/1] iommu/vt-d: Fix NULL pointer dereference in dev_iommu_priv_set()

2020-09-02 Thread Lu Baolu
The dev_iommu_priv_set() must be called after probe_device(). This fixes a NULL pointer deference bug when booting a system with kernel cmdline "intel_iommu=on,igfx_off", where the dev_iommu_priv_set() is abused. The following stacktrace was produced: [0.00] Command line: BOOT_IMAGE=/isol

[Linux-kernel-mentees] [PATCH] block: Fix use-after-free in bdev_del_partition()

2020-09-02 Thread Peilin Ye
In bdev_del_partition(), `part` is being looked up outside the critical section. This is causing bdev_del_partition() to delete the same partition more than once. Fix it by reverting commit cddae808aeb7. Fixes: cddae808aeb7 ("block: pass a hd_struct to delete_partition") Reported-and-tested-by: sy

Re: [PATCH] x86/uaccess: Use pointer masking to limit uaccess speculation

2020-09-02 Thread Christoph Hellwig
On Wed, Sep 02, 2020 at 06:23:30PM +0100, Mark Rutland wrote: > I've pushed an initial/incomplete/WIP stab (just the kernel accessors) > to: > > https://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git/log/?h=arm64/set_fs-removal Thanks! > ... and doing that made it clear that the necessar

Re: R: [RFC PATCH v3 0/2] Add Krait Cache Scaling support

2020-09-02 Thread Viresh Kumar
On 31-08-20, 09:41, ansuels...@gmail.com wrote: > On 31-08-20, Sibi wrote: > > On 2020-08-24 16:10, Viresh Kumar wrote: > > > +Vincent/Saravana/Sibi > > > > > > On 21-08-20, 16:00, Ansuel Smith wrote: > > >> This adds Krait Cache scaling support using the cpufreq notifier. > > >> I have some doubt

Re: [PATCH] dmaengine: Mark dma_request_slave_channel() deprecated

2020-09-02 Thread Vinod Koul
On 28-08-20, 14:05, Peter Ujfalusi wrote: > New drivers should use dma_request_chan() instead > dma_request_slave_channel() > > dma_request_slave_channel() is a simple wrapper for dma_request_chan() > eating up the error code for channel request failure and makes deferred > probing impossible. >

Re: [PATCH v3 3/3] mm/armv6: work around armv6 cmpxchg support issue

2020-09-02 Thread Alex Shi
在 2020/9/1 下午9:17, Matthew Wilcox 写道: > On Tue, Sep 01, 2020 at 02:30:51PM +0800, Alex Shi wrote: >> seems there are couples archs can not do cmpxchg1 >> So update the patch here. And it's easy to fix if more arch issue find here. > >> +/* >> + * cmpxchg only support 32-bits operands on the fol

Re: [PATCH v3 1/3] mm/pageblock: mitigation cmpxchg false sharing in pageblock flags

2020-09-02 Thread Alex Shi
在 2020/9/2 上午1:06, Vlastimil Babka 写道: >> >>pageblock pageblock pageblockrc2 rc2 >>rc2 >> 1616-216-3 a b >> c >> Duration User 14.81 15.24 14.55 14.

Re: [PATCH 01/10] USB: move snd_usb_pipe_sanity_check into the USB core

2020-09-02 Thread Takashi Iwai
On Thu, 03 Sep 2020 02:45:53 +0200, Alan Stern wrote: > > In a few places here this check is completely unnecessary. All it does > is verify that the device does have an endpoint 0 and the the type of > the endpoint matches the type of the pipe. Well, every USB device > always has an endpoint

[PATCH] cypto: mediatek - fix leaks in mtk_desc_ring_alloc

2020-09-02 Thread Xiaoliang Pang
In the init loop, if an error occurs in function 'dma_alloc_coherent', then goto the err_cleanup section, in the cleanup loop, after run i--, the struct mtk_ring rising[i] will not be released, causing a memory leak Signed-off-by: Xiaoliang Pang --- drivers/crypto/mediatek/mtk-platform.c | 2 +-

Re: [PATCH] mm/memory_hotplug: drain per-cpu pages again during memory offline

2020-09-02 Thread Michal Hocko
On Wed 02-09-20 19:51:45, Vlastimil Babka wrote: > On 9/2/20 5:13 PM, Michal Hocko wrote: > > On Wed 02-09-20 16:55:05, Vlastimil Babka wrote: > >> On 9/2/20 4:26 PM, Pavel Tatashin wrote: > >> > On Wed, Sep 2, 2020 at 10:08 AM Michal Hocko wrote: > >> >> > >> >> > > >> >> > Thread#1 - continue >

Re: [PATCH v2 1/2] cper, apei, mce: Pass x86 CPER through the MCA handling chain

2020-09-02 Thread Punit Agrawal
Hi Smita, Smita Koralahalli Channabasappa writes: > On 8/31/20 12:05 AM, Punit Agrawal wrote: > >> Hi Smita, >> >> A couple of comments below - >> >> Smita Koralahalli writes: >> >> [...] >> >> >>> diff --git a/drivers/firmware/efi/cper-x86.c >>> b/drivers/firmware/efi/cper-x86.c >>> index 253

[PATCH v2 3/6] clk: rockchip: Export rockchip_register_softrst()

2020-09-02 Thread Elaine Zhang
This is used by the Rockchip clk driver, export it to allow that driver to be compiled as a module.. Signed-off-by: Elaine Zhang --- drivers/clk/rockchip/softrst.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/clk/rockchip/softrst.c b/drivers/clk/rockchip/sof

[PATCH v2 4/6] clk: rockchip: Export some clock common APIs for module drivers

2020-09-02 Thread Elaine Zhang
This is used by the Rockchip clk driver, export it to allow that driver to be compiled as a module. Signed-off-by: Elaine Zhang --- drivers/clk/rockchip/clk.c | 52 ++ 1 file changed, 30 insertions(+), 22 deletions(-) diff --git a/drivers/clk/rockchip/clk.c b

[PATCH v2 1/6] clk: rockchip: Use clk_hw_register_composite instead of clk_register_composite calls

2020-09-02 Thread Elaine Zhang
clk_hw_register_composite it's already exported. Preparation for compilation of rK common clock drivers into modules. Signed-off-by: Elaine Zhang --- drivers/clk/rockchip/clk-half-divider.c | 18 drivers/clk/rockchip/clk.c | 58 - 2 files changed, 38

[PATCH v2 6/6] clk: rockchip: rk3399: Support module build

2020-09-02 Thread Elaine Zhang
support CLK_OF_DECLARE and builtin_platform_driver_probe double clk init method. add module author, description and license to support building Soc Rk3399 clock driver as module. Signed-off-by: Elaine Zhang --- drivers/clk/rockchip/clk-rk3399.c | 55 +++ 1 file change

[PATCH v2 2/6] clk: rockchip: Export rockchip_clk_register_ddrclk()

2020-09-02 Thread Elaine Zhang
This is used by the Rockchip clk driver, export it to allow that driver to be compiled as a module.. Signed-off-by: Elaine Zhang --- drivers/clk/rockchip/clk-ddr.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/clk/rockchip/clk-ddr.c b/drivers/clk/rockchip/clk-ddr.c index 9273bce4d7

[PATCH v2 0/6] clk: rockchip: Support module build

2020-09-02 Thread Elaine Zhang
Export some APIs for module drivers. Fix the clock config to support module build. Fix the clk driver init, add module author, description and license to support building RK3399 SoC clock driver as module. Change in V2: [PATCH v2 1/6]: remove "clk",and check "hw" isn't an error value. [PATCH v2 6/

[PATCH v2 5/6] clk: rockchip: fix the clk config to support module build

2020-09-02 Thread Elaine Zhang
use CONFIG_COMMON_CLK_ROCKCHIP for Rk common clk drivers. use CONFIG_CLK_RKXX for Rk soc clk driver. Mark configuration to "tristate", to support building Rk SoCs clock driver as module. Signed-off-by: Elaine Zhang --- drivers/clk/Kconfig | 1 + drivers/clk/rockchip/Kconfig | 78

Re: [PATCH V3 3/3] media: i2c: gc5035: Add GC5035 image sensor driver

2020-09-02 Thread Sakari Ailus
Hi Tomasz, On Thu, Sep 03, 2020 at 12:59:20AM +0200, Tomasz Figa wrote: > Hi Sakari, > > On Mon, Aug 31, 2020 at 7:41 PM Sakari Ailus > wrote: > > > > Hi Xingyu, > > > > Thanks for the update. I've got a few more comments below. > > > > Do you happen to have some insight on what the OTP data con

RE: [PATCH v9 2/3] drm: bridge: Add support for Cadence MHDP8546 DPI/DP bridge

2020-09-02 Thread Milind Parab
Hi Tomi, >-Original Message- >From: Tomi Valkeinen >Sent: Tuesday, September 1, 2020 2:05 PM >To: Swapnil Kashinath Jakhade ; airl...@linux.ie; >dan...@ffwll.ch; laurent.pinch...@ideasonboard.com; robh...@kernel.org; >a.ha...@samsung.com; narmstr...@baylibre.com; jo...@kwiboo.se; >jernej.

Re: [PATCH 4/4] perf vendor events amd: Enable Family 19h users by matching Zen2 events

2020-09-02 Thread Ian Rogers
On Tue, Sep 1, 2020 at 3:10 PM Kim Phillips wrote: > > This enables zen3 users by reusing mostly-compatible zen2 events > until the official public list of zen3 events is published in a > future PPR. > > Signed-off-by: Kim Phillips Acked-by: Ian Rogers Thanks! Ian > Cc: Peter Zijlstra > Cc:

Re: [PATCH 3/4] perf vendor events amd: Add recommended events

2020-09-02 Thread Ian Rogers
On Tue, Sep 1, 2020 at 3:10 PM Kim Phillips wrote: > > Add support for events listed in Section 2.1.15.2 "Performance > Measurement" of "PPR for AMD Family 17h Model 31h B0 - 55803 > Rev 0.54 - Sep 12, 2019". > > perf now supports these new events (-e): > > all_dc_accesses > all_tlbs_flushed >

Re: [PATCH 3/4] sh: Add SECCOMP_FILTER

2020-09-02 Thread Rich Felker
On Thu, Sep 03, 2020 at 08:04:44AM +0200, John Paul Adrian Glaubitz wrote: > On 9/3/20 7:46 AM, Rich Felker wrote: > > > > OK, I think I have an explanation for the mechanism of the bug, and it > > really is a combination of the 2008 bug (confusion of r0 vs r3) and > > the SECCOMP_FILTER commit. W

Re: [PATCH] i2c: virtio: add a virtio i2c frontend driver

2020-09-02 Thread Jason Wang
On 2020/9/3 下午1:34, Jie Deng wrote: Add an I2C bus driver for virtio para-virtualization. The controller can be emulated by the backend driver in any device model software by following the virtio protocol. This driver communicates with the backend driver through a virtio I2C message structure

[GIT PULL for v5.9-rc4] media fixes

2020-09-02 Thread Mauro Carvalho Chehab
Hi Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media tags/media/v5.9-2 For: - a compilation fix issue with ti-vpe on arm 32 bits; - two Kconfig fixes for imx214 and max9286 drivers; - a kernel information leak at v4l2-core on time32 compat ioctls; - so

Re: [PATCH 3/4] sh: Add SECCOMP_FILTER

2020-09-02 Thread John Paul Adrian Glaubitz
On 9/3/20 7:46 AM, Rich Felker wrote: > > OK, I think I have an explanation for the mechanism of the bug, and it > really is a combination of the 2008 bug (confusion of r0 vs r3) and > the SECCOMP_FILTER commit. When the syscall_trace_entry code path is > in use, a syscall with argument 5 having v

Re: [PATCH 2/4] perf vendor events amd: Add ITLB Instruction Fetch Hits event for zen1

2020-09-02 Thread Ian Rogers
On Tue, Sep 1, 2020 at 3:10 PM Kim Phillips wrote: > > The ITLB Instruction Fetch Hits event isn't documented even in > later zen1 PPRs, but it seems to count correctly on zen1 hardware. > > Add it to zen1 group so zen1 users can use the upcoming IC Fetch Miss > Ratio Metric. > > The IF1G, 1IF2M,

Re: [PATCH 3/4] sh: Add SECCOMP_FILTER

2020-09-02 Thread John Paul Adrian Glaubitz
Hi Richi! On 9/3/20 5:56 AM, Rich Felker wrote: >> Test 51-live-user_notification%%001-1 result: FAILURE >> 51-live-user_notification 5 ALLOW rc=14 > > AFAICT, this test is buggy and cannot possibly work. It attempts to > have SYS_getpid return a 64-bit value and check that the returned >

Re: [PATCH 02/38] media: v4l2-ioctl: avoid memory leaks on some time32 compat functions

2020-09-02 Thread Mauro Carvalho Chehab
Em Wed, 2 Sep 2020 20:45:53 +0200 Arnd Bergmann escreveu: > On Wed, Sep 2, 2020 at 6:10 PM Mauro Carvalho Chehab > wrote: > > > > There are some reports about possible memory leaks: > > > > drivers/media/v4l2-core//v4l2-ioctl.c:3203 video_put_user() warn: > > check that 'ev32' doesn't l

[PATCH v2] ASoC: fsl_sai: Set SAI Channel Mode to Output Mode

2020-09-02 Thread Shengjiu Wang
Transmit data pins will output zero when slots are masked or channels are disabled. In CHMOD TDM mode, transmit data pins are tri-stated when slots are masked or channels are disabled. When data pins are tri-stated, there is noise on some channels when FS clock value is high and data is read while

Re: [PATCH net-next RFC v3 01/14] devlink: Add reload action option to devlink reload command

2020-09-02 Thread Jiri Pirko
Wed, Sep 02, 2020 at 05:30:25PM CEST, k...@kernel.org wrote: >On Wed, 2 Sep 2020 11:46:27 +0200 Jiri Pirko wrote: >> >? Do we need such change there too or keep it as is, each action by itself >> >and return what was performed ? >> >> Well, I don't know. User asks for X, X should be performed, n

Re: [PATCH v3 19/23] sh: use asm-generic/mmu_context.h for no-op implementations

2020-09-02 Thread Rich Felker
On Wed, Sep 02, 2020 at 12:15:35AM +1000, Nicholas Piggin wrote: > Cc: Yoshinori Sato > Cc: Rich Felker > Cc: linux...@vger.kernel.org > Signed-off-by: Nicholas Piggin > --- > > Please ack or nack if you object to this being mered via > Arnd's tree. Acked-by: Rich Felker > > arch/sh/includ

[PATCH] media: mtk-vcodec: remove allocated dma_parms

2020-09-02 Thread Hsin-Yi Wang
9495b7e92f71 ("driver core: platform: Initialize dma_parms for platform devices") included dma_parms in platform_device. There's no need to allocate again. Fixes: 13483fc2f20f0e2db7ba9c39b095ac7ea46f8de8 ("media: mtk-vcodec: set dma max segment size") Suggested-by: Robin Murphy Signed-off-by: Hs

[PATCH] sh: fix syscall tracing

2020-09-02 Thread Rich Felker
Addition of SECCOMP_FILTER exposed a longstanding bug in do_syscall_trace_enter, whereby r0 (the 5th argument register) was mistakenly used where r3 (syscall_nr) was intended. By overwriting r0 rather than r3 with -1 when attempting to block a syscall, the existing code would instead have caused th

Re: [PATCH 3/4] sh: Add SECCOMP_FILTER

2020-09-02 Thread Rich Felker
On Wed, Sep 02, 2020 at 11:56:04PM -0400, Rich Felker wrote: > On Sat, Aug 29, 2020 at 01:09:43PM +0200, John Paul Adrian Glaubitz wrote: > > Hi! > > > > On 8/29/20 2:49 AM, Rich Felker wrote: > > > This restored my ability to use strace > > > > I can confirm that. However ... > > > > > and I've

[PATCH] mmc: s3cmci: Drop unused variables in dbg_dumpregs

2020-09-02 Thread Krzysztof Kozlowski
The 'imask' and 'bsize' are not used in dbg_dumpregs: drivers/mmc/host/s3cmci.c:149:36: warning: variable 'imask' set but not used [-Wunused-but-set-variable] drivers/mmc/host/s3cmci.c:148:63: warning: variable 'bsize' set but not used [-Wunused-but-set-variable] Reported-by: kernel test ro

[PATCH 2/9] block: add a bdev_is_partition helper

2020-09-02 Thread Christoph Hellwig
Add a littler helper to make the somewhat arcane bd_contains checks a little more obvious. Signed-off-by: Christoph Hellwig --- block/blk-lib.c | 2 +- block/ioctl.c | 4 ++-- block/scsi_ioctl.c | 2 +- drivers/ide/ide-ioctls.c| 4 ++-- driv

[PATCH 5/9] drbd: don't detour through bd_contains for the gendisk

2020-09-02 Thread Christoph Hellwig
bd_disk is set on all block devices, including those for partitions. Signed-off-by: Christoph Hellwig --- drivers/block/drbd/drbd_receiver.c | 2 +- drivers/block/drbd/drbd_worker.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/block/drbd/drbd_receiver.c b/dri

[PATCH 4/9] md: don't detour through bd_contains for the gendisk

2020-09-02 Thread Christoph Hellwig
bd_disk is set on all block devices, including those for partitions. Signed-off-by: Christoph Hellwig --- drivers/md/md.c | 2 +- drivers/md/md.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/md/md.c b/drivers/md/md.c index 3f33562d10d6f5..5a0fd93769a70e 100644 -

[PATCH 7/9] target/iblock: fix holder printing in iblock_show_configfs_dev_params

2020-09-02 Thread Christoph Hellwig
bd_contains is never NULL for an open block device. In addition ibd_bd is always set to a block device that was exclusively opened by the target code, so the holder is guranteed to be ib_dev as well. Signed-off-by: Christoph Hellwig --- drivers/target/target_core_iblock.c | 5 ++--- 1 file chan

[PATCH 3/9] md: compare bd_disk instead of bd_contains

2020-09-02 Thread Christoph Hellwig
To check for partitions of the same disk bd_contains works as well, but bd_disk is way more obvious. Signed-off-by: Christoph Hellwig --- drivers/md/md.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/md/md.c b/drivers/md/md.c index 9562ef598ae1f4..3f33562d10d

clean up is partition checks

2020-09-02 Thread Christoph Hellwig
Hi Jens, this series add a new helepr to check if a struct block_device represents a parition, and removes most direct access to ->bd_contained from drivers. Diffstat: Documentation/userspace-api/ioctl/hdio.rst | 24 block/blk-lib.c|2 +-

[PATCH 9/9] vsprintf: use bd_partno in bdev_name

2020-09-02 Thread Christoph Hellwig
No need to go through the hd_struct to find the partition number. Signed-off-by: Christoph Hellwig --- lib/vsprintf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/vsprintf.c b/lib/vsprintf.c index afb9521ddf9197..14c9a6af1b239a 100644 --- a/lib/vsprintf.c +++ b/lib

[PATCH 6/9] drbd: don't set ->bd_contains

2020-09-02 Thread Christoph Hellwig
The ->bd_contains field is set by __blkdev_get and drivers have no business manipulating it. Signed-off-by: Christoph Hellwig --- drivers/block/drbd/drbd_main.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c index 04b6bde9419d

[PATCH 8/9] block: use bd_partno in bdevname

2020-09-02 Thread Christoph Hellwig
No need to go through the hd_struct to find the partition number. Signed-off-by: Christoph Hellwig --- block/genhd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/genhd.c b/block/genhd.c index 081f1039d9367f..771aa56b1a8c3d 100644 --- a/block/genhd.c +++ b/block/genhd

[PATCH 1/9] Documentation/hdio: fix up obscure bd_contains references

2020-09-02 Thread Christoph Hellwig
bd_contains is an implementation detail and should not be mentioned in a userspace API documentation. Signed-off-by: Christoph Hellwig --- Documentation/userspace-api/ioctl/hdio.rst | 24 +++--- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/Documentation/userspa

Re: [PATCH 1/4] perf vendor events amd: Add L2 Prefetch events for zen1

2020-09-02 Thread Ian Rogers
On Tue, Sep 1, 2020 at 3:10 PM Kim Phillips wrote: > > Later revisions of PPRs that post-date the original Family 17h events > submission patch add these events. > > Specifically, they were not in this 2017 revision of the F17h PPR: > > Processor Programming Reference (PPR) for AMD Family 17h Mode

Re: [PATCH v2] ARM: davinci: use simple i2c probe function

2020-09-02 Thread Sekhar Nori
On 10/08/20 3:07 PM, Wolfram Sang wrote: > On Sun, Aug 09, 2020 at 07:24:44PM +0200, Stephen Kitt wrote: >> The i2c probe functions here don't use the id information provided in >> their second argument, so the single-parameter i2c probe function >> ("probe_new") can be used instead. >> >> This avo

Re: [PATCH 11/11] mmc: host: Enable compile testing of multiple drivers

2020-09-02 Thread Krzysztof Kozlowski
On Wed, Sep 02, 2020 at 11:32:27PM +0200, Michał Mirosław wrote: > On Wed, Sep 02, 2020 at 09:36:58PM +0200, Krzysztof Kozlowski wrote: > > Multiple MMC host controller driver can be compile tested as they do not > > depend on architecture specific headers. > [...] > > --- a/drivers/mmc/host/Kconfi

Re: [PATCH] ASoC: fsl_sai: Set SAI Channel Mode to Output Mode

2020-09-02 Thread Shengjiu Wang
On Thu, Sep 3, 2020 at 11:42 AM Nicolin Chen wrote: > > On Thu, Sep 03, 2020 at 11:09:15AM +0800, Shengjiu Wang wrote: > > Transmit data pins will output zero when slots are masked or channels > > are disabled. In CHMOD TDM mode, transmit data pins are tri-stated when > > slots are masked or chann

Re: [PATCH 6/9] i2c: imx: Simplify with dev_err_probe()

2020-09-02 Thread Oleksij Rempel
On Wed, Sep 02, 2020 at 05:06:40PM +0200, Krzysztof Kozlowski wrote: > Common pattern of handling deferred probe can be simplified with > dev_err_probe(). Less code and the error value gets printed. > > Signed-off-by: Krzysztof Kozlowski Acked-by: Oleksij Rempel > --- > drivers/i2c/busses/i2

Re: [RFC PATCH 0/7] Trace events to pstore

2020-09-02 Thread Sai Prakash Ranjan
On 2020-09-03 03:17, Joel Fernandes wrote: On Wed, Sep 2, 2020 at 4:01 PM Nachammai Karuppiah wrote: Hi, This patch series adds support to store trace events in pstore. Storing trace entries in persistent RAM would help in understanding what happened just before the system went down. The tr

[PATCH] i2c: virtio: add a virtio i2c frontend driver

2020-09-02 Thread Jie Deng
Add an I2C bus driver for virtio para-virtualization. The controller can be emulated by the backend driver in any device model software by following the virtio protocol. This driver communicates with the backend driver through a virtio I2C message structure which includes following parts: - Head

Re: [PATCH v2 2/2] mm/pageblock: remove false sharing in pageblock_flags

2020-09-02 Thread Alex Shi
在 2020/8/31 上午4:32, Alexander Duyck 写道: >> Right that the different level to fix this problem, but narrow the cmpxchg >> comparsion is still needed and helpful. > What I was getting at though is that I am not sure that is the case. > Normally I believe we are always holding the zone lock when up

Re: [PATCH] arm64: dts: qcom: sc7180: Add 'sustainable_power' for CPU thermal zones

2020-09-02 Thread Rajendra Nayak
On 9/3/2020 10:14 AM, Rajendra Nayak wrote: On 9/2/2020 9:02 PM, Doug Anderson wrote: Hi, On Tue, Sep 1, 2020 at 10:36 PM Rajendra Nayak wrote: * In terms of the numbers here, I believe that you're claiming that we can dissipate 768 mW * 6 + 1202 mW * 2 = ~7 Watts of power.  My memory o

Re: [PATCH v3] x86/asm: Replace __force_order with memory clobber

2020-09-02 Thread Miguel Ojeda
On Thu, Sep 3, 2020 at 1:21 AM Arvind Sankar wrote: > > Changes from v2: > - Clarify commit log and source comment some more Much better now, thanks! Reviewed-by: Miguel Ojeda Cheers, Miguel

Re: [PATCH v2] scsi: ibmvfc: interface updates for future FPIN and MQ support

2020-09-02 Thread Tyrel Datwyler
On 9/2/20 7:11 PM, Martin K. Petersen wrote: > > Tyrel, > >> Fixup complier errors from neglected commit --amend > > Bunch of formatting-related checkpatch warnings. Please fix. > > Thanks! > So, I stuck to the existing style already in that header. If I'm going to fixup to make checkpat

Re: [RFC PATCH] libbpf: Support setting map max_entries at runtime

2020-09-02 Thread Andrii Nakryiko
On Mon, Aug 31, 2020 at 4:03 PM Barret Rhoden wrote: > > The max_entries for a BPF map may depend on runtime parameters. > Currently, we need to know the maximum value at BPF compile time. For > instance, if you want an array map with NR_CPUS entries, you would hard > code your architecture's lar

Re: [PATCH 6/7] arm64: dts: ti: k3-*: Use generic adc for node names

2020-09-02 Thread Vignesh Raghavendra
Hi Nishanth, On 9/2/20 11:48 PM, Nishanth Menon wrote: > On 11:51-20200902, Suman Anna wrote: >> On 9/1/20 5:30 PM, Nishanth Menon wrote: >>> Use adc@ naming for nodes following standard conventions of device >>> tree (section 2.2.2 Generic Names recommendation

linux-next: manual merge of the scsi-mkp tree with Linus' tree

2020-09-02 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the scsi-mkp tree got a conflict in: drivers/scsi/ufs/ufshcd.c between commit: b10178ee7fa8 ("scsi: ufs: Clean up completed request without interrupt notification") from Linus' tree and commit: 307348f6ab14 ("scsi: ufs: Abort tasks before clearing th

Re: [Nouveau] [PATCH v2] nouveau: fix the start/end range for migration

2020-09-02 Thread Ben Skeggs
On Tue, 1 Sep 2020 at 06:31, Ralph Campbell wrote: > > The user level OpenCL code shouldn't have to align start and end > addresses to a page boundary. That is better handled in the nouveau > driver. The npages field is also redundant since it can be computed > from the start and end addresses. >

Re: [Nouveau] [PATCH v4] drm/nouveau/kms/nv50-: Program notifier offset before requesting disp caps

2020-09-02 Thread Ben Skeggs
On Wed, 2 Sep 2020 at 09:43, Lyude Paul wrote: > > Not entirely sure why this never came up when I originally tested this > (maybe some BIOSes already have this setup?) but the ->caps_init vfunc > appears to cause the display engine to throw an exception on driver > init, at least on my ThinkPad P

Re: [RFC PATCH v7 06/23] bitops: Introduce find_next_or_bit

2020-09-02 Thread Randy Dunlap
On 8/28/20 12:51 PM, Julien Desfossez wrote: > +#ifndef find_next_or_bit > +/** > + * find_next_or_bit - find the next set bit in any memory regions > + * @addr1: The first address to base the search on > + * @addr2: The second address to base the search on > + * @offset: The bitnumber to start sea

Re: [PATCH 4.4 00/61] 4.4.235-rc2 review

2020-09-02 Thread Naresh Kamboju
--- kernel: 4.4.235-rc2 git repo: https://git.linaro.org/lkft/arm64-stable-rc.git git branch: 4.4.235-rc2-hikey-20200902-803 git commit: 4e984a08e49b4aa772d7681bfaeb091bd7a7b4b9 git describe: 4.4.235-rc2-hikey-20200902-803 Test details: https://qa-reports.linaro.org/lkft/linaro-hikey-stab

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2020-09-02 Thread Cong Wang
Hello, Kehuan Can you test the attached one-line fix? I think we are overthinking, probably all we need here is a busy wait. Thanks. diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h index d60e7c39d60c..fc1bacdb102b 100644 --- a/include/net/sch_generic.h +++ b/include/net/sch_gen

Re: linux-next: build failure after merge of the tip tree

2020-09-02 Thread Stephen Rothwell
Hi Ingo, On Thu, 3 Sep 2020 05:51:08 +0200 Ingo Molnar wrote: > > I've merged the old commit by mistake - it's removed now. Ah, OK, thanks. -- Cheers, Stephen Rothwell pgpqbzuw8G3mY.pgp Description: OpenPGP digital signature

Re: [PATCH] arm64: dts: qcom: sc7180: Add 'sustainable_power' for CPU thermal zones

2020-09-02 Thread Rajendra Nayak
On 9/2/2020 9:02 PM, Doug Anderson wrote: Hi, On Tue, Sep 1, 2020 at 10:36 PM Rajendra Nayak wrote: * In terms of the numbers here, I believe that you're claiming that we can dissipate 768 mW * 6 + 1202 mW * 2 = ~7 Watts of power. My memory of how much power we could dissipate in previou

[PATCH] HID: i2c-hid: Prefer asynchronous probe

2020-09-02 Thread Douglas Anderson
Adding printouts to the i2c_hid_probe() function shows that it takes quite some time. It used to take about 70 ms, but after commit eef4016243e9 ("HID: i2c-hid: Always sleep 60ms after I2C_HID_PWR_ON commands") it takes about 190 ms. This is not tons of time but it's not trivial. Because we have

Re: [PATCH v1 02/10] powerpc/kernel/iommu: Align size for IOMMU_PAGE_SIZE on iommu_*_coherent()

2020-09-02 Thread Alexey Kardashevskiy
On 02/09/2020 08:34, Leonardo Bras wrote: On Mon, 2020-08-31 at 10:47 +1000, Alexey Kardashevskiy wrote: Maybe testing with host 64k pagesize and IOMMU 16MB pagesize in qemu should be enough, is there any chance to get indirect mapping in qemu like this? (DDW but with smaller DMA window avai

Re: [PATCH v11 6/9] x86/cet: Add PTRACE interface for CET

2020-09-02 Thread Andy Lutomirski
> On Sep 2, 2020, at 7:53 PM, Yu, Yu-cheng wrote: > > On 9/2/2020 4:50 PM, Andy Lutomirski wrote: On Sep 2, 2020, at 3:13 PM, Yu, Yu-cheng wrote: >>> >>> On 9/2/2020 1:03 PM, Jann Horn wrote: > On Tue, Aug 25, 2020 at 2:30 AM Yu-cheng Yu wrote: > Add REGSET_CET64/REGSET_CET32

Re: [RFC PATCH v7 17/23] kernel/entry: Add support for core-wide protection of kernel-mode

2020-09-02 Thread Joel Fernandes
On Wed, Sep 2, 2020 at 12:57 PM Dario Faggioli wrote: > > On Wed, 2020-09-02 at 09:53 +0200, Thomas Gleixner wrote: > > On Tue, Sep 01 2020 at 21:29, Joel Fernandes wrote: > > > On Tue, Sep 01, 2020 at 10:02:10PM +0200, Thomas Gleixner wrote: > > > > > > > Or, are you saying users may want 'core s

Re: [PATCH v1 01/10] powerpc/pseries/iommu: Replace hard-coded page shift

2020-09-02 Thread Alexey Kardashevskiy
On 02/09/2020 07:38, Leonardo Bras wrote: On Mon, 2020-08-31 at 13:48 +1000, Alexey Kardashevskiy wrote: Well, I created this TCE_RPN_BITS = 52 because the previous mask was a hardcoded 40-bit mask (0xfful), for hard-coded 12-bit (4k) pagesize, and on PAPR+/LoPAR also defines TCE as h

Re: [PATCH net-next v2 3/3] net: dp83869: Add speed optimization feature

2020-09-02 Thread kernel test robot
dc1a9bf2c8169d9f607502162af1858a73a18cb8 config: i386-randconfig-m021-20200902 (attached as .config) compiler: gcc-9 (Debian 9.3.0-15) 9.3.0 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot smatch warnings: drivers/net/phy/dp83869.c:669 dp83869_config_init() warn

[PATCH RESEND 2/2] Revert "clk: qcom: Support 'protected-clocks' property"

2020-09-02 Thread Samuel Holland
Now that protected-clocks is handled in the clk core, this driver-specific implementation is redundant. This reverts commit b181b3b801da8893c8eb706e448dd5111b02de60. Signed-off-by: Samuel Holland --- drivers/clk/qcom/common.c | 18 -- 1 file changed, 18 deletions(-) diff --git

[PATCH RESEND 0/2] Common protected-clocks implementation

2020-09-02 Thread Samuel Holland
Stephen, Maxime, You previously asked me to implement the protected-clocks property in a driver-independent way: https://www.spinics.net/lists/arm-kernel/msg753832.html I provided an implementation 6 months ago, which I am resending now: https://patchwork.kernel.org/patch/11398629/ Do you have

[PATCH RESEND 1/2] clk: Implement protected-clocks for all OF clock providers

2020-09-02 Thread Samuel Holland
This is a generic implementation of the "protected-clocks" property from the common clock binding. It allows firmware to inform the OS about clocks that must not be disabled while the OS is running. This implementation comes with some caveats: 1) Clocks that have CLK_IS_CRITICAL in their init dat

Re: [PATCH 3/4] sh: Add SECCOMP_FILTER

2020-09-02 Thread Rich Felker
On Sat, Aug 29, 2020 at 01:09:43PM +0200, John Paul Adrian Glaubitz wrote: > Hi! > > On 8/29/20 2:49 AM, Rich Felker wrote: > > This restored my ability to use strace > > I can confirm that. However ... > > > and I've written and tested a minimal strace-like hack using > > SECCOMP_RET_USER_NOTIF

Re: linux-next: build failure after merge of the tip tree

2020-09-02 Thread Ingo Molnar
* Stephen Rothwell wrote: > Hi all, > > After merging the tip tree, today's linux-next build (powerpc > ppc64_defconfig) failed like this: > > > Caused by commit > > f670269a42bf ("x86: Fix early boot crash on gcc-10, next try") > > interacting with commit > > a9a3ed1eff36 ("x86: Fix

Re: [PATCH v3] staging: qlge: fix build breakage with dumping enabled

2020-09-02 Thread Benjamin Poirier
On 2020-09-02 22:00 +0800, Coiby Xu wrote: > This fixes commit 0107635e15ac > ("staging: qlge: replace pr_err with netdev_err") which introduced an > build breakage of missing `struct ql_adapter *qdev` for some functions > and a warning of type mismatch with dumping enabled, i.e., > > $ make CFLAG

Re: Boot failure on gru-scarlet-inx with 5.9-rc2

2020-09-02 Thread Samuel Dionne-Riel
On Wed, 2 Sep 2020 17:01:19 +0100 Lorenzo Pieralisi wrote: > On Tue, Sep 01, 2020 at 02:33:56PM -0400, Samuel Dionne-Riel wrote: > > Please print a pointer as a pointer and print both bus and > bus->parent. Hopefully pointer as a pointer is %px. Not sure what else, if that's wrong please tell.

Re: [PATCH 1/2] dma-mapping: introduce dma_get_seg_boundary_nr_pages()

2020-09-02 Thread Michael Ellerman
Nicolin Chen writes: > diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c > index 9704f3f76e63..cbc2e62db597 100644 > --- a/arch/powerpc/kernel/iommu.c > +++ b/arch/powerpc/kernel/iommu.c > @@ -236,15 +236,10 @@ static unsigned long iommu_range_alloc(struct device > *dev, >

[PATCH v4 2/3] scsi: 3w-9xxx: Reduce scope of structure packing

2020-09-02 Thread Samuel Holland
Currently, all command packet structs used by this driver are packed. However, only one (TW_SG_Entry) actually needs to be packed, because it uses 64-bit addresses at 32-bit alignment. To improve the quality of generated code, stop packing all of the other command packet structs. This requires adju

[PATCH v4 3/3] scsi: 3w-9xxx: Fix endianness issues in command packets

2020-09-02 Thread Samuel Holland
The controller expects all data it sends/receives to be little-endian. Therefore, the packet struct definitions should use the __le16/32/64 types. Once those are correct, sparse reports several issues with the driver code, which are fixed here as well. The main issue observed was at the call to sc

[PATCH v4 1/3] scsi: 3w-9xxx: Use flexible array members to avoid struct padding

2020-09-02 Thread Samuel Holland
In preparation for removing the "#pragma pack(1)" from the driver, fix all instances where a trailing array member could be replaced by a flexible array member. Since a flexible array member has zero size, it introduces no padding, whether or not the struct is packed. Signed-off-by: Samuel Holland

[PATCH] mtd: mtdoops: Don't write panic data twice

2020-09-02 Thread Mark Tomlinson
If calling mtdoops_write, don't also schedule work to be done later. Although this appears to not be causing an issue, possibly because the scheduled work will never get done, it is confusing. Fixes: 016c1291ce70 ("mtd: mtdoops: do not use mtd->panic_write directly") Signed-off-by: Mark Tomlinson

Re: [PATCH] ASoC: fsl_sai: Set SAI Channel Mode to Output Mode

2020-09-02 Thread Nicolin Chen
On Thu, Sep 03, 2020 at 11:09:15AM +0800, Shengjiu Wang wrote: > Transmit data pins will output zero when slots are masked or channels > are disabled. In CHMOD TDM mode, transmit data pins are tri-stated when > slots are masked or channels are disabled. When data pins are tri-stated, > there is noi

[RFC PATCH 3/4] usb: xhci-mtk: add support runtime pm

2020-09-02 Thread Chunfeng Yun
From: CK Hu add support runtime pm feature Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- drivers/usb/host/xhci-mtk.c | 446 +++- drivers/usb/host/xhci-mtk.h | 14 ++ 2 files changed, 455 insertions(+), 5 deletions(-) mode change 100644

[RFC PATCH 1/4] usb: xhci-mtk: improve bandwidth scheduling with multi-TT

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang After inserted the usb type-c 3.5mm dongle with headset, dmesg showed: usb 1-1.1: new full-speed USB device number 5 using xhci-mtk usb 1-1.1: New USB device found, idVendor=05ac, idProduct=110a, bcdDevice=26.11 usb 1-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber

[RFC PATCH 4/4] arm64: dts: mt8192: add SSUSB related nodes

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang Add SSUSB related nodes for mt8192 Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- Depends on: https://patchwork.kernel.org/patch/11713559/ [v4,1/3] arm64: dts: Add Mediatek SoC MT8192 and evaluation board dts and Makefile --- arch/arm64/boot/dts/mediatek/mt8

[RFC PATCH 2/4] usb: xhci-mtk: add mt8192 wakeup

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang need to add wakeup solution as V3 since not support presently. Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- drivers/usb/host/xhci-mtk.c | 9 + 1 file changed, 9 insertions(+) mode change 100644 => 100755 drivers/usb/host/xhci-mtk.c diff --git a/dr

[RFC PATCH 4/4] arm64: dts: mt8192: add SSUSB related nodes

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang Add SSUSB related nodes for mt8192 Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- Depends on: https://patchwork.kernel.org/patch/11713559/ [v4,1/3] arm64: dts: Add Mediatek SoC MT8192 and evaluation board dts and Makefile --- arch/arm64/boot/dts/mediatek/mt8

Re: [PATCH] ASoC: fsl_sai: Support multiple data channel enable bits

2020-09-02 Thread Nicolin Chen
On Tue, Sep 01, 2020 at 07:01:08PM +0800, Shengjiu Wang wrote: > One data channel is one data line. From imx7ulp, the SAI IP is > enhanced to support multiple data channels. > > If there is only two channels input and slots is 2, then enable one > data channel is enough for data transfer. So enabl

[RFC PATCH 3/4] usb: xhci-mtk: add support runtime pm

2020-09-02 Thread Chunfeng Yun
From: CK Hu add support runtime pm feature Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- drivers/usb/host/xhci-mtk.c | 446 +++- drivers/usb/host/xhci-mtk.h | 14 ++ 2 files changed, 455 insertions(+), 5 deletions(-) mode change 100644

[RFC PATCH 1/4] usb: xhci-mtk: improve bandwidth scheduling with multi-TT

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang After inserted the usb type-c 3.5mm dongle with headset, dmesg showed: usb 1-1.1: new full-speed USB device number 5 using xhci-mtk usb 1-1.1: New USB device found, idVendor=05ac, idProduct=110a, bcdDevice=26.11 usb 1-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber

[RFC PATCH 2/4] usb: xhci-mtk: add mt8192 wakeup

2020-09-02 Thread Chunfeng Yun
From: Zhanyong Wang need to add wakeup solution as V3 since not support presently. Signed-off-by: Zhanyong Wang Signed-off-by: Chunfeng Yun --- drivers/usb/host/xhci-mtk.c | 9 + 1 file changed, 9 insertions(+) mode change 100644 => 100755 drivers/usb/host/xhci-mtk.c diff --git a/dr

Re: [PATCH 0/2] dma-mapping: update default segment_boundary_mask

2020-09-02 Thread Nicolin Chen
On Wed, Sep 02, 2020 at 10:13:12AM +0200, Niklas Schnelle wrote: > On 9/2/20 12:16 AM, Nicolin Chen wrote: > > These two patches are to update default segment_boundary_mask. > > > > PATCH-1 fixes overflow issues in callers of dma_get_seg_boundary. > > Previous version was a series: https://lkml.or

[PATCH v3 4/9] dt-bindings: ARM: Mediatek: Document bindings for MT8192 Camera

2020-09-02 Thread Weiyi Lu
This patch adds the binding documentation of camsys-raw, camsys and imgsys for Mediatek MT8192. Signed-off-by: Weiyi Lu --- .../bindings/arm/mediatek/mediatek,camsys-raw.yaml | 54 ++ .../bindings/arm/mediatek/mediatek,camsys.txt | 1 + .../bindings/arm/mediatek/mediate

[PATCH v3 8/9] clk: mediatek: Add configurable enable control to mtk_pll_data

2020-09-02 Thread Weiyi Lu
In all MediaTek PLL design, bit0 of CON0 register is always the enable bit. However, there's a special case of usbpll on MT8192. The enable bit of usbpll is moved to bit2 of other register. Add configurable en_reg and pll_en_bit for enable control or default 0 where pll data are static variables. H

[PATCH v3 6/9] clk: mediatek: Add dt-bindings for MT8192 clocks

2020-09-02 Thread Weiyi Lu
Add MT8192 clock dt-bindings, include topckgen, apmixedsys, infracfg, pericfg and subsystem clocks. Signed-off-by: Weiyi Lu --- include/dt-bindings/clock/mt8192-clk.h | 592 + 1 file changed, 592 insertions(+) create mode 100644 include/dt-bindings/clock/mt8192-c

[PATCH v3 7/9] clk: mediatek: Fix asymmetrical PLL enable and disable control

2020-09-02 Thread Weiyi Lu
The en_mask actually is a combination of divider enable mask and pll enable bit(bit0). Before this patch, we enabled both divider mask and bit0 in prepare(), but only cleared the bit0 in unprepare(). Now, setting the enable register(CON0) in 2 steps: first divider mask, then bit0 during prepare(),

  1   2   3   4   5   6   7   8   9   10   >