Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Jiri Kosina
On Wed, 3 Jan 2018, Dan Williams wrote: > Speaking from a purely Linux kernel maintenance process perspective we > play wack-a-mole with missed endian conversions and other bugs that > coccinelle, sparse, etc help us catch. Fully agreed. > So this is in that same category, but yes, it's inconve

[PATCH v2 04/12] x86/retpoline/ftrace: Convert ftrace assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in ftrace assembler code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/kernel/ftrace_32.S | 3 ++- arch/x86/kernel/ftrace_64.S | 6 +++--- 2 files changed, 5 insertions(+), 4

[PATCH v2 09/12] x86/retpoline: Finally enable retpoline for C code

2018-01-03 Thread Andi Kleen
From: Dave Hansen From: David Woodhouse Add retpoline compile option in Makefile Update Makefile with retpoline compile options. This requires a gcc with the retpoline compiler patches enabled. Print a warning when the compiler doesn't support retpoline [Originally from David and Tim, but h

[PATCH v2 10/12] retpoline/taint: Taint kernel for missing retpoline in compiler

2018-01-03 Thread Andi Kleen
From: Andi Kleen When the kernel or a module hasn't been compiled with a retpoline aware compiler, print a warning and set a taint flag. For modules it is checked at compile time, however it cannot check assembler or other non compiled objects used in the module link. Due to lack of better lett

Avoid speculative indirect calls in kernel

2018-01-03 Thread Andi Kleen
This is a fix for Variant 2 in https://googleprojectzero.blogspot.com/2018/01/reading-privileged-memory-with-side.html Any speculative indirect calls in the kernel can be tricked to execute any kernel code, which may allow side channel attacks that can leak arbitrary kernel data. So we want to

[PATCH v2 11/12] retpoline/objtool: Disable some objtool warnings

2018-01-03 Thread Andi Kleen
From: Andi Kleen With the indirect call thunk enabled compiler two objtool warnings are triggered very frequently and make the build very noisy. I don't see a good way to avoid them, so just disable them for now. Signed-off-by: Andi Kleen --- tools/objtool/check.c | 11 +++ 1 file cha

[PATCH v2 07/12] x86/retpoline/checksum32: Convert assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in 32bit checksum assembler code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/lib/checksum_32.S | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/arch

[PATCH v2 02/12] x86/retpoline/crypto: Convert crypto assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in crypto assembler code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/crypto/aesni-intel_asm.S| 5 +++-- arch/x86/crypto/camellia-aesni-avx-asm_64.S | 3 ++- ar

[PATCH v2 03/12] x86/retpoline/entry: Convert entry assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in core 32/64bit entry assembler code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/entry/entry_32.S | 5 +++-- arch/x86/entry/entry_64.S | 12 +++- 2 files changed,

[PATCH v2 01/12] x86/retpoline: Define retpoline indirect thunk and macros

2018-01-03 Thread Andi Kleen
From: Dave Hansen From: David Woodhouse retpoline is a special sequence on Intel CPUs to stop speculation for indirect branches. Provide assembler infrastructure to use retpoline by the compiler and for assembler. We add the out of line trampoline used by the compiler, and NOSPEC_JUMP / NOSPEC

[PATCH v2 12/12] retpoline: Attempt to quiten objtool warning for unreachable code

2018-01-03 Thread Andi Kleen
From: Andi Kleen The speculative jump trampoline has to contain unreachable code. objtool keeps complaining arch/x86/lib/retpoline.o: warning: objtool: __x86.indirect_thunk()+0x8: unreachable instruction I tried to fix it here by adding ASM_UNREACHABLE annotation (after supporting them for pur

[PATCH v2 06/12] x86/retpoline/crypto: Convert xen assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in xen inline assembler code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/crypto/camellia-aesni-avx2-asm_64.S | 1 + arch/x86/include/asm/xen/hypercall.h | 3 ++- 2

[PATCH v2 05/12] x86/retpoline/hyperv: Convert assembler indirect jumps

2018-01-03 Thread Andi Kleen
From: Andi Kleen Convert all indirect jumps in hyperv inline asm code to use non speculative sequences. Based on code from David Woodhouse and Tim Chen Signed-off-by: Andi Kleen --- arch/x86/include/asm/mshyperv.h | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/ar

Re: [Ocfs2-devel] [PATCH v2 2/2] ocfs2: add trimfs lock to avoid duplicated trims in cluster

2018-01-03 Thread Gang He
Hi Alex, >>> > Hi Gang, > > On 2017/12/14 13:14, Gang He wrote: >> As you know, ocfs2 has support trim the underlying disk via >> fstrim command. But there is a problem, ocfs2 is a shared disk >> cluster file system, if the user configures a scheduled fstrim >> job on each file system node, thi

Re: Avoid speculative indirect calls in kernel

2018-01-03 Thread Paolo Bonzini
On 04/01/2018 02:59, Alan Cox wrote: >> But then, exactly because the retpoline approach adds quite some cruft >> and leaves something to be desired, why even bother? > > Performance Dunno. If I care about mitigating this threat, I wouldn't stop at retpolines even if the full solution has pretty

Re: [PATCH v2 01/12] x86/retpoline: Define retpoline indirect thunk and macros

2018-01-03 Thread Brian Gerst
On Wed, Jan 3, 2018 at 9:00 PM, Andi Kleen wrote: > From: Dave Hansen > > From: David Woodhouse > > retpoline is a special sequence on Intel CPUs to stop speculation for > indirect branches. > > Provide assembler infrastructure to use retpoline by the compiler > and for assembler. We add the out

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Alan Cox
> Disagreed, violently. CPU has to execute the instructions I ask it to > execute, and if it executes *anything* else that reveals any information > about the instructions that have *not* been executed, it's flawed. Then stick to in order processors. Just don't be in a hurry to get your computat

Re: [RFC] pwm-backlight: Allow backlight to remain disabled on boot

2018-01-03 Thread hl
Hi All,     Since many panel power sequence request backlight stay disable before panel power ready, but with now pwm-backlight drvier, it default to enable backlight when pwm-backlight probe, it mess up the panel power sequence. So we need this patch. This patch have been fly for a long tim

[PATCH V2 2/5] usb: serial: f81534: add auto RTS direction support

2018-01-03 Thread Ji-Ze Hong (Peter Hong)
The F81532/534 had auto RTS direction support for RS485 mode. We'll read it from internal Flash with address 0x2f01~0x2f04 for 4 ports. There are 4 conditions below: 0: F81534_PORT_CONF_RS232. 1: F81534_PORT_CONF_RS485. 2: value error, default to F81534_PORT_CONF_RS232.

[PATCH V2 4/5] usb: serial: f81534: add H/W disable port support

2018-01-03 Thread Ji-Ze Hong (Peter Hong)
The F81532/534 can be disable port by manufacturer with following H/W design. 1: Connect DCD/DSR/CTS/RI pin to ground. 2: Connect RX pin to ground. In driver, we'll implements some detect method likes following: 1: Read MSR. 2: Turn MCR LOOP bit on, off and read LSR after delay wit

[PATCH V2 3/5] usb: serial: f81534: add output pin control

2018-01-03 Thread Ji-Ze Hong (Peter Hong)
The F81532/534 had 3 output pin (M0/SD, M1, M2) with open-drain mode to control transceiver. We'll read it from internal Flash with address 0x2f05~0x2f08 for 4 ports. The value is range from 0 to 7. The M0/SD is MSB of this value. For a examples, If read value is 6, we'll write M0/SD, M1, M2 as 1,

[PATCH V2 1/5] usb: serial: f81534: add high baud rate support

2018-01-03 Thread Ji-Ze Hong (Peter Hong)
The F81532/534 had 4 clocksource 1.846/18.46/14.77/24MHz and baud rates can be up to 1.5Mbits with 24MHz. This device may generate data overrun when baud rate setting to 921600bps or higher with old UART trigger level setting (8x14=112) with full loading. We'll change trigger level from 8x14=112 t

[PATCH V2 5/5] usb: serial: f81534: fix tx error on some baud rate

2018-01-03 Thread Ji-Ze Hong (Peter Hong)
The F81532/534 had 4 clocksource 1.846/18.46/14.77/24MHz and baud rates can be up to 1.5Mbits with 24MHz. But on some baud rate (384~500kps), the TX side will send the data frame too close to treat frame error on RX side. This patch will force all TX data frame with delay 1bit gap. Signed-off-by:

Re: [PATCH v2 01/12] x86/retpoline: Define retpoline indirect thunk and macros

2018-01-03 Thread Alan Cox
> > +ENTRY(__x86.indirect_thunk) > > + CFI_STARTPROC > > + callretpoline_call_target > > +2: > > + lfence /* stop speculation */ > > + jmp 2b > > +retpoline_call_target: > > +#ifdef CONFIG_64BIT > > + lea 8(%rsp), %rsp > > +#else > > + lea

Re: CONFIG_PAGE_TABLE_ISOLATION=y on x86_64 causes gcc to segfault when building x86_32 binaries

2018-01-03 Thread Boris Ostrovsky
On 01/03/2018 01:52 PM, Thomas Gleixner wrote: > On Wed, 3 Jan 2018, Thomas Gleixner wrote: > >> On Wed, 3 Jan 2018, Lars Wendler wrote: >>> Am Wed, 3 Jan 2018 13:05:38 +0100 (CET) >>> schrieb Thomas Gleixner : Also can you please try Linus v4.15-rc6 with PTI enabled so we can see whether

Re: [PATCH 4.13 28/43] SMB3: Validate negotiate request must always be signed

2018-01-03 Thread Srivatsa S. Bhat
On 11/1/17 8:18 AM, Greg Kroah-Hartman wrote: > On Tue, Oct 31, 2017 at 03:02:11PM +0200, Thomas Backlund wrote: >> Den 31.10.2017 kl. 11:55, skrev Greg Kroah-Hartman: >>> 4.13-stable review patch. If anyone has any objections, please let me know. >>> >>> -- >>> >>> From: Steve Fre

Re: [PATCH V3 04/12] perf mmap: introduce perf_mmap__read_done

2018-01-03 Thread Namhyung Kim
Hi Kan, On Wed, Jan 03, 2018 at 02:15:38PM +, Liang, Kan wrote: > > Hello, > > > > On Thu, Dec 21, 2017 at 10:08:46AM -0800, kan.li...@intel.com wrote: > > > From: Kan Liang > > > > > > The direction of overwrite mode is backward. The last mmap__read_event > > > will set tail to map->prev. N

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Williams, Dan J
On Wed, 2018-01-03 at 17:54 -0800, Linus Torvalds wrote: > On Wed, Jan 3, 2018 at 5:51 PM, Dan Williams m> wrote: > > > > Elena has done the work of auditing static analysis reports to a > > dozen > > or so locations that need some 'nospec' handling. > > I'd love to see that patch, just to see h

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Alexei Starovoitov
On Thu, Jan 04, 2018 at 02:15:53AM +, Alan Cox wrote: > > > > Elena has done the work of auditing static analysis reports to a dozen > > > or so locations that need some 'nospec' handling. > > > > How exactly is that related (especially in longer-term support terms) to > > BPF anyway? > >

[PATCH net-next V2 1/2] tun/tap: use ptr_ring instead of skb_array

2018-01-03 Thread Jason Wang
This patch switches to use ptr_ring instead of skb_array. This will be used to enqueue different types of pointers by encoding type into lower bits. Signed-off-by: Jason Wang --- drivers/net/tap.c | 41 + drivers/net/tun.c | 42 ++

[PATCH net-next V2 2/2] tuntap: XDP transmission

2018-01-03 Thread Jason Wang
This patch implements XDP transmission for TAP. Since we can't create new queues for TAP during XDP set, exist ptr_ring was reused for queuing XDP buffers. To differ xdp_buff from sk_buff, TUN_XDP_FLAG (0x1UL) was encoded into lowest bit of xpd_buff pointer during ptr_ring_produce, and was decoded

[PATCH net-next V2 0/2] XDP transmission for tuntap

2018-01-03 Thread Jason Wang
Hi all: This series tries to implement XDP transmission (ndo_xdp_xmit) for tuntap. Pointer ring was used for queuing both XDP buffers and sk_buff, this is done by encoding the type into lowest bit of the pointer and storin XDP metadata in the headroom of XDP buff. Tests gets 3.05 Mpps when doing

Re: Regression: kexec/kdump boot hangs with x86/vector commits

2018-01-03 Thread Dave Young
On 12/14/17 at 05:24pm, Dave Young wrote: > On 12/13/17 at 11:57pm, Yu Chen wrote: > > On Wed, Dec 13, 2017 at 10:52:56AM +0800, Dave Young wrote: > > > Hi, > > > > > > Kexec reboot and kdump has broken on my laptop for long time with > > > 4.15.0-rc1+ kernels. With the patch below an early panic

[PATCH] cpufreq: stats: Change return type of cpufreq_stats_update() as void

2018-01-03 Thread Viresh Kumar
It always returns 0 and none of its callers check its return value. Make it return void. Signed-off-by: Viresh Kumar --- drivers/cpufreq/cpufreq_stats.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/cpufreq/cpufreq_stats.c b/drivers/cpufreq/cpufreq_stats.c index 1

Re: [Ocfs2-devel] [PATCH v3 2/3] ocfs2: add ocfs2_overwrite_io function

2018-01-03 Thread Gang He
Hi Alex, >>> > Hi Gang, > > On 2018/1/3 13:14, Gang He wrote: >> Hi Alex, >> >> > >>> Hi Gang, >>> >>> On 2017/12/28 18:07, Gang He wrote: Add ocfs2_overwrite_io function, which is used to judge if overwrite allocated blocks, otherwise, the write will bring extra block allo

RE: [Intel-wired-lan] [PATCH] igb: Delete an error message for a failed memory allocation in igb_enable_sriov()

2018-01-03 Thread Brown, Aaron F
> From: Intel-wired-lan [mailto:intel-wired-lan-boun...@osuosl.org] On > Behalf Of SF Markus Elfring > Sent: Monday, January 1, 2018 11:57 AM > To: net...@vger.kernel.org; intel-wired-...@lists.osuosl.org; Kirsher, > Jeffrey T > Cc: kernel-janit...@vger.kernel.org; LKML > Subject: [Intel-wired-la

Re: [PATCH] doc: memory-barriers: reStructure Text

2018-01-03 Thread afzal mohammed
Hi, On Thu, Jan 04, 2018 at 12:48:28AM +0100, Peter Zijlstra wrote: > > Let PDF & HTML's be created out of memory-barriers Text by > > reStructuring. > So I hate this rst crap with a passion, so NAK from me. Okay, the outcome is exactly as was feared. Abondoning the patch, let this be > /dev/n

[PATCH v2] f2fs: check segment type in __f2fs_replace_block

2018-01-03 Thread Yunlong Song
Signed-off-by: Yunlong Song --- fs/f2fs/segment.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c index 890d483..e3bbabf 100644 --- a/fs/f2fs/segment.c +++ b/fs/f2fs/segment.c @@ -2719,6 +2719,8 @@ void __f2fs_replace_block(struct f2fs_sb_info *sbi, st

Re: [PATCH] scsi: sd: Use warn for logs about no caching info

2018-01-03 Thread Martin K. Petersen
Hi Jeremy, > When no caching mode information can be found for a disk, use the > warning log level rather than error. It is common for this to occur > with cheap USB sticks. Just because something is common occurrence doesn't mean it's not an error. What's the rationale behind demoting this to a

Re: [PATCH] scsi: lpfc: don't dereference localport before it has been null checked

2018-01-03 Thread Martin K. Petersen
Colin, > localport is being dereferenced to assign lport and then immediately > afterwards localport is being sanity checked to see if it is null. > Fix this by only dereferencing localport until after it has been > null checked. Applied to 4.16/scsi-queue, thanks! -- Martin K. Petersen O

Re: [PATCH] scsi: lpfc: fix a couple of minor indentation issues

2018-01-03 Thread Martin K. Petersen
Colin, > Several statements are indented too far, fix these Applied to 4.16/scsi-queue. -- Martin K. Petersen Oracle Linux Engineering

RE: [PATCH -next] irqchip/ompic: fix return value check in ompic_of_init()

2018-01-03 Thread weiyongjun (A)
On Wed, Jan 03, 2018 10:41 PM, Stafford Horne wrote: > On Tue, Jan 02, 2018 at 11:47:19AM +, Wei Yongjun wrote: > > In case of error, the function ioremap() returns NULL pointer not > > ERR_PTR(). The IS_ERR() test in the return value check should be > > replaced with NULL test. > > Thanks, I

Re: [PATCH v5 7/9] arm64: Topology, rename cluster_id

2018-01-03 Thread Xiongfeng Wang
On 2018/1/4 1:32, Jeremy Linton wrote: > Hi, > > On 01/03/2018 08:29 AM, Sudeep Holla wrote: >> >> On 02/01/18 02:29, Xiongfeng Wang wrote: >>> Hi, >>> >>> On 2017/12/18 20:42, Morten Rasmussen wrote: On Fri, Dec 15, 2017 at 10:36:35AM -0600, Jeremy Linton wrote: > Hi, > > On 12

Re: [PATCH] doc: memory-barriers: reStructure Text

2018-01-03 Thread afzal mohammed
Hi, On Thu, Jan 04, 2018 at 09:48:50AM +0800, Boqun Feng wrote: > > The location chosen is "Documentation/kernel-hacking", i was unsure > > where this should reside & there was no .rst file in top-level directory > > "Documentation", so put it into one of the existing folder that seemed > > to me

Re: [PATCH] nvme: check ctrl.tagset before start ns scan

2018-01-03 Thread jianchao.wang
Hi sagi Many thanks for your kindly response. On 01/03/2018 05:37 PM, Sagi Grimberg wrote: > Hi Jianchao, > >> ctrl.tagset maybe NULL due to failure of io queue setup or blk-mq >> tagset allocation in nvme_reset_work. Then panic would come up. >> To fix this, just add ctrl.tagset check in nvme_s

Re: [PATCH 4.9 00/39] 4.9.75-stable review

2018-01-03 Thread Hugh Dickins
On Wed, Jan 3, 2018 at 5:24 PM, Ben Hutchings wrote: > On Wed, 2018-01-03 at 21:11 +0100, Greg Kroah-Hartman wrote: >> This is the start of the stable review cycle for the 4.9.75 release. >> There are 39 patches in this series, all will be posted as a response >> to this one. If anyone has any is

Re: [PATCH v5 7/9] arm64: Topology, rename cluster_id

2018-01-03 Thread Xiongfeng Wang
On 2018/1/4 1:32, Jeremy Linton wrote: > Hi, > > On 01/03/2018 08:29 AM, Sudeep Holla wrote: >> >> On 02/01/18 02:29, Xiongfeng Wang wrote: >>> Hi, >>> >>> On 2017/12/18 20:42, Morten Rasmussen wrote: On Fri, Dec 15, 2017 at 10:36:35AM -0600, Jeremy Linton wrote: > Hi, > > On 12

[PATCH V7] mmc:host:sdhci-pci:Addition of Arasan PCI Controller with integrated phy.

2018-01-03 Thread Atul Garg
The Arasan Controller is based on a FPGA platform and has integrated phy with specific registers used during initialization and management of different modes. The phy and the controller are integrated and registers are very specific to Arasan. Arasan being an IP provider, licenses these IPs to var

Re: [PATCH 4.9 00/39] 4.9.75-stable review

2018-01-03 Thread Andy Lutomirski
On Wed, Jan 3, 2018 at 8:07 PM, Hugh Dickins wrote: > On Wed, Jan 3, 2018 at 5:24 PM, Ben Hutchings wrote: >> On Wed, 2018-01-03 at 21:11 +0100, Greg Kroah-Hartman wrote: >>> This is the start of the stable review cycle for the 4.9.75 release. >>> There are 39 patches in this series, all will be

[GIT PULL] isolation: 1Hz residual tick offloading v3

2018-01-03 Thread Frederic Weisbecker
Ingo, Please pull the sched/0hz branch that can be found at: git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks.git sched/0hz HEAD: 9e932b2cc707209febd130978a5eb9f4a943a3f4 -- Now that scheduler_tick() has become resilient towards the absence of ticks, current->sched_

[PATCH 4/5] sched/isolation: Residual 1Hz scheduler tick offload

2018-01-03 Thread Frederic Weisbecker
When a CPU runs in full dynticks mode, a 1Hz tick remains in order to keep the scheduler stats alive. However this residual tick is a burden for bare metal tasks that can't stand any interruption at all, or want to minimize them. Adding the boot parameter "isolcpus=nohz_offload" will now outsource

[PATCH 2/5] sched/isolation: Add scheduler tick offloading interface

2018-01-03 Thread Frederic Weisbecker
Add the boot option that will allow us to offload the 1Hz scheduler tick to the housekeeping CPU. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Rik van Riel Cc: Thomas Gleixner

[PATCH 1/5] sched: Rename init_rq_hrtick to hrtick_rq_init

2018-01-03 Thread Frederic Weisbecker
Do that rename in order to normalize the hrtick namespace. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Rik van Riel Cc: Thomas Gleixner Cc: Wanpeng Li Cc: Ingo Molnar --- k

[PATCH 5/5] sched/isolation: Document "nohz_offload" flag

2018-01-03 Thread Frederic Weisbecker
Document the interface to offload the 1Hz scheduler tick in full dynticks mode. Also improve the comment about the existing "nohz" flag in order to differentiate its behaviour. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc

[PATCH 3/5] nohz: Allow to check if remote CPU tick is stopped

2018-01-03 Thread Frederic Weisbecker
This check is racy but provides a good heuristic to determine whether a CPU may need a remote tick or not. Signed-off-by: Frederic Weisbecker Cc: Chris Metcalf Cc: Christoph Lameter Cc: Luiz Capitulino Cc: Mike Galbraith Cc: Paul E. McKenney Cc: Peter Zijlstra Cc: Rik van Riel Cc: Thomas G

Re: [PATCH 10/12] hpsa: drop unneeded newline

2018-01-03 Thread Martin K. Petersen
Julia, > hpsa_show_dev_msg prints other information and a newline after the > message string, so the message string does not need to include a > newline explicitly. Done using Coccinelle. Applied to 4.16/scsi-queue, thanks. -- Martin K. Petersen Oracle Linux Engineering

Re: "bad pmd" errors + oops with KPTI on 4.14.11 after loading X.509 certs

2018-01-03 Thread Benjamin Gilbert
On Wed, Jan 03, 2018 at 04:37:53PM -0800, Andy Lutomirski wrote: > Maybe try rebuilding a bad kernel with free_ldt_pgtables() modified > to do nothing, and the read /sys/kernel/debug/page_tables/current (or > current_kernel, or whatever it's called). The problem may be obvious. current_kernel att

Re: "bad pmd" errors + oops with KPTI on 4.14.11 after loading X.509 certs

2018-01-03 Thread Benjamin Gilbert
On Wed, Jan 03, 2018 at 05:37:42PM -0800, Benjamin Gilbert wrote: > I was caught by the fact that 4.14.11 has PAGE_TABLE_ISOLATION default y > but 4.15-rc6 doesn't. Retesting. It turns out that 4.15-rc6 has the same problem as 4.14.11. --Benjamin Gilbert

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Al Viro
On Thu, Jan 04, 2018 at 03:10:51AM +, Williams, Dan J wrote: > diff --git a/include/linux/fdtable.h b/include/linux/fdtable.h > index 1c65817673db..dbc12007da51 100644 > --- a/include/linux/fdtable.h > +++ b/include/linux/fdtable.h > @@ -82,8 +82,10 @@ static inline struct file *__fcheck_files

Re: "bad pmd" errors + oops with KPTI on 4.14.11 after loading X.509 certs

2018-01-03 Thread Andy Lutomirski
On Wed, Jan 3, 2018 at 8:35 PM, Benjamin Gilbert wrote: > On Wed, Jan 03, 2018 at 04:37:53PM -0800, Andy Lutomirski wrote: >> Maybe try rebuilding a bad kernel with free_ldt_pgtables() modified >> to do nothing, and the read /sys/kernel/debug/page_tables/current (or >> current_kernel, or whatever

Re: [PATCH v2 0/2] clk: qcom: MISC RCG changes for SDM845

2018-01-03 Thread Amit Nischal
On 2018-01-02 23:43, Stephen Boyd wrote: On 01/02, Amit Nischal wrote: Changes in v2: * Changed usage of clk_hw_is_prepared() to __clk_is_enabled() in clk_rcg2_shared_ops to fix build test error. Please change it to read the hardware directly and not use __clk_is_enabled() or clk_hw_is_prepa

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Eric W. Biederman
"Williams, Dan J" writes: > Note that these are "a human looked at static analysis reports and > could not rationalize that these are false positives". Specific domain > knowledge about these paths may find that some of them are indeed false > positives. > > The change to m_start in kernel/user

linux-next: Tree for Jan 4

2018-01-03 Thread Stephen Rothwell
Hi all, Changes since 20180103: Non-merge commits (relative to Linus' tree): 6793 7290 files changed, 280741 insertions(+), 199625 deletions(-) I have created today's linux-next tree at git://git.kernel.o

Re: KASAN: use-after-free Read in __dev_queue_xmit

2018-01-03 Thread Eric Dumazet
On Wed, Jan 3, 2018 at 8:58 PM, syzbot wrote: > Hello, > > syzkaller hit the following crash on > 37759fa6d0fa9e4d6036d19ac12f555bfc0aeafd > git://git.cmpxchg.org/linux-mmots.git/master > compiler: gcc (GCC) 7.1.1 20170620 > .config is attached > Raw console output is attached. > C reproducer is a

Re: [PATCH v3 00/20] arm64: Unmap the kernel whilst running in userspace (KPTI)

2018-01-03 Thread Florian Fainelli
On 12/11/2017 09:59 AM, Catalin Marinas wrote: > On Wed, Dec 06, 2017 at 12:35:19PM +, Will Deacon wrote: >> Patches are also pushed here: >> >> git://git.kernel.org/pub/scm/linux/kernel/git/will/linux.git kpti >> >> Feedback and testing welcome. At this point, I'd like to start thinking >> a

Re: [PATCH v1 1/1] usb: xhci: do not create and register shared_hcd when USB3.0 is disabled

2018-01-03 Thread Thang Q. Nguyen
Hi, On Sat, Dec 16, 2017 at 10:45 AM, Thang Q. Nguyen wrote: > From: Tung Nguyen > > Currently, hcd->shared_hcd always creates and registers to the usb-core. > If, for some reasons, USB3 downstream port is disabled, no roothub port for > USB3.0 is found. This causes kernel to display an error: >

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Dan Williams
On Wed, Jan 3, 2018 at 8:44 PM, Al Viro wrote: > On Thu, Jan 04, 2018 at 03:10:51AM +, Williams, Dan J wrote: > >> diff --git a/include/linux/fdtable.h b/include/linux/fdtable.h >> index 1c65817673db..dbc12007da51 100644 >> --- a/include/linux/fdtable.h >> +++ b/include/linux/fdtable.h >> @@ -

[lkp-robot] [x86/mm/kasan] 2533a63618: BUG:KASAN:use-after-scope_in__lock_acquire

2018-01-03 Thread kernel test robot
FYI, we noticed the following commit (built with gcc-7): commit: 2533a63618fcfd5fb0c7bb7549913e173a1908af ("x86/mm/kasan: Don't use vmemmap_populate() to initialize shadow") https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master in testcase: trinity with following parameters:

Re: [f2fs-dev] [PATCH] f2fs: enable quota at remount from r to w

2018-01-03 Thread Chao Yu
On 2018/1/3 10:01, Jaegeuk Kim wrote: > We have to enable quota only when remounting from read to write. Otherwise, > we'll get remount failure. (e.g., write to write case) > > Signed-off-by: Jaegeuk Kim Reviewed-by: Chao Yu Thanks,

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Dave Hansen
On 01/03/2018 09:44 PM, Dan Williams wrote: > No, the concern is that an fd value >= fdt->max_fds may cause the cpu > to read arbitrary memory addresses relative to files->fdt and > userspace can observe that it got loaded. Yep, it potentially tells you someting about memory after fdt->fd[]. For i

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Al Viro
On Wed, Jan 03, 2018 at 09:44:33PM -0800, Dan Williams wrote: > On Wed, Jan 3, 2018 at 8:44 PM, Al Viro wrote: > > On Thu, Jan 04, 2018 at 03:10:51AM +, Williams, Dan J wrote: > > > >> diff --git a/include/linux/fdtable.h b/include/linux/fdtable.h > >> index 1c65817673db..dbc12007da51 100644 >

[lkp-robot] [mm/memory_hotplug] 3072e413e3: page_allocation_failure:order:#,mode:#(GFP_KERNEL|__GFP_RETRY_MAYFAIL|__GFP_ZERO),nodemask=(null)

2018-01-03 Thread kernel test robot
FYI, we noticed the following commit (built with gcc-7): commit: 3072e413e305e353cd4654f8a57d953b66e85bf3 ("mm/memory_hotplug: introduce add_pages") https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git master in testcase: nvml with following parameters: group: obj te

[lkp-robot] [perf machine] 8edf8850d5: stderr./usr/src/linux-perf-x86_64-rhel-#/tools/perf/util/rb_resort.h:#:#:error:passing_argument#of'threads_sorted__new'from_incompatible_pointer_type[-Werror=in

2018-01-03 Thread kernel test robot
FYI, we noticed the following commit (built with gcc-7): commit: 8edf8850d51e911a35b5d7aad4f8604db11abc66 ("perf machine: Use cached rbtrees") url: https://github.com/0day-ci/linux/commits/Davidlohr-Bueso/tools-perf-Update-rbtree-implementation-and-optimize-users/20171128-120320 in testcase:

Re: linux-next: build warning after merge of the cifs tree

2018-01-03 Thread Stephen Rothwell
Hi Steve, On Wed, 3 Jan 2018 16:44:59 -0600 Steve French wrote: > > I don't see this with gcc 5.4 Good to know. > Harmless to initialize flags here ... even if unneeded ... so if it > makes your life easier I don't mind initializes to 0. Let me know. > Wonder why it doesn't generate the warnin

Re: [PATCH] virtio_balloon: use non-blocking allocation

2018-01-03 Thread Wei Wang
On 01/02/2018 10:50 PM, Tetsuo Handa wrote: Commit c7cdff0e864713a0 ("virtio_balloon: fix deadlock on OOM") tried to avoid OOM lockup by moving memory allocations to outside of balloon_lock. Now, Wei is trying to allocate far more pages outside of balloon_lock and some more memory inside of ball

Re: [PATCHv4 0/2] capability controlled user-namespaces

2018-01-03 Thread महेश बंडेवार
On Wed, Jan 3, 2018 at 8:44 AM, Eric W. Biederman wrote: > Mahesh Bandewar writes: > >> From: Mahesh Bandewar >> >> TL;DR version >> - >> Creating a sandbox environment with namespaces is challenging >> considering what these sandboxed processes can engage into. e.g. >> CVE-2017-6074

Re: [RFC PATCH] asm/generic: introduce if_nospec and nospec_barrier

2018-01-03 Thread Al Viro
On Thu, Jan 04, 2018 at 05:50:12AM +, Al Viro wrote: > On Wed, Jan 03, 2018 at 09:44:33PM -0800, Dan Williams wrote: > > On Wed, Jan 3, 2018 at 8:44 PM, Al Viro wrote: > > > On Thu, Jan 04, 2018 at 03:10:51AM +, Williams, Dan J wrote: > > > > > >> diff --git a/include/linux/fdtable.h b/inc

Re: [PATCH v2] f2fs: check segment type in __f2fs_replace_block

2018-01-03 Thread Chao Yu
Please add simple description here to explain why we need to add this, even though this change is very simple. On 2018/1/4 11:48, Yunlong Song wrote: > Signed-off-by: Yunlong Song > --- > fs/f2fs/segment.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/fs/f2fs/segment.c b/fs/f2fs/se

[lkp-robot] [workqueue] 5c0338c687: blogbench.write_score -21.2% regression

2018-01-03 Thread kernel test robot
Greeting, FYI, we noticed a -21.2% regression of blogbench.write_score due to commit: commit: 5c0338c68706be53b3dc472e4308961c36e4ece1 ("workqueue: restore WQ_UNBOUND/max_active==1 to be ordered") https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git master in testcase: blogbench on

Re: [f2fs-dev] [PATCH v5] f2fs: add reserved blocks for root user

2018-01-03 Thread Jaegeuk Kim
On 01/04, Chao Yu wrote: > On 2018/1/4 3:06, Jaegeuk Kim wrote: > > On 01/03, Chao Yu wrote: > >> On 2018/1/3 10:21, Jaegeuk Kim wrote: > >>> This patch allows root to reserve some blocks via mount option. > >>> > >>> "-o reserve_root=N" means N x 4KB-sized blocks for root only. > >>> > >>> Signed-

[PATCH net] net: dsa: b53: Turn off Broadcom tags for more switches

2018-01-03 Thread Florian Fainelli
Models such as BCM5395/97/98 and BCM53125/24/53115 and compatible require that we turn on managed mode to actually act on Broadcom tags, otherwise they just pass them through on ingress (host -> switch) and don't insert them in egress (switch -> host). Turning on managed mode is simple, but require

Re: [PATCH v5 0/7] Enhance libsas hotplug feature

2018-01-03 Thread Martin K. Petersen
John, > At this point we feel that we have a decent solution to the > long-standing libsas hotplug issues. > > Hannes has kindly reviewed the series. > > Can you let us know what else you require for acceptance? More > independent review or testing? According to my notes, Hannes had some concern

Re: [PATCH v2 1/2] PCI: dra7xx: Fix legacy INTD IRQ handling

2018-01-03 Thread Kishon Vijay Abraham I
On Friday 29 December 2017 05:11 PM, Vignesh R wrote: > Legacy INTD IRQ handling is broken on dra7xx due to fact that driver > uses hwirq in range of 1-4 for INTA, INTD whereas IRQ domain is of size > 4 which is numbered 0-3. Therefore when INTD IRQ line is used with > pci-dra7xx driver following

Re: [PATCH v2 2/2] PCI: dra7xx: Iterate over INTx status bits

2018-01-03 Thread Kishon Vijay Abraham I
On Friday 29 December 2017 05:11 PM, Vignesh R wrote: > It is possible that more than one legacy IRQ may be set at the same > time, therefore iterate and handle all the pending INTx interrupts > before clearing the status and exiting the IRQ handler. Otherwise, some > interrupts would be lost. >

Re: [PATCH 1/9] scsi: qla4xxx: Use zeroing allocator rather than allocator/memset

2018-01-03 Thread Martin K. Petersen
Himanshu, > Use dma_zalloc_coherent instead of dma_alloc_coherent followed by memset > 0. Applied to 4.16/scsi-queue. -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH 2/9] scsi: qla2xxx: Use zeroing allocator rather than allocator/memset

2018-01-03 Thread Martin K. Petersen
Himanshu, > Use dma_zalloc_coherent and vzalloc instead of dma_alloc_coherent and > vmalloc respectively, followed by memset 0. Applied to 4.16/scsi-queue. -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH 8/9] scsi: bfa: Use zeroing allocator rather than allocator/memset

2018-01-03 Thread Martin K. Petersen
Himanshu, > Use vzalloc instead of vmalloc followed by memset 0. Applied to 4.16/scsi-queue. -- Martin K. Petersen Oracle Linux Engineering

[PATCH v2 2/7] ARM: dts: imx6q-icore: Switch LVDS timings from panel-simple

2018-01-03 Thread Jagan Teki
Switch to use ampire,am-800480aytzqw-00h LVDS timings from panel-simple instead hard coding the same in dts. Signed-off-by: Jagan Teki --- Changes for v2: - none arch/arm/boot/dts/imx6q-icore.dts| 31 +-- arch/arm/boot/dts/imx6qdl-icore.dtsi | 2 +- 2 files chan

Re: [PATCH] mm/fadvise: discard partial pages iff endbyte is also eof

2018-01-03 Thread 夷则(Caspar)
On 2018/1/3 18:48, Mel Gorman wrote: On Wed, Jan 03, 2018 at 02:53:43PM +0800, ??(Caspar) wrote: ?? 2017??12??2312:16?? ?? From: "shidao.ytt" in commit 441c228f817f7 ("mm: fadvise: document the fadvise(FADV_DONTNEED) behaviour for partial pages") Mel Gorman explained why

[PATCH v2 0/7] ARM: dts: imx6q: engicam LVDS panel changes

2018-01-03 Thread Jagan Teki
Series add LVDS panel attributes on panel drivers instead of defining them in dts nodes, and also added new icorem6 engicam boards Jagan Teki (7): drm/panel: simple: add support for Ampire AM-800480AYTZQW-00H ARM: dts: imx6q-icore: Switch LVDS timings from panel-simple ARM: dts: imx6dl-icore

Re: [PATCH v2 2/2] PCI: dra7xx: Iterate over INTx status bits

2018-01-03 Thread Vignesh R
On Tuesday 02 January 2018 09:17 PM, Lorenzo Pieralisi wrote: > On Fri, Dec 29, 2017 at 05:11:31PM +0530, Vignesh R wrote: >> It is possible that more than one legacy IRQ may be set at the same >> time, therefore iterate and handle all the pending INTx interrupts >> before clearing the status and

Re: [PATCH 9/9] scsi: bnx2i: Use zeroing allocator rather than allocator/memset

2018-01-03 Thread Martin K. Petersen
Himanshu, > Use dma_zalloc_coherent instead of dma_alloc_coherent followed by > memset 0. Applied to 4.16/scsi-queue. -- Martin K. Petersen Oracle Linux Engineering

[PATCH v2 3/7] ARM: dts: imx6dl-icore: Add LVDS node

2018-01-03 Thread Jagan Teki
Add ampire,am-800480aytzqw-00h LVDS support by using timings from panel-simple. Signed-off-by: Jagan Teki --- Changes for v2: - none arch/arm/boot/dts/imx6dl-icore.dts | 28 1 file changed, 28 insertions(+) diff --git a/arch/arm/boot/dts/imx6dl-icore.dts b/arch/ar

[PATCH v2 4/7] drm/panel: simple: Add support for KEO TX31D200VM0BAA

2018-01-03 Thread Jagan Teki
This adds support for the Kaohsiung Opto-Electronics., TX31D200VM0BAA 12.3" HSXGA LVDS panel, which can be supported by the simple panel driver. Signed-off-by: Jagan Teki --- Changes for v2: - Updated binding info about optional properties, node and example .../bindings/display/panel/koe,tx31d2

[PATCH v2 7/7] ARM: dts: imx6q: Add Engicam i.CoreM6 1.5 Quad/Dual MIPI starter kit support

2018-01-03 Thread Jagan Teki
i.CoreM6 1.5 is an another i.CoreM6 QDL cpu modules which can be connected to EDIMM starter kit design with eMMC and MIPI-CSI interfaces suitable for Android and video capture application. notable features: CPU NXP i.MX6 S/DL/D/Q, Up to 4 x Cortex-A9@800MHz Memory

[PATCH v2 5/7] ARM: dts: imx6q-icore-ofcap12: Switch LVDS timings from panel-simple

2018-01-03 Thread Jagan Teki
Switch to use koe_tx31d200vm0baa LVDS timings from panel-simple instead hard coding the same in dts. Signed-off-by: Jagan Teki --- Changes for v2: - none arch/arm/boot/dts/imx6q-icore-ofcap12.dts | 31 +-- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git

[PATCH v2 6/7] ARM: dts: imx6q: Add Engicam i.CoreM6 Quad/Dual OpenFrame Cap 7 initial support

2018-01-03 Thread Jagan Teki
i.CoreM6 Quad/Dual OpenFrame modules are "system on modules plus openframe display carriers" which are good solution for develop user friendly graphic user interface. ofcap 7 general features: CPU NXP Freescale i.MX6Q rev1.5 at 792 MHz RAM 1GB, 32, 64 bit, DDR3-800/1066 NAND

[PATCH v2 1/7] drm/panel: simple: add support for Ampire AM-800480AYTZQW-00H

2018-01-03 Thread Jagan Teki
This adds support for the Ampire AM-800480AYTZQW-00H 7.0" WGA LCD, which can be supported by the simple panel driver. Signed-off-by: Jagan Teki --- Changes for v2: - Updated binding info about optional properties, node and example .../display/panel/ampire,am-800480aytzqw-00h.txt | 25

Re: [PATCH 1/2] f2fs: use flexible array for f2fs_checkpoint::sit_nat_version_bitmap

2018-01-03 Thread Jaegeuk Kim
On 01/04, Chao Yu wrote: > On 2018/1/4 4:12, Jaegeuk Kim wrote: > > On 01/03, Chao Yu wrote: > >> If we need an array with variable size in the end of structure, we > >> can utilize flexible array feature which is supported in C99, so > >> let's change sit_nat_version_bitmap[] to flexible array in

Re: [PATCH 3/9] scsi: qedi: Use zeroing allocator instead of allocator/memset

2018-01-03 Thread Martin K. Petersen
Himanshu, > Use dma_zalloc_coherent instead of dma_alloc_coherent followed by memset > 0. Does not apply to 4.16/scsi-queue. Please resubmit. Thanks! -- Martin K. Petersen Oracle Linux Engineering

<    4   5   6   7   8   9   10   >