Re: BUG: executor-detected bug

2019-01-30 Thread Tetsuo Handa
On 2019/01/29 3:33, syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:    30bac164aca7 Revert "Change mincore() to count "mapped" pa.. > git tree:   upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=11888d5f40 > kernel config: 

Re: [PATCH] ALSA: hda/tegra: enable clock during probe

2019-01-30 Thread Sameer Pujar
On 1/30/2019 4:09 PM, Takashi Iwai wrote: On Wed, 30 Jan 2019 10:35:35 +0100, Jon Hunter wrote: On 28/01/2019 06:06, Sameer Pujar wrote: On 1/25/2019 7:34 PM, Jon Hunter wrote: On 25/01/2019 13:58, Takashi Iwai wrote: On Fri, 25 Jan 2019 14:26:27 +0100, Jon Hunter wrote: On 25/01/2019

Re: [PATCH -next] bcache: Fix potential NULL pointer dereference

2019-01-30 Thread Kent Overstreet
On Wed, Jan 30, 2019 at 06:21:12PM +0800, YueHaibing wrote: > There is a potential NULL pointer dereference in case > kzalloc() fails and returns NULL. > > Fixes: bc082a55d25c ("bcache: fix inaccurate io state for detached bcache > devices") > Signed-off-by: YueHaibing > --- >

Re: [PATCH] phy: ti-pipe3: Add set_mode callback to configure usb3 phy as pcie phy

2019-01-30 Thread Kishon Vijay Abraham I
Hi Roger, On 30/01/19 4:18 PM, Roger Quadros wrote: > Hi Kishon, > > On 24/01/19 12:48, Kishon Vijay Abraham I wrote: >> DRA72 platform has the second instance of PHY shared between USB3 >> controller and PCIe controller with default as USB3 controller. >> Since it is used with USB3 controller

Re: [PATCH v2 2/2] x86/xen: dont add memory above max allowed allocation

2019-01-30 Thread William Kucharski
> On Jan 30, 2019, at 1:22 AM, Juergen Gross wrote: > > +#ifdef CONFIG_MEMORY_HOTPLUG > + /* > + * Don't allow adding memory not in E820 map while > + * booting the system. Once the balloon driver is up > + *

[tip:x86/cleanups] x86/hw_breakpoints, kprobes: Remove kprobes ifdeffery

2019-01-30 Thread tip-bot for Borislav Petkov
Commit-ID: fab940755d1d78377901450b6ee7c77356e06821 Gitweb: https://git.kernel.org/tip/fab940755d1d78377901450b6ee7c77356e06821 Author: Borislav Petkov AuthorDate: Sun, 27 Jan 2019 14:03:57 +0100 Committer: Borislav Petkov CommitDate: Wed, 30 Jan 2019 11:52:21 +0100

[PATCH v7 0/4] drm: add support for Cadence MHDP DPI/DP bridge.

2019-01-30 Thread Damian Kos
Hello! This is the series of patches that will add support for the Cadence's DPI/DP bridge. Please note that this is a preliminary version of the driver and there will be more patches in the future with updates, fixes and improvements. Please keep that in mind when looking at FIXME/TODO/XXX

[PATCH v7 2/4] drm/dp: fix link probing for devices supporting DP 1.4+

2019-01-30 Thread Damian Kos
From: Quentin Schulz DP 1.4 introduced a DP_EXTENDED_RECEIVER_CAP_FIELD_PRESENT bit in DP_TRAINING_AUX_RD_INTERVAL register. If set, DPCD registers from DP_DPCD_REV to DP_ADAPTER_CAP should be retrieved starting from DP_DPCD_REV_EXTENDED. All registers are copied except DP_DPCD_REV,

[PATCH v7 1/4] drm/rockchip: prepare common code for cdns and rk dpi/dp driver

2019-01-30 Thread Damian Kos
- Extracted common fields from cdn_dp_device to a new cdns_mhdp_device structure which will be used by two separate drivers later on. - Moved some datatypes (audio_format, audio_info, vic_pxl_encoding_format, video_info) from cdn-dp-core.c to cdn-dp-reg.h. - Changed prefixes from cdn_dp to

[PATCH 1/7] mmc: sdhci: add support for using external DMA devices

2019-01-30 Thread Chunyan Zhang
Some standard SD host controllers can support both external dma controllers as well as ADMA/SDMA in which the SD host controller acts as DMA master. TI's omap controller is the case as an example. Currently the generic SDHCI code supports ADMA/SDMA integrated in the host controller but does not

[PATCH v7 4/4] drm: bridge: add support for Cadence MHDP DPI/DP bridge

2019-01-30 Thread Damian Kos
From: Quentin Schulz This adds support for Cadence MHDP DPI to DP bridge. Basically, it takes a DPI stream as input and output it encoded in DP format. It supports SST and MST modes. Changes made in the low level driver (cdn-dp-reg.*): - moved it to from drivers/gpu/drm/rockchip to

[PATCH v7 3/4] dt-bindings: drm/bridge: Document Cadence MHDP bridge bindings

2019-01-30 Thread Damian Kos
From: Quentin Schulz Document the bindings used for the Cadence MHDP DPI/DP bridge. Signed-off-by: Quentin Schulz Signed-off-by: Damian Kos Reviewed-by: Rob Herring --- .../bindings/display/bridge/cdns,mhdp.txt | 47 +++ 1 file changed, 47 insertions(+) create mode

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread Tetsuo Handa
Hello, Omar. syzbot is reporting a crash due to dput(-EINVAL) [1]. I think the location is dir = debugfs_lookup(buts->name, blk_debugfs_root); if (!dir) bt->dir = dir = debugfs_create_dir(buts->name, blk_debugfs_root); added by commit 6ac93117ab009d39

[PATCH] kbuild: gitignore output directory

2019-01-30 Thread Vladimir Kondratiev
When compiling into output directory using O=, many files created under KBUILD_OUTPUT that git considers as new ones; git clients, ex. "git gui" lists it, and it clutters file list making it difficult to see what was really changed Generate .gitignore in output directory that ignores all its

Re: [kbuild-all] arch/x86/include/asm/cmpxchg.h:245:2: error: 'asm' operand has impossible constraints

2019-01-30 Thread Borislav Petkov
On Wed, Jan 30, 2019 at 11:28:40AM +0800, Rong Chen wrote: > we have added it to the blacklist, and there's no other configuration found > in the past reports. Thanks. We'll dig it out again if it becomes more prominent. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid

[PATCH v2 ] PM-runtime: fix deadlock with ktime

2019-01-30 Thread Vincent Guittot
A deadlock has been seen when swicthing clocksources which use PM runtime. The call path is: change_clocksource ... write_seqcount_begin ... timekeeping_update ... sh_cmt_clocksource_enable ... rpm_resume

Re: [PATCH v2] KVM: x86: Sync the pending Posted-Interrupts

2019-01-30 Thread Paolo Bonzini
On 30/01/19 11:38, Kang, Luwei wrote: This is not what I asked. You should instead do the check after pi_clear_sn. >>> >>> I think the SN has been cleared here before test the bitmap. >>> The SN will be set when the vCPU is schedule out. ID: >>>

[PATCH v2] Adding smp_acquire__after_ctrl_dep barrier

2019-01-30 Thread Elena Reshetova
Changes in v2: - hopefully fixed all (at least to my eye and to checkpatch) errors on whitespacing, etc. - changed text on ACQUIRE guarantees pointed by Andrea and Dmitry - removed mentioning of control dependency on dec/sub_and_test variants I also have to send it now with a cover

[PATCH] refcount_t: add ACQUIRE ordering on success for dec(sub)_and_test variants

2019-01-30 Thread Elena Reshetova
This adds an smp_acquire__after_ctrl_dep() barrier on successful decrease of refcounter value from 1 to 0 for refcount_dec(sub)_and_test variants and therefore gives stronger memory ordering guarantees than prior versions of these functions. Co-developed-by: Peter Zijlstra (Intel) Signed-off-by:

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread syzbot
syzbot has found a reproducer for the following crash on: HEAD commit:02495e76ded5 Add linux-next specific files for 20190130 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=116209ef40 kernel config: https://syzkaller.appspot.com/x/.config?x

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread Greg Kroah-Hartman
On Wed, Jan 30, 2019 at 08:11:17PM +0900, Tetsuo Handa wrote: > Hello, Omar. > > syzbot is reporting a crash due to dput(-EINVAL) [1]. I think the location is > > dir = debugfs_lookup(buts->name, blk_debugfs_root); > if (!dir) > bt->dir = dir =

[PATCH] x86/boot: Build the command line parsing code unconditionally (was: Re: [PATCH v16 0/7] Parse ACPI table and limit KASLR to choosing immovable memory)

2019-01-30 Thread Borislav Petkov
On Wed, Jan 30, 2019 at 01:58:47PM +0800, Chao Fan wrote: > I clone your branch and test some cases. Except the build issue of > cmdline_find_option(), PATCHSET works well. > Build in x86_64 and i386. > Tested EFI/BIOS environment in x86_64 and BIOS environment in i386. > Tested the 'acpi_rsdp='

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread Tetsuo Handa
On 2019/01/30 20:11, Tetsuo Handa wrote: > Hello, Omar. > > syzbot is reporting a crash due to dput(-EINVAL) [1]. I think the location is > > dir = debugfs_lookup(buts->name, blk_debugfs_root); > if (!dir) > bt->dir = dir = debugfs_create_dir(buts->name, >

Re: [PATCH 2/4] staging: android: ion: Restrict cache maintenance to dma mapped memory

2019-01-30 Thread Brian Starkey
Hi Liam, On Tue, Jan 29, 2019 at 03:44:53PM -0800, Liam Mark wrote: > On Fri, 18 Jan 2019, Liam Mark wrote: > > > On Fri, 18 Jan 2019, Andrew F. Davis wrote: > > > > > On 1/18/19 12:37 PM, Liam Mark wrote: > > > > The ION begin_cpu_access and end_cpu_access functions use the > > > >

Re: general protection fault in __dentry_path

2019-01-30 Thread syzbot
syzbot has found a reproducer for the following crash on: HEAD commit:02495e76ded5 Add linux-next specific files for 20190130 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=106161ef40 kernel config: https://syzkaller.appspot.com/x/.config?x

Re: [PATCH v6] x86: load FPU registers on return to userland

2019-01-30 Thread Borislav Petkov
On Wed, Jan 09, 2019 at 12:47:22PM +0100, Sebastian Andrzej Siewior wrote: > This is a refurbished series originally started by by Rik van Riel. The > goal is load the FPU registers on return to userland and not on every > context switch. By this optimisation we can: > - avoid loading the

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread Greg Kroah-Hartman
On Wed, Jan 30, 2019 at 08:26:24PM +0900, Tetsuo Handa wrote: > On 2019/01/30 20:11, Tetsuo Handa wrote: > > Hello, Omar. > > > > syzbot is reporting a crash due to dput(-EINVAL) [1]. I think the location > > is > > > > dir = debugfs_lookup(buts->name, blk_debugfs_root); > > if

Re: [PATCH V7 3/4] powerpc/mm/iommu: Allow migration of cma allocated pages during mm_iommu_do_alloc

2019-01-30 Thread Michael Ellerman
"Aneesh Kumar K.V" writes: > The current code doesn't do page migration if the page allocated is a > compound page. > With HugeTLB migration support, we can end up allocating hugetlb pages from > CMA region. Also, THP pages can be allocated from CMA region. This patch > updates > the code to

Re: [PATCH v2 2/2] phy: qualcomm: usb: Add Super-Speed PHY driver

2019-01-30 Thread Jorge Ramirez
On 1/30/19 10:53, Jorge Ramirez wrote: > On 1/29/19 21:27, Bjorn Andersson wrote: >> On Tue 29 Jan 03:35 PST 2019, Jorge Ramirez-Ortiz wrote: >>> diff --git a/drivers/phy/qualcomm/phy-qcom-usb-ss.c >>> b/drivers/phy/qualcomm/phy-qcom-usb-ss.c >>> new file mode 100644 >>> index 000..e6ae96e

Re: BUG: unable to handle kernel paging request in dput (2)

2019-01-30 Thread Greg Kroah-Hartman
On Wed, Jan 30, 2019 at 08:26:24PM +0900, Tetsuo Handa wrote: > On 2019/01/30 20:11, Tetsuo Handa wrote: > > Hello, Omar. > > > > syzbot is reporting a crash due to dput(-EINVAL) [1]. I think the location > > is > > > > dir = debugfs_lookup(buts->name, blk_debugfs_root); > > if

Re: [PATCH 16/22] x86/fpu: Always store the registers in copy_fpstate_to_sigframe()

2019-01-30 Thread Borislav Petkov
On Wed, Jan 09, 2019 at 12:47:38PM +0100, Sebastian Andrzej Siewior wrote: > From: Rik van Riel > > copy_fpstate_to_sigframe() stores the registers directly to user space. > This is okay because the FPU register are valid and saving it directly > avoids saving it into kernel memory and making a

Re: [PATCH v9 12/26] arm64: irqflags: Use ICC_PMR_EL1 for interrupt masking

2019-01-30 Thread Julien Thierry
On 23/01/2019 10:44, Julien Thierry wrote: > > > On 22/01/2019 15:21, Catalin Marinas wrote: >> On Mon, Jan 21, 2019 at 03:33:31PM +, Julien Thierry wrote: >>> diff --git a/arch/arm64/include/asm/irqflags.h >>> b/arch/arm64/include/asm/irqflags.h >>> index 24692ed..7e82a92 100644 >>> ---

Re: [PATCH 17/22] x86/fpu: Prepare copy_fpstate_to_sigframe() for TIF_NEED_FPU_LOAD

2019-01-30 Thread Borislav Petkov
On Wed, Jan 09, 2019 at 12:47:39PM +0100, Sebastian Andrzej Siewior wrote: > From: Rik van Riel > > The FPU registers need only to be saved if TIF_NEED_FPU_LOAD is not set. > Otherwise this has been already done and can be skipped. > > Signed-off-by: Rik van Riel > Signed-off-by: Sebastian

Re: [PATCH v8 0/8] Introduce the for_each_set_clump8 macro

2019-01-30 Thread Linus Walleij
On Wed, Jan 30, 2019 at 11:17 AM William Breathitt Gray wrote: > On Tue, Jan 29, 2019 at 05:07:34PM -0800, Andrew Morton wrote: > > Do we have any expectation that these facilities will be used by > > anything other than GPIO? If not then perhaps they should be sited > > within drivers/gpio

Re: [LSF/MM TOPIC] Page flags, can we free up space ?

2019-01-30 Thread David Hildenbrand
On 22.01.19 21:17, Jerome Glisse wrote: > So lattely i have been looking at page flags and we are using 6 flags > for memory reclaim and compaction: > > PG_referenced > PG_lru > PG_active > PG_workingset > PG_reclaim > PG_unevictable > > On top of which you can add the

Re: [PATCH 15/22] x86/entry: Add TIF_NEED_FPU_LOAD

2019-01-30 Thread Borislav Petkov
On Wed, Jan 09, 2019 at 12:47:37PM +0100, Sebastian Andrzej Siewior wrote: > Add TIF_NEED_FPU_LOAD. This is reserved for loading the FPU registers > before returning to userland. This flag must not be set for systems > without a FPU. > If this flag is cleared, the CPU's FPU register hold the

Re: [PATCH] mm: Prevent mapping typed pages to userspace

2019-01-30 Thread David Hildenbrand
On 29.01.19 06:38, Matthew Wilcox wrote: > Pages which use page_type must never be mapped to userspace as it would > destroy their page type. Add an explicit check for this instead of > assuming that kernel drivers always get this right. > > Signed-off-by: Matthew Wilcox > --- > mm/memory.c |

Re: [PATCH] futex: Handle early deadlock return correctly

2019-01-30 Thread Thomas Gleixner
On Tue, 29 Jan 2019, Thomas Gleixner wrote: > int __rt_mutex_start_proxy_lock(struct rt_mutex *lock, > struct rt_mutex_waiter *waiter, > struct task_struct *task) > { > int ret; > > + lockdep_asssert_held(>wait_lock); I'm a

Re: [PATCH v8 1/7] tpm: dynamically allocate the allocated_banks array

2019-01-30 Thread Jarkko Sakkinen
On Wed, Jan 30, 2019 at 08:52:40AM +0100, Roberto Sassu wrote: > On 1/29/2019 8:29 PM, Jarkko Sakkinen wrote: > > On Thu, Jan 24, 2019 at 04:49:04PM +0100, Roberto Sassu wrote: > > > + chip->allocated_banks = kcalloc(1, sizeof(*chip->allocated_banks), > > > +

Re: [PATCH] reset: Don't WARN if trying to get a used reset control

2019-01-30 Thread Philipp Zabel
Hi Thierry, On Mon, 2019-01-28 at 15:58 +0100, Thierry Reding wrote: > On Mon, Jan 28, 2019 at 12:26:48PM +0100, Philipp Zabel wrote: > > Hi Thierry, > > > > On Fri, 2019-01-25 at 11:15 +0100, Thierry Reding wrote: > > > From: Thierry Reding > > > > > > When requesting a reset control for

Re: [PATCH v6] x86: load FPU registers on return to userland

2019-01-30 Thread Sebastian Andrzej Siewior
On 2019-01-30 12:35:55 [+0100], Borislav Petkov wrote: > On Wed, Jan 09, 2019 at 12:47:22PM +0100, Sebastian Andrzej Siewior wrote: > > This is a refurbished series originally started by by Rik van Riel. The > > goal is load the FPU registers on return to userland and not on every > > context

Re: [RFD] A mount api that notices previous mounts

2019-01-30 Thread Karel Zak
On Tue, Jan 29, 2019 at 03:44:22PM -0600, Eric W. Biederman wrote: > so I am proposing we change this in the new mount api. Well, this forces me to ask what the new API is? :-) It seems that David uses fsconfig() and fsinfo() to set and get mount options, and your patch introduces fsset() and

Re: [PATCH v9 10/26] arm64: kvm: Unmask PMR before entering guest

2019-01-30 Thread Christoffer Dall
On Mon, Jan 21, 2019 at 03:33:29PM +, Julien Thierry wrote: > Interrupts masked by ICC_PMR_EL1 will not be signaled to the CPU. This > means that hypervisor will not receive masked interrupts while running a > guest. > You could add to the commit description how this works overall, something

Re: [PATCH v2 ] PM-runtime: fix deadlock with ktime

2019-01-30 Thread Ulf Hansson
On Wed, 30 Jan 2019 at 12:16, Vincent Guittot wrote: > > A deadlock has been seen when swicthing clocksources which use PM runtime. > The call path is: > change_clocksource > ... > write_seqcount_begin > ... > timekeeping_update > ... > sh_cmt_clocksource_enable >

Re: WARN_ON_ONCE(!new_owner) within wake_futex_pi() triggered

2019-01-30 Thread Thomas Gleixner
On Wed, 30 Jan 2019, Heiko Carstens wrote: > On Tue, Jan 29, 2019 at 06:16:53PM +0100, Sebastian Sewior wrote: > > if (unlikely(p->flags & PF_KTHREAD)) { > > put_task_struct(p); > > Last lines of the trace with your additional patch (full log attached): > ><...>-50539

Re: [PATCH 1/2] Revert "mm: don't reclaim inodes with many attached pages"

2019-01-30 Thread Chris Mason
On 29 Jan 2019, at 23:17, Dave Chinner wrote: > From: Dave Chinner > > This reverts commit a76cf1a474d7dbcd9336b5f5afb0162baa142cf0. > > This change causes serious changes to page cache and inode cache > behaviour and balance, resulting in major performance regressions > when combining

Re: [PATCH 0/4] powerpc/livepatch: reliable stack unwinder fixes

2019-01-30 Thread Michael Ellerman
Jiri Kosina writes: > On Tue, 22 Jan 2019, Joe Lawrence wrote: > >> This patchset fixes a false negative report (ie, unreliable) from the >> ppc64 reliable stack unwinder, discussed here [1] when it may >> inadvertently trip over a stale exception marker left on the stack. >> >> The first two

Re: [PATCH v2 1/2] staging: iio: ad7780: add gain & filter gpio support

2019-01-30 Thread Popa, Stefan Serban
On Du, 2019-01-27 at 18:30 -0200, Renato Lui Geh wrote: > Previously, the AD7780 driver only supported gpio for the 'powerdown' > pin. This commit adds suppport for the 'gain' and 'filter' pin. > > Signed-off-by: Renato Lui Geh > Signed-off-by: Giuliano Belinassi > Co-developed-by: Giuliano

Re: [PATCH] ALSA: hda/tegra: enable clock during probe

2019-01-30 Thread Jon Hunter
On 30/01/2019 10:56, Sameer Pujar wrote: > > On 1/30/2019 4:09 PM, Takashi Iwai wrote: >> On Wed, 30 Jan 2019 10:35:35 +0100, >> Jon Hunter wrote: >>> >>> On 28/01/2019 06:06, Sameer Pujar wrote: On 1/25/2019 7:34 PM, Jon Hunter wrote: > On 25/01/2019 13:58, Takashi Iwai wrote: >>

Re: [PATCH v6] x86: load FPU registers on return to userland

2019-01-30 Thread Borislav Petkov
On Wed, Jan 30, 2019 at 01:06:47PM +0100, Sebastian Andrzej Siewior wrote: > I don't know if hackbench would show anything besides noise. Yeah, if a sensible benchmark (dunno if hackbench is among them :)) shows no difference, is also saying something. -- Regards/Gruss, Boris. Good mailing

Re: [PATCH 1/4] powerpc/64s: Clear on-stack exception marker upon exception return

2019-01-30 Thread Michael Ellerman
Joe Lawrence writes: > From: Nicolai Stange > > The ppc64 specific implementation of the reliable stacktracer, > save_stack_trace_tsk_reliable(), bails out and reports an "unreliable > trace" whenever it finds an exception frame on the stack. Stack frames > are classified as exception frames if

Re: [PATCH v2 2/2] phy: qualcomm: usb: Add Super-Speed PHY driver

2019-01-30 Thread Jorge Ramirez
On 1/30/19 10:53, Jorge Ramirez wrote: >> +priv->vbus = devm_regulator_get_optional(priv->dev, "vbus"); > get_optional means that if vbus-supply is not found, rather than > returning a dummy regulator object this will fail with -ENODEV. on this subject, is it intentional that

Re: [PATCH 2/2] iommu/amd: Remove clear_flush_young notifier

2019-01-30 Thread Jean-Philippe Brucker
Hi Peter, On 30/01/2019 05:57, Peter Xu wrote: > AMD IOMMU driver is using the clear_flush_young() to do cache flushing > but that's actually already covered by invalidate_range(). Remove the > extra notifier and the chunks. Aren't uses of clear_flush_young() and invalidate_range() orthogonal?

Re: [PATCH 17/22] x86/fpu: Prepare copy_fpstate_to_sigframe() for TIF_NEED_FPU_LOAD

2019-01-30 Thread Sebastian Andrzej Siewior
On 2019-01-30 12:56:14 [+0100], Borislav Petkov wrote: > > diff --git a/arch/x86/kernel/fpu/signal.c b/arch/x86/kernel/fpu/signal.c > > index bf4e6caad305e..a25be217f9a2c 100644 > > --- a/arch/x86/kernel/fpu/signal.c > > +++ b/arch/x86/kernel/fpu/signal.c > > @@ -156,7 +156,16 @@ int

Re: [PATCH] mm/mincore: allow for making sys_mincore() privileged

2019-01-30 Thread Jiri Kosina
On Wed, 30 Jan 2019, Michal Hocko wrote: > > > I'm not sure why I'm the main recipient of that mail but answering > > > because I am -- let's get these patches in through the regular -mm > > > tree though > > > > *prod to mm maintainers* (at least for an opinion) > > Could you repost those

Re: [PATCH] refcount_t: add ACQUIRE ordering on success for dec(sub)_and_test variants

2019-01-30 Thread Andrea Parri
On Wed, Jan 30, 2019 at 01:18:51PM +0200, Elena Reshetova wrote: > This adds an smp_acquire__after_ctrl_dep() barrier on successful > decrease of refcounter value from 1 to 0 for refcount_dec(sub)_and_test > variants and therefore gives stronger memory ordering guarantees than > prior versions of

Re: [PATCH v2] powerpc/traps: fix the message printed when stack overflows

2019-01-30 Thread Michael Ellerman
Christophe Leroy writes: > Today's message is useless: > > [ 42.253267] Kernel stack overflow in process (ptrval), r1=c65500b0 > > This patch fixes it: > > [ 66.905235] Kernel stack overflow in process sh[356], r1=c65560b0 > > Fixes: ad67b74d2469 ("printk: hash addresses printed with %p") >

Re: [PATCH] PCI: Mediatek: Use resource_size function on resource object

2019-01-30 Thread Lorenzo Pieralisi
On Wed, Jan 02, 2019 at 02:03:53PM +0800, honghui.zh...@mediatek.com wrote: > From: Honghui Zhang > > drivers/pci/pcie-mediatek.c:720:13-16: WARNING: Suspicious code. > resource_size is maybe missing with mem > > Generated by: scripts/coccinelle/api/resource_size.cocci > > Signed-off-by:

[PATCH] csky: Fixup io-range page attribute for mmap("/dev/mem")

2019-01-30 Thread guoren
From: Guo Ren Some user space drivers need accessing IO address and IO remap need SO(strong order) page-attribute to make IO operation correct. So we need add SO-page-attr for all non-memory address. Signed-off-by: Guo Ren Reported-by: Fan Xiaodong --- arch/csky/include/asm/pgtable.h | 5

[patch 0/2] genirq, proc: Speedup /proc/stat interrupt statistics

2019-01-30 Thread Thomas Gleixner
Waiman reported that on large systems with a large amount of interrupts the readout of /proc/stat takes a long time to sum up the interrupt statistics. In principle this is not a problem. but for unknown reasons some enterprise quality software reads /proc/stat with a high frequency. The reason

[patch 2/2] proc/stat: Make the interrupt statistics more efficient

2019-01-30 Thread Thomas Gleixner
Waiman reported that on large systems with a large amount of interrupts the readout of /proc/stat takes a long time to sum up the interrupt statistics. In principle this is not a problem. but for unknown reasons some enterprise quality software reads /proc/stat with a high frequency. The reason

[patch 1/2] genriq: Avoid summation loops for /proc/stat

2019-01-30 Thread Thomas Gleixner
Waiman reported that on large systems with a large amount of interrupts the readout of /proc/stat takes a long time to sum up the interrupt statistics. In principle this is not a problem. but for unknown reasons some enterprise quality software reads /proc/stat with a high frequency. The reason

Re: [PATCH] phy: ti-pipe3: Add set_mode callback to configure usb3 phy as pcie phy

2019-01-30 Thread Roger Quadros
Kishon, On 30/01/19 12:59, Kishon Vijay Abraham I wrote: > Hi Roger, > > On 30/01/19 4:18 PM, Roger Quadros wrote: >> Hi Kishon, >> >> On 24/01/19 12:48, Kishon Vijay Abraham I wrote: >>> DRA72 platform has the second instance of PHY shared between USB3 >>> controller and PCIe controller with

Re: [PATCH] livepatch: core: Return ENOTSUPP instead of ENOSYS

2019-01-30 Thread Petr Mladek
On Tue 2019-01-29 10:50:54, Josh Poimboeuf wrote: > On Mon, Jan 28, 2019 at 02:49:43PM -0500, Joe Lawrence wrote: > > On Sun, Jan 27, 2019 at 04:26:30AM +0900, Alice Ferrazzi wrote: > > > This patch fixes a checkpatch warning: > > > WARNING: ENOSYS means 'invalid syscall nr' and nothing else >

Re: Question on handling managed IRQs when hotplugging CPUs

2019-01-30 Thread Thomas Gleixner
On Wed, 30 Jan 2019, John Garry wrote: > On 29/01/2019 17:20, Keith Busch wrote: > > On Tue, Jan 29, 2019 at 05:12:40PM +, John Garry wrote: > > > On 29/01/2019 15:44, Keith Busch wrote: > > > > > > > > Hm, we used to freeze the queues with CPUHP_BLK_MQ_PREPARE callback, > > > > which would

[PATCH 2/3] mm/filemap: initiate readahead even if IOCB_NOWAIT is set for the I/O

2019-01-30 Thread Vlastimil Babka
From: Jiri Kosina preadv2(RWF_NOWAIT) can be used to open a side-channel to pagecache contents, as it reveals metadata about residency of pages in pagecache. If preadv2(RWF_NOWAIT) returns immediately, it provides a clear "page not resident" information, and vice versa. Close that sidechannel

[PATCH 1/3] mm/mincore: make mincore() more conservative

2019-01-30 Thread Vlastimil Babka
From: Jiri Kosina The semantics of what mincore() considers to be resident is not completely clear, but Linux has always (since 2.3.52, which is when mincore() was initially done) treated it as "page is available in page cache". That's potentially a problem, as that [in]directly exposes

[PATCH 0/3] mincore() and IOCB_NOWAIT adjustments

2019-01-30 Thread Vlastimil Babka
I've collected the patches from the discussion for formal posting. The first two should be settled already, third one is the possible improvement I've mentioned earlier, where only in restricted case we resort to existence of page table mapping (the original and later reverted approach from Linus)

Re: [PATCH v2] ALSA: hda/tegra: enable clock during probe

2019-01-30 Thread Jon Hunter
On 25/01/2019 11:06, Sameer Pujar wrote: > If CONFIG_PM is disabled or runtime PM calls are forbidden, the clocks > will not be ON. This could cause issue during probe, where hda init > setup is done. This patch enables clocks unconditionally during probe. > > Along with above, follwoing

[PATCH 3/3] mm/mincore: provide mapped status when cached status is not allowed

2019-01-30 Thread Vlastimil Babka
After "mm/mincore: make mincore() more conservative" we sometimes restrict the information about page cache residency, which we have to do without breaking existing userspace, if possible. We thus fake the resulting values as 1, which should be safer than faking them as 0, as there might

[PATCH v7 03/28] x86/asm/suspend: use SYM_DATA for data

2019-01-30 Thread Jiri Slaby
Some global data in the suspend code were marked as `ENTRY'. ENTRY was intended for functions and shall be paired with ENDPROC. ENTRY also aligns symbols which creates unnecessary holes here between data. Since we are dropping historical markings, make proper use of newly added SYM_DATA in this

Re: [PATCH v2] firmware: imx: Add support to start/stop a CPU

2019-01-30 Thread Dong Aisheng
On Wed, Jan 30, 2019 at 5:59 PM Daniel Baluta wrote: > > This is done via RPC call to SCU. > > Signed-off-by: Daniel Baluta > --- > Changes since v1: > - remove unused variable ret > - add documentation for imx_sc_pm_cpu_start function > > drivers/firmware/imx/misc.c |

[PATCH v7 00/28] New macros for assembler symbols

2019-01-30 Thread Jiri Slaby
This series introduces new macros for assembly as was discussed [1]. The rationale is that now we use several undocumented random macros collected over time. There are even some defined for different architectures differently. In many cases, developers do not know the difference in semantics

[PATCH v7 23/28] x86_64/asm: change all ENTRY+END to SYM_CODE_*

2019-01-30 Thread Jiri Slaby
Here, we change all assembly code which is marked using END (and not ENDPROC). We switch all these to appropriate new markings SYM_CODE_START and SYM_CODE_END. Signed-off-by: Jiri Slaby Reviewed-by: Boris Ostrovsky [xen bits] Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc:

[PATCH v7 07/28] x86/asm/crypto: annotate local functions

2019-01-30 Thread Jiri Slaby
Use the newly added SYM_FUNC_START_LOCAL to annotate starts of all functions which do not have ".globl" annotation, but their ends are annotated by ENDPROC. This is needed to balance ENDPROC for tools that generate debuginfo. To be symmetric, we also convert their ENDPROCs to the new

[PATCH v7 01/28] linkage: new macros for assembler symbols

2019-01-30 Thread Jiri Slaby
Introduce new C macros for annotations of functions and data in assembly. There is a long-standing mess in macros like ENTRY, END, ENDPROC and similar. They are used in different manners and sometimes incorrectly. So introduce macros with clear use to annotate assembly as follows: a) Support

[PATCH v7 22/28] x86_64/asm: add ENDs to some functions and relabel with SYM_CODE_*

2019-01-30 Thread Jiri Slaby
All these are functions which are invoked from elsewhere, but they are not typical C functions. So we annotate them using the new SYM_CODE_START. All these were not balanced with any END, so mark their ends by SYM_CODE_END appropriatelly too. Signed-off-by: Jiri Slaby Reviewed-by: Boris

[PATCH v7 25/28] x86_32/asm: add ENDs to some functions and relabel with SYM_CODE_*

2019-01-30 Thread Jiri Slaby
All these are functions which are invoked from elsewhere, but they are not typical C functions. So we annotate them using the new SYM_CODE_START. All these were not balanced with any END, so mark their ends by SYM_CODE_END, appropriatelly. Signed-off-by: Jiri Slaby Reviewed-by: Boris Ostrovsky

[PATCH v7 21/28] x86/asm/ftrace: mark function_hook as function

2019-01-30 Thread Jiri Slaby
Relabel function_hook to be marked really as a function. It is called from C and has the same expectations towards the stack etc. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org --- arch/x86/kernel/ftrace_32.S | 4 ++-- 1 file changed, 2

[PATCH v7 24/28] x86_64/asm: change all ENTRY+ENDPROC to SYM_FUNC_*

2019-01-30 Thread Jiri Slaby
These are all functions which are invoked from elsewhere, so we annotate them as global using the new SYM_FUNC_START. And their ENDPROC's by SYM_FUNC_END. And make sure ENTRY/ENDPROC is not defined on X86_64, given these were the last users. Signed-off-by: Jiri Slaby Reviewed-by: Rafael J.

[PATCH v7 27/28] x86_32/asm: change all ENTRY+ENDPROC to SYM_FUNC_*

2019-01-30 Thread Jiri Slaby
These are all functions which are invoked from elsewhere, so we annotate them as global using the new SYM_FUNC_START. And their ENDPROC's by SYM_FUNC_END. Now, we can finally force ENTRY/ENDPROC to be undefined on X86. Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc:

[PATCH v7 26/28] x86_32/asm: change all ENTRY+END to SYM_CODE_*

2019-01-30 Thread Jiri Slaby
Here, we change all assembly code which is marked using END (and not ENDPROC). We switch all these to appropriate new markings SYM_CODE_START and SYM_CODE_END. And since we removed the last user of END on X86, make sure, that END is not defined there. Signed-off-by: Jiri Slaby Cc: Thomas

[PATCH v7 28/28] x86/asm: replace WEAK uses by SYM_INNER_LABEL_ALIGN

2019-01-30 Thread Jiri Slaby
Use the new SYM_INNER_LABEL_ALIGN for WEAK entries in the middle of x86 assembly functions. And make sure WEAK is not defined for x86 anymore as these were the last users. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org ---

[PATCH v7 17/28] x86/asm: use SYM_INNER_LABEL instead of GLOBAL

2019-01-30 Thread Jiri Slaby
GLOBAL had several meanings and is going away. In this patch, convert all the inner function labels marked with GLOBAL to use SYM_INNER_LABEL instead. Note that retint_user needs not be global, perhaps since commit 2ec67971facc ("x86/entry/64/compat: Remove most of the fast system call

[PATCH v7 02/28] x86/asm/suspend: drop ENTRY from local data

2019-01-30 Thread Jiri Slaby
ENTRY was intended for functions and shall be paired with ENDPROC. ENTRY also aligns symbols which creates unnecessary holes here between data. So drop ENTRY from saved_eip in wakeup_32 and many saved_* in wakeup_64, as these symbols are local only. We could use SYM_DATA_LOCAL for these symbols,

[PATCH v7 20/28] x86/asm: make some functions local

2019-01-30 Thread Jiri Slaby
There is a couple of assembly functions, which are invoked only locally in the file they are defined. In C, we mark them "static". In assembly, annotate them using SYM_{FUNC,CODE}_START_LOCAL (and switch their ENDPROC to SYM_{FUNC,CODE}_END too). Whether we use FUNC or CODE, depends on whether

[PATCH v7 19/28] x86/asm: kill the last GLOBAL user and remove the macro

2019-01-30 Thread Jiri Slaby
Convert the remaining 32bit users and remove GLOBAL macro finally. In particular, this means to use SYM_ENTRY for the singlestepping hack region. Exclude the global definition of GLOBAL from x86 too. Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc:

[PATCH v7 18/28] x86/asm/realmode: use SYM_DATA_* instead of GLOBAL

2019-01-30 Thread Jiri Slaby
GLOBAL had several meanings and is going away. In this patch, convert all the data marked using GLOBAL to use SYM_DATA_START or SYM_DATA instead. Notes: * SYM_DATA_END_LABEL is used to generate tr_gdt_end too. * wakeup_idt is marked as LOCAL now as it is used only locally. Signed-off-by: Jiri

[PATCH v7 15/28] x86/asm/purgatory: start using annotations

2019-01-30 Thread Jiri Slaby
purgatory used no annotations at all. So include linux/linkage.h and annotate everything: * code by SYM_CODE_* * data by SYM_DATA_* Signed-off-by: Jiri Slaby Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H. Peter Anvin" Cc: x...@kernel.org --- arch/x86/purgatory/entry64.S | 21

[PATCH v7 16/28] x86/asm: do not annotate functions by GLOBAL

2019-01-30 Thread Jiri Slaby
GLOBAL is an x86's custom macro and is going to die very soon. It was meant for global symbols, but here, it was used for functions. Instead, use the new macros SYM_FUNC_START* and SYM_CODE_START* (depending on the type of a function) which are dedicated for global functions. And since they both

[PATCH v7 13/28] um: annotate data appropriatelly

2019-01-30 Thread Jiri Slaby
Use the new SYM_DATA_START and SYM_DATA_END_LABEL macros for vdso_start. We get: 2376 OBJECT GLOBAL DEFAULT4 vdso_start 0948 0 OBJECT GLOBAL DEFAULT4 vdso_end Signed-off-by: Jiri Slaby Cc: Jeff Dike Cc: Richard Weinberger Cc: Thomas Gleixner Cc: Ingo Molnar Cc: "H.

[PATCH v7 12/28] x86/boot/compressed: annotate data appropriatelly

2019-01-30 Thread Jiri Slaby
Use the new SYM_DATA, SYM_DATA_START, and SYM_DATA_END* macros for data. Now, the data in the object file look sane: Value Size TypeBind Vis Ndx Name 10 OBJECT GLOBAL DEFAULT3 efi32_boot_gdt 000a10 OBJECT LOCAL DEFAULT3 save_gdt 0014 8 OBJECT LOCAL

[PATCH v7 11/28] x86/asm/head: annotate data appropriatelly

2019-01-30 Thread Jiri Slaby
Use the new SYM_DATA, SYM_DATA_START, and SYM_DATA_END in both 32 and 64 bit heads. In the 64-bit version, define also SYM_DATA_START_PAGE_ALIGNED locally using the new SYM_START. It is used in the code instead of NEXT_PAGE() which was defined in this file and has been using the obsolete macro

[PATCH v7 14/28] xen/pvh: annotate data appropriatelly

2019-01-30 Thread Jiri Slaby
Use the new SYM_DATA_START_LOCAL, and SYM_DATA_END* macros to have: 8 OBJECT LOCAL DEFAULT6 gdt 000832 OBJECT LOCAL DEFAULT6 gdt_start 0028 0 OBJECT LOCAL DEFAULT6 gdt_end 0028 256 OBJECT LOCAL DEFAULT6 early_stack 0128 0 OBJECT LOCAL

[PATCH v7 05/28] x86/asm/entry: annotate THUNKs

2019-01-30 Thread Jiri Slaby
Place SYM_*_START_NOALIGN and SYM_*_END around the THUNK macro body. Preserve @function by FUNC (64bit) and CODE (32bit). Given it was not marked as aligned, use NOALIGN. The common tail .L_restore is put inside SYM_CODE_START_LOCAL_NOALIGN and SYM_CODE_END too. The result: Value Size Type

答复: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-30 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Greg KH > 发送时间: 2019年1月30日 18:19 > 收件人: Li,Rongqing > 抄送: jsl...@suse.com; linux-kernel@vger.kernel.org; gko...@codeaurora.org > 主题: Re: [PATCH][v4] tty: fix race between flush_to_ldisc

[PATCH v7 08/28] x86/boot/compressed: annotate local functions

2019-01-30 Thread Jiri Slaby
relocated, paging_enabled, and no_longmode are self-standing local functions, annotate them as such. paging_enabled is annotated as NOALIGN, since the trampoline code has to be compact. Signed-off-by: Jiri Slaby Cc: "H. Peter Anvin" Cc: Thomas Gleixner Cc: Ingo Molnar Cc: x...@kernel.org ---

[PATCH v7 06/28] x86/asm: annotate local pseudo-functions

2019-01-30 Thread Jiri Slaby
Use the newly added SYM_CODE_START_LOCAL* to annotate starts of all pseudo-functions (those ending END until now) which do not have ".globl" annotation. This is needed to balance END for tools that generate debuginfo. Note that we switch from END to SYM_CODE_END too so that everybody can see the

[PATCH v7 10/28] x86/asm/entry: annotate interrupt symbols properly

2019-01-30 Thread Jiri Slaby
* annotate functions properly by SYM_CODE_START, SYM_CODE_START_LOCAL* and SYM_CODE_END -- these are not C-like functions, so we have to annotate them using CODE. * use SYM_INNER_LABEL* for labels being in the middle of other functions [v4] alignments preserved Signed-off-by: Jiri Slaby Cc:

Re: [RFD] A mount api that notices previous mounts

2019-01-30 Thread Eric W. Biederman
ebied...@xmission.com (Eric W. Biederman) writes: > ebied...@xmission.com (Eric W. Biederman) writes: > >> Casey Schaufler writes: >>> Are you taking the LSM specific mount options into account? >> >> In the design yes, and I allow setting them. It appears in the code >> to retrieve the mount

<    1   2   3   4   5   6   7   8   9   10   >